Skip to content

Commit

Permalink
Update NB to fix error extracting metric docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffcarlin committed Jan 31, 2025
1 parent 2d475e1 commit a67618d
Showing 1 changed file with 25 additions and 17 deletions.
42 changes: 25 additions & 17 deletions notebooks/atools_metrics_plots_census.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
"\n",
" for r in res:\n",
" # Process the string to extract the bundle name, module, and task:\n",
" full_string = atools_pipeline_config[r: r+150]\n",
" full_string = atools_pipeline_config[r: r+200]\n",
" split0 = str.split(full_string, 'config.atools.')\n",
" bundle_name = str.split(split0[1], '=')[0]\n",
" split1 = str.split(split0[1], sub_str)\n",
Expand All @@ -209,7 +209,7 @@
"\n",
" # Link to w_2025_02 version of the docs on github:\n",
" mod_new = module.replace('.', '/')\n",
" path = 'https://github.com/lsst/analysis_tools/blob/w.2025.02/python/'+mod_new+'.py'\n",
" path = 'https://github.com/lsst/analysis_tools/blob/w.2025.04/python/'+mod_new+'.py'\n",
" info = {'docstring': doc2, 'path': path}\n",
" docstring_dict[bundle_name] = info\n",
"\n",
Expand Down Expand Up @@ -297,9 +297,9 @@
"metadata": {},
"outputs": [],
"source": [
"repo = '/repo/embargo'\n",
"repo = '/repo/main'\n",
"\n",
"collections = ['LSSTComCam/runs/DRP/DP1-RC1/w_2025_02/DM-48371']\n",
"collections = ['LSSTComCam/runs/DRP/DP1/w_2025_04/DM-48556']\n",
"\n",
"butler = Butler(repo, collections=collections)\n",
"registry = butler.registry"
Expand Down Expand Up @@ -379,17 +379,17 @@
" 'sourceTable_visit_gaia_dr3_20230707_match',\n",
"]\n",
"pipelines_url = [\n",
" 'https://github.com/lsst/drp_pipe/blob/w.2025.02/pipelines/LSSTComCamSim/nightly-validation-ops-rehearsal-3.yaml#L18-L26',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/diaTractQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/matchedVisitQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/coaddColumnValidate.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/coaddQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/coaddQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/coaddQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/coaddQualityExtended.yaml',\n",
" 'https://github.com/lsst/drp_pipe/blob/w.2025.02/pipelines/_ingredients/LSSTComCamSim/DRP.yaml#L68-L78',\n",
" 'https://github.com/lsst/drp_pipe/blob/w.2025.04/pipelines/LSSTComCamSim/nightly-validation-ops-rehearsal-3.yaml#L18-L26',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/diaTractQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/matchedVisitQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/coaddColumnValidate.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/coaddQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/coaddQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/coaddQualityCore.yaml',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/coaddQualityExtended.yaml',\n",
" 'https://github.com/lsst/drp_pipe/blob/w.2025.04/pipelines/_ingredients/LSSTComCamSim/DRP.yaml#L68-L78',\n",
" # TO DO: put in real links here\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.02/pipelines/coaddQualityCore.yaml#L90-L123',\n",
" 'https://github.com/lsst/analysis_tools/blob/w.2025.04/pipelines/coaddQualityCore.yaml#L90-L123',\n",
" 'NA'\n",
"]\n",
"task_frame = pd.DataFrame({'name': task_names,\n",
Expand Down Expand Up @@ -434,9 +434,7 @@
"cell_type": "code",
"execution_count": null,
"id": "e186e24e-a5d7-4853-8ba3-e554dc8df1ce",
"metadata": {
"scrolled": true
},
"metadata": {},
"outputs": [],
"source": [
"for task in task_frame.name:\n",
Expand Down Expand Up @@ -720,6 +718,16 @@
"create_plot_references(task_frame, task_table_dict)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "f0194a0b-c627-4391-9a50-1db566db3937",
"metadata": {},
"outputs": [],
"source": [
"task_frame"
]
},
{
"cell_type": "code",
"execution_count": null,
Expand Down

0 comments on commit a67618d

Please sign in to comment.