From 8359acb2b0186d594bc579dbb13f1868dba3f5e5 Mon Sep 17 00:00:00 2001 From: peter Date: Tue, 16 May 2023 09:23:07 -0700 Subject: [PATCH 1/2] finalize DFE development docs; closes #1085 --- docs/development.rst | 37 ++++++++++++++++++++++++------------- 1 file changed, 24 insertions(+), 13 deletions(-) diff --git a/docs/development.rst b/docs/development.rst index e8234a1a8..643f6ee84 100644 --- a/docs/development.rst +++ b/docs/development.rst @@ -1652,7 +1652,7 @@ Testing your DFE model and submitting a PR After you finished your implementation, and specified all the necessary citations, -we recommend that you run some basic local tests to see that +we recommend that you run some basic local checks to see that the model was successfully loaded to ``stdpopsim``. You may follow the process outlined for `Testing your demographic model and submitting a PR`_. @@ -1664,15 +1664,7 @@ At this point, most of your work is done. **You have officially joined the** ``stdpopsim`` **development team. Welcome!!** Your DFE model still needs to undergo review by another member of the development team before it is fully incorporated into ``stdpopsim``. -This will likely require additional feedback from you, -so, stay tuned for discussion during the review process. - ---------------------- -Reviewing a DFE model ---------------------- - -The review process for DFE models is currently being developed. -For now, we suggest that you +To facilitate this, please `open a new blank issue `__ and specify the following information: @@ -1682,9 +1674,28 @@ and specify the following information: 4. **Potential issues:** 5. **QC'er requests:** -A reviewer will be assigned to check your implementation and approve it. -All discussion about the review can be conducted in the **QC issue** -mentioned above. +This will likely require additional feedback from you, +so, stay tuned for discussion during the review process. + +--------------------- +Reviewing a DFE model +--------------------- + +The process for reviewing a DFE is essentially the same +as for reviewing a demographic model (see `Overview of the stdpopsim review process`_). +Briefly, you will re-implement the DFE "blind", i.e., without looking at the DFE +implementation already added to the code. +Then, the unit tests check whether the implementations are equivalent. +To do this, you add your implementation to ``stdpopsim/qc/.py``, +followed by a call like + +.. code-block:: python + + _species.get_dfe(_MODEL_ID_).register_qc(_your_review_function()) + +where ``_MODEL_ID_`` is the string specified as the ID for the original DFE, +and ``_your_review_function()`` is the function you've added to the QC file +that returns a DFE object. **************** Coding standards From ff1ba855b458c8bb79ad3617197c3af200fbbaf6 Mon Sep 17 00:00:00 2001 From: peter Date: Sun, 22 Dec 2024 20:07:19 -0800 Subject: [PATCH 2/2] dfe qc issue template --- .github/ISSUE_TEMPLATE/dfe-qc-issue-template.md | 17 +++++++++++++++++ docs/development.rst | 16 ++++++---------- 2 files changed, 23 insertions(+), 10 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE/dfe-qc-issue-template.md diff --git a/.github/ISSUE_TEMPLATE/dfe-qc-issue-template.md b/.github/ISSUE_TEMPLATE/dfe-qc-issue-template.md new file mode 100644 index 000000000..47e42e33e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/dfe-qc-issue-template.md @@ -0,0 +1,17 @@ +--- +name: DFE QC issue template +about: Quality control process for DFE addition +title: QC for {dfe_id} ({species}) +labels: DFE QC +assignees: '' + +--- + +**PR for new model:** {link to Pull Request} +**Original paper:** {ink to original paper} +**Parameter values:** {reference to where parameter values can be found} + +**Potential issues that might lead to differences between the model implementations:** +{description of any potential issues} + +**QC'er requests:** {tag potential developers to QC the model} diff --git a/docs/development.rst b/docs/development.rst index 643f6ee84..92fb82b58 100644 --- a/docs/development.rst +++ b/docs/development.rst @@ -1664,19 +1664,15 @@ At this point, most of your work is done. **You have officially joined the** ``stdpopsim`` **development team. Welcome!!** Your DFE model still needs to undergo review by another member of the development team before it is fully incorporated into ``stdpopsim``. -To facilitate this, please -`open a new blank issue `__ -and specify the following information: - -1. **PR for new model:** -2. **Original paper:** -3. **Parameter values:** -4. **Potential issues:** -5. **QC'er requests:** - This will likely require additional feedback from you, so, stay tuned for discussion during the review process. +To facilitate this, there is one more step: please open a +`new issue `__, +using the "DFE QC" template. +The template asks for the basic information that someone will need +to independently verify the implemented DFE. + --------------------- Reviewing a DFE model ---------------------