Skip to content

Commit 017dd2d

Browse files
Jammy2211claude
authored andcommitted
docs: fix dead internal references in script docstrings
The README half of this drift class is fixed and now gated at PR time (PyAutoHands#213). This is the remaining surface: dead file/folder references in scripts/**/*.py docstrings and comments, which the gate deliberately does not cover. Driven by `pyauto-brain hygiene refs --json`, which reported 129 findings across 7 repos. Verified classes: - log_likelihood_function -> likelihood_function (the scripts drop the log_) - notation/label.yaml -> notation.yaml (config went folder -> file) - config/generag.yaml -> config/general.yaml (autolens->autogalaxy clone residue, here in script prose) - autofit_workspace/*/plots -> plot (the package is singular) - feature/pixelization/... -> features/ ; subhalo/detection -> detect - guides/source_science -> the topic packages (source_science.py lives in imaging/, interferometer/, group/ -- never guides/) - preprocess / propocess -> imaging/data_preparation - modeling/imaging/{customize,searches} -> guides/modeling/... - imaging/advanced/database -> guides/results/database - simulators -> simulator (singular) - dataset directories quoted without their `dataset/` prefix -- the folder is written by a simulator, so the fix is qualification, not a restore Eleven needed prose rewriting rather than a re-point, because the target does not exist in any form: autogalaxy has no CPU-fast pixelization example (now points at the autolens one), point_source has no likelihood_function walkthrough (points at cluster/likelihood_function, titled "Log Likelihood Function: Cluster Point Source"), no subhalo/detect/examples folder exists, mat_wrap.yaml was retired in favour of general.yaml, config/priors has no `default` subfolder, and z_projects/ is not part of this workspace (the Euclid pipeline has its own repo). Notebooks and the navigator catalogue regenerated, since docstring text feeds notebooks/, llms-full.txt and workspace_index.json. Verified: hygiene refs reports 0 findings across all 7 repos (from 129), and check_navigator.py --banners=fail passes on all 6 gated repos. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
1 parent 4e0e4b3 commit 017dd2d

5 files changed

Lines changed: 61 additions & 61 deletions

File tree

notebooks/chapter_1_introduction/start_here.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
"\n",
5656
"An applied astronomy-focused example (previously tutorial 8) now lives in\n",
5757
"`autofit_workspace_developer/scripts/howtofit/chapter_1_introduction/tutorial_8_astronomy_example.py`,\n",
58-
"alongside the larger `projects/cosmology/` example. These depend on astronomy-specific datasets\n",
58+
"alongside the larger `autofit_workspace_developer/projects/cosmology/` example. These depend on astronomy-specific datasets\n",
5959
"that only live in the developer workspace."
6060
]
6161
},

notebooks/chapter_1_introduction/tutorial_5_results_and_samples.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"In this tutorial, we'll cover all of the output that comes from a non-linear search's `Result` object.\n",
1111
"\n",
1212
"We used this object at various points in the chapter. The bulk of material covered here is described in the example\n",
13-
"script `autofit_workspace/overview/simple/result.py`. Nevertheless, it is a good idea to refresh ourselves about how\n",
13+
"script `autofit_workspace/*/cookbooks/result.py`. Nevertheless, it is a good idea to refresh ourselves about how\n",
1414
"results in **PyAutoFit** work before covering more advanced material.\n",
1515
"\n",
1616
"__Contents__\n",
@@ -993,7 +993,7 @@
993993
"\n",
994994
"By combining this with the filtering tools below, specific parameters can be included or removed from the latex.\n",
995995
"\n",
996-
"Remember that the superscripts of a parameter are loaded from the config file `notation/label.yaml`, providing high\n",
996+
"Remember that the superscripts of a parameter are loaded from the config file `notation.yaml`, providing high\n",
997997
"levels of customization for how the parameter names appear in the latex table. This is especially useful if your model\n",
998998
"uses the same model components with the same parameter, which therefore need to be distinguished via superscripts."
999999
]
Lines changed: 55 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,55 @@
1-
"""
2-
HowToFit Lectures
3-
=================
4-
5-
Welcome to the HowToFit Jupyter Notebook lectures!
6-
7-
At the core of data science is fitting a model to data. This process extracts meaningful patterns, relationships,
8-
and insights, enabling accurate predictions, decision-making, and understanding of underlying processes.
9-
10-
However, data science can be quite challenging. With a vast array of statistical methods to choose from, it can be
11-
difficult to determine the right one for your problem. Interpreting large volumes of results is complex, and managing big datasets requires significant computational power and sophisticated statistical methods.
12-
13-
The HowToFit lectures teach you how to perform effective data science analysis. Designed at an undergraduate level,
14-
these lectures assume no prior knowledge of model-fitting, Bayesian statistics, or scientific analysis. They
15-
introduce core concepts without formal statistical equations, aiming to provide an understanding of the
16-
phenomenological methods used in data science. By the end of the lectures, you'll be equipped to perform your own
17-
data analysis.
18-
19-
The lectures use the probabilistic programming language PyAutoFit, an open-source library for model-fitting,
20-
scientific analysis, and big data analysis (https://github.com/PyAutoLabs/PyAutoFit).
21-
22-
The HowToFit lectures are composed of 3 chapters:
23-
24-
**Chapter 1: Introduction**: How to fit a model to data, perform statistical inference, and interpret the results
25-
for scientific analysis.
26-
27-
**Chapter 2: Scientific Workflow**: Scaling model-fitting to big datasets while ensuring detailed scientific analysis
28-
of the results.
29-
30-
**Chapter 3: Graphical Models**: Simultaneous model fitting of large datasets, scaling up to models with tens of
31-
thousands of parameters.
32-
33-
After each chapter, it is advised that you apply what you've learned to your own model-fitting analysis based on
34-
your scientific problem to build confidence in the techniques. Once confident, proceed to the next chapter.
35-
36-
__Chapter 1: Introduction__
37-
38-
The first chapter of the HowToFit lectures covers the basics of model-fitting, statistical inference, and scientific
39-
interpretation. The chapter includes:
40-
41-
`tutorial_1_models.py`: What probabilistic models are and how to compose them using PyAutoFit.
42-
43-
`tutorial_2_fitting_data.py`: Fitting a model with an input set of parameters to data and quantifying the goodness of fit.
44-
45-
`tutorial_3_non_linear_search.py`: Searching non-linear parameter spaces to find the best-fit model.
46-
47-
`tutorial_4_why_modeling_is_hard.py`: Why modeling becomes difficult and how to over model-fitting problems.
48-
49-
`tutorial_5_results_and_samples.py`: Interpreting model-fit results and using the samples for scientific analysis.
50-
51-
An applied astronomy-focused example (previously tutorial 8) now lives in
52-
`autofit_workspace_developer/scripts/howtofit/chapter_1_introduction/tutorial_8_astronomy_example.py`,
53-
alongside the larger `projects/cosmology/` example. These depend on astronomy-specific datasets
54-
that only live in the developer workspace.
55-
"""
1+
"""
2+
HowToFit Lectures
3+
=================
4+
5+
Welcome to the HowToFit Jupyter Notebook lectures!
6+
7+
At the core of data science is fitting a model to data. This process extracts meaningful patterns, relationships,
8+
and insights, enabling accurate predictions, decision-making, and understanding of underlying processes.
9+
10+
However, data science can be quite challenging. With a vast array of statistical methods to choose from, it can be
11+
difficult to determine the right one for your problem. Interpreting large volumes of results is complex, and managing big datasets requires significant computational power and sophisticated statistical methods.
12+
13+
The HowToFit lectures teach you how to perform effective data science analysis. Designed at an undergraduate level,
14+
these lectures assume no prior knowledge of model-fitting, Bayesian statistics, or scientific analysis. They
15+
introduce core concepts without formal statistical equations, aiming to provide an understanding of the
16+
phenomenological methods used in data science. By the end of the lectures, you'll be equipped to perform your own
17+
data analysis.
18+
19+
The lectures use the probabilistic programming language PyAutoFit, an open-source library for model-fitting,
20+
scientific analysis, and big data analysis (https://github.com/PyAutoLabs/PyAutoFit).
21+
22+
The HowToFit lectures are composed of 3 chapters:
23+
24+
**Chapter 1: Introduction**: How to fit a model to data, perform statistical inference, and interpret the results
25+
for scientific analysis.
26+
27+
**Chapter 2: Scientific Workflow**: Scaling model-fitting to big datasets while ensuring detailed scientific analysis
28+
of the results.
29+
30+
**Chapter 3: Graphical Models**: Simultaneous model fitting of large datasets, scaling up to models with tens of
31+
thousands of parameters.
32+
33+
After each chapter, it is advised that you apply what you've learned to your own model-fitting analysis based on
34+
your scientific problem to build confidence in the techniques. Once confident, proceed to the next chapter.
35+
36+
__Chapter 1: Introduction__
37+
38+
The first chapter of the HowToFit lectures covers the basics of model-fitting, statistical inference, and scientific
39+
interpretation. The chapter includes:
40+
41+
`tutorial_1_models.py`: What probabilistic models are and how to compose them using PyAutoFit.
42+
43+
`tutorial_2_fitting_data.py`: Fitting a model with an input set of parameters to data and quantifying the goodness of fit.
44+
45+
`tutorial_3_non_linear_search.py`: Searching non-linear parameter spaces to find the best-fit model.
46+
47+
`tutorial_4_why_modeling_is_hard.py`: Why modeling becomes difficult and how to over model-fitting problems.
48+
49+
`tutorial_5_results_and_samples.py`: Interpreting model-fit results and using the samples for scientific analysis.
50+
51+
An applied astronomy-focused example (previously tutorial 8) now lives in
52+
`autofit_workspace_developer/scripts/howtofit/chapter_1_introduction/tutorial_8_astronomy_example.py`,
53+
alongside the larger `autofit_workspace_developer/projects/cosmology/` example. These depend on astronomy-specific datasets
54+
that only live in the developer workspace.
55+
"""

scripts/chapter_1_introduction/tutorial_5_results_and_samples.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
In this tutorial, we'll cover all of the output that comes from a non-linear search's `Result` object.
66
77
We used this object at various points in the chapter. The bulk of material covered here is described in the example
8-
script `autofit_workspace/overview/simple/result.py`. Nevertheless, it is a good idea to refresh ourselves about how
8+
script `autofit_workspace/*/cookbooks/result.py`. Nevertheless, it is a good idea to refresh ourselves about how
99
results in **PyAutoFit** work before covering more advanced material.
1010
1111
__Contents__
@@ -678,7 +678,7 @@ def model_data_from(self, xvalues: np.ndarray):
678678
679679
By combining this with the filtering tools below, specific parameters can be included or removed from the latex.
680680
681-
Remember that the superscripts of a parameter are loaded from the config file `notation/label.yaml`, providing high
681+
Remember that the superscripts of a parameter are loaded from the config file `notation.yaml`, providing high
682682
levels of customization for how the parameter names appear in the latex table. This is especially useful if your model
683683
uses the same model components with the same parameter, which therefore need to be distinguished via superscripts.
684684
"""

workspace_index.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@
130130
"Latex"
131131
],
132132
"cross_refs": [
133-
"autofit_workspace/overview/simple/result.py",
133+
"/cookbooks/result.py",
134134
"corner.py"
135135
],
136136
"notebook": "notebooks/chapter_1_introduction/tutorial_5_results_and_samples.ipynb",

0 commit comments

Comments
 (0)