From 6ccc697f967b2d275f411d9f29c849d87de5762f Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 7 Aug 2026 02:29:59 +0000 Subject: [PATCH] docs: mark the 2 data.json auto-simulate guards as intentionally raw MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Decision record for the file-path leg of the raw-guard migration (autolens_workspace#475, split from autolens_workspace#354): these guards check a file (dataset_0/data.json), and this workspace has no should_simulate namespace and never sets PYAUTO_SMALL_DATASETS (the recorded leg-3 rejection — adding an af.util.should_simulate plus a new env contract in PyAutoFit would buy zero functional gain). A one-line comment at each site records this so future sweeps don't re-flag them. Notebooks regenerated for the 2 touched scripts (carries the now-canonical setup_notebook activation from PyAutoHands 596967e). Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01EGua3k2WDPVrtvj4MTMUoT --- notebooks/features/graphical_models.ipynb | 4 +++- notebooks/features/shared_analysis_state.ipynb | 4 +++- scripts/features/graphical_models.py | 2 ++ scripts/features/shared_analysis_state.py | 2 ++ 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/notebooks/features/graphical_models.ipynb b/notebooks/features/graphical_models.ipynb index 3b26edae..0994c8a1 100644 --- a/notebooks/features/graphical_models.ipynb +++ b/notebooks/features/graphical_models.ipynb @@ -97,7 +97,7 @@ "metadata": {}, "source": [ "\n", - "# from autofit import setup_notebook; setup_notebook()\n", + "from autofit import setup_notebook; setup_notebook()\n", "\n", "from os import path\n", "import matplotlib.pyplot as plt\n", @@ -141,6 +141,8 @@ "cell_type": "code", "metadata": {}, "source": [ + "# Intentional raw guard: this guards a single file, and this workspace has no\n", + "# should_simulate / PYAUTO_SMALL_DATASETS contract (unlike autolens/autogalaxy).\n", "if not path.exists(\n", " path.join(\"dataset\", \"example_1d\", \"gaussian_x1__low_snr\", \"dataset_0\", \"data.json\")\n", "):\n", diff --git a/notebooks/features/shared_analysis_state.ipynb b/notebooks/features/shared_analysis_state.ipynb index 2a47e4f5..29e25cb5 100644 --- a/notebooks/features/shared_analysis_state.ipynb +++ b/notebooks/features/shared_analysis_state.ipynb @@ -104,7 +104,7 @@ "metadata": {}, "source": [ "\n", - "# from autofit import setup_notebook; setup_notebook()\n", + "from autofit import setup_notebook; setup_notebook()\n", "\n", "from os import path\n", "import matplotlib.pyplot as plt\n", @@ -147,6 +147,8 @@ "cell_type": "code", "metadata": {}, "source": [ + "# Intentional raw guard: this guards a single file, and this workspace has no\n", + "# should_simulate / PYAUTO_SMALL_DATASETS contract (unlike autolens/autogalaxy).\n", "if not path.exists(\n", " path.join(\"dataset\", \"example_1d\", \"gaussian_x1__low_snr\", \"dataset_0\", \"data.json\")\n", "):\n", diff --git a/scripts/features/graphical_models.py b/scripts/features/graphical_models.py index ec1117a9..8fbfbc27 100644 --- a/scripts/features/graphical_models.py +++ b/scripts/features/graphical_models.py @@ -71,6 +71,8 @@ If the dataset does not already exist on your system, it will be created by running the corresponding simulator script. This ensures that all example scripts can be run without manually simulating data first. """ +# Intentional raw guard: this guards a single file, and this workspace has no +# should_simulate / PYAUTO_SMALL_DATASETS contract (unlike autolens/autogalaxy). if not path.exists( path.join("dataset", "example_1d", "gaussian_x1__low_snr", "dataset_0", "data.json") ): diff --git a/scripts/features/shared_analysis_state.py b/scripts/features/shared_analysis_state.py index 0666e314..e8f76b64 100644 --- a/scripts/features/shared_analysis_state.py +++ b/scripts/features/shared_analysis_state.py @@ -77,6 +77,8 @@ If the dataset does not already exist on your system, it will be created by running the corresponding simulator script. """ +# Intentional raw guard: this guards a single file, and this workspace has no +# should_simulate / PYAUTO_SMALL_DATASETS contract (unlike autolens/autogalaxy). if not path.exists( path.join("dataset", "example_1d", "gaussian_x1__low_snr", "dataset_0", "data.json") ):