Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,14 +98,13 @@ for the chapter 1 tutorials listed with a `markdown` link below; every other tut
- [Tutorial 5: Data and Likelihoods](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_2_lens_modeling/tutorial_5_data_and_likelihoods.ipynb) — Separating datasets, models and likelihoods, including positions penalties.
- [Tutorial 6: Search Chaining](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_2_lens_modeling/tutorial_6_search_chaining.ipynb) — Combining searches and introducing the SLaM pipelines.
- [Tutorial 7: Summary](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_2_lens_modeling/tutorial_7_summary.ipynb) — Bringing the chapter together and continuing to pixelized sources.
- **[Chapter 3: Pixelizations](scripts/chapter_3_pixelizations/README.md)** — From MGE to pixelized sources: mappings, inversions, Bayesian regularization, borders and chained lens fits.
- **[Chapter 3: Pixelizations](scripts/chapter_3_pixelizations/README.md)** — From MGE to pixelized sources: mappings, inversions, Bayesian regularization, borders, fit problems, adaptive reconstruction and chained lens fits.
- Tutorial 1 Pixelizations — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_1_pixelizations.ipynb))
- Tutorial 2 Bayesian Regularization — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_2_bayesian_regularization.ipynb))
- Tutorial 3 Borders — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_3_borders.ipynb))
- Tutorial 4 Lens Modeling — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_4_lens_modeling.ipynb))
- Tutorial 8 Adaptive Pixelization — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_8_adaptive_pixelization.ipynb))
- Tutorial 11 Brightness Adaption — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_11_brightness_adaption.ipynb))
- Tutorial 12 Adaptive Regularization — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_12_adaptive_regularization.ipynb))
- Tutorial 5 Fit Problems — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_5_fit_problems.ipynb))
- Tutorial 6 Adaptive Reconstruction — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_6_adaptive_reconstruction.ipynb))
- **[Chapter 4: Scaling Up Lensing](scripts/chapter_4_scaling_up_lensing/README.md)** — Extra galaxies, multi-galaxy lenses, scaling relations, group and cluster scales, and weak lensing.
- Tutorial 1: Extra Galaxies — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/2026.11.1.1/notebooks/chapter_4_scaling_up_lensing/tutorial_1_extra_galaxies.ipynb))
- Tutorial 2: Multi Galaxy — ([Colab](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/2026.11.1.1/notebooks/chapter_4_scaling_up_lensing/tutorial_2_multi_galaxy.ipynb))
Expand Down
5 changes: 1 addition & 4 deletions config/build/profile_smoke.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,5 @@ defaults:
# `multi/start_here` and `guides/results/` are all autolens_workspace paths
# copied in from that repo's profile_smoke.yaml. HowToLens contains only
# chapter_*/tutorial_*.py, so none of them ever matched a file here.
# Do not copy override patterns between repos; a pattern that matches nothing
# is silently inert, not an override. The list is now empty, and `overrides: []`
# is written explicitly because env_config.py reads `.get("overrides", [])` —
# a bare `overrides:` key would load as None and raise on iteration.
# Tutorials requiring full-size datasets declare this in their __Env__ sections.
overrides: []
26 changes: 12 additions & 14 deletions llms-full.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,20 +44,18 @@ AUTO-GENERATED by PyAutoHands — do not edit by hand; regenerate with generate.

## chapter_3_pixelizations

- [Tutorial 11: Brightness Adaption](scripts/chapter_3_pixelizations/tutorial_11_brightness_adaption.py): In the previous tutorial we motivated our need to adapt the pixelization to the source's morphology, such that source pixels congregates in the source's brightest regions regardless of where the source is located in the source-plane.
- Contents: Initial Setup, Adapt Image, Adaption, Hilbert, Weight Map, Wrap Up
- [Tutorial 12: Adaptive Regularization](scripts/chapter_3_pixelizations/tutorial_12_adaptive_regularization.py): Tutorial 2 introduced `Constant` regularization. Different regions of the source can favour different levels of regularization, motivating a scheme which adapts to the reconstructed source's surface brightness.
- Contents: Initial Setup, Convenience Function, Adaptive Regularization, Wrap Up
- [Tutorial 1: Pixelizations, Mappers and Inversions](scripts/chapter_3_pixelizations/tutorial_1_pixelizations.py): (no summary in script docstring)
- Contents: Opening — Pixelized source reconstruction, A complex source, Why a simple source model falls short, A grid for the source light, Following the same image pixels into the source plane, Where a traced image pixel meets the source mesh, One source region, several image regions, Reconstructing the source, A first look at regularization, From source indexes to reconstructed brightnesses, Turning the reconstructed source back into an image, Inspecting the reconstruction, Changing the source resolution, Wrap up
- [Tutorial 2: Bayesian Regularization](scripts/chapter_3_pixelizations/tutorial_2_bayesian_regularization.py): (no summary in script docstring)
- Contents: Interpolation and Bayesian regularization, Interpolation and our starting reconstruction, Reducing regularization, Increasing regularization, Bayesian evidence, Exploring the regularization coefficient, Inspecting the preferred reconstruction, What is linear, and what requires a search?, Mesh resolution and regularization belong together, What we have learned, and what comes next
- [Tutorial 3: Borders](scripts/chapter_3_pixelizations/tutorial_3_borders.py): (no summary in script docstring)
- Contents: Why the extent of the source mesh matters, What we mean by a border, Starting without border relocation, Including the central image pixels, Following the central pixels into the source plane, Tracing the outer border, Switching border relocation on, What relocation changes—and what it does not, The mask still needs to cover the lensed source, Wrap up
- [Tutorial 4: Lens Modeling](scripts/chapter_3_pixelizations/tutorial_4_lens_modeling.py): (no summary in script docstring)
- Contents: Lens modelling with a pixelized source, Giving the inversion an incorrect mass model, Comparing with the correct mass model, Seeing how the mass model changes the mappings, Why evidence does not remove the search difficulty, Starting with a simpler source model, Running and inspecting the initial search, Requiring corresponding images to trace together, Replacing the analytic source with a pixelization, Running the pixelized-source search, Establishing the foreground light model, Using that result in the pixelized-source fit
- [Tutorial 8: Adaptive Pixelization](scripts/chapter_3_pixelizations/tutorial_8_adaptive_pixelization.py): In this tutorial we will introduce a new `Pixelization` object, which uses an `Overlay` image-mesh and a `Delaunay` mesh.
- Contents: Initial Setup, Advantages and Disadvantages, Image Mesh, Regularization, Source Compactness, Wrap Up
- [Tutorial 1: Pixelizations, Mappers and Inversions](scripts/chapter_3_pixelizations/tutorial_1_pixelizations.py): Reconstruct a complex source using pixelizations, image-to-source mappings and a linear inversion.
- Contents: Opening — Pixelized source reconstruction, A complex source, Why a simple source model falls short, A grid for the source light, Following the same image pixels into the source plane, Where a traced image pixel meets the source mesh, One source region, several image regions, Reconstructing the source, A first look at regularization, From source indexes to reconstructed brightnesses, Keeping source brightnesses non-negative, Where the image weakly constrains the source, Turning the reconstructed source back into an image, Inspecting the reconstruction, Changing the source resolution, Wrap up
- [Tutorial 2: Bayesian Regularization](scripts/chapter_3_pixelizations/tutorial_2_bayesian_regularization.py): Explore regularization and use Bayesian evidence to choose its strength for a source reconstruction.
- Contents: Interpolation and Bayesian regularization, Interpolation and our starting reconstruction, Reducing regularization, Increasing regularization, Bayesian evidence, Choosing the coefficient, Exploring the regularization coefficient, Inspecting the preferred reconstruction, What is linear, and what requires a search?, Mesh resolution and regularization belong together, Wrap Up
- [Tutorial 3: Borders](scripts/chapter_3_pixelizations/tutorial_3_borders.py): Explore how masks and border relocation affect the extent and resolution of a source mesh.
- Contents: Why the extent of the source mesh matters, What we mean by a border, Starting without border relocation, Including the central image pixels, Following the central pixels into the source plane, Tracing the outer border, Switching border relocation on, What relocation changes, The mask still needs to cover the lensed source, Wrap Up
- [Tutorial 4: Lens Modeling](scripts/chapter_3_pixelizations/tutorial_4_lens_modeling.py): Fit lens mass and foreground light alongside a pixelized source using search chaining and a positions likelihood penalty.
- Contents: Lens modelling with a pixelized source, Giving the inversion an incorrect mass model, Comparing with the correct mass model, Seeing how the mass model changes the mappings, Why evidence does not remove the search difficulty, Starting with a simpler source model, Running and inspecting the initial search, Requiring corresponding images to trace together, Replacing the analytic source with a pixelization, Running the pixelized-source search, Establishing the foreground light model, Using that result in the pixelized-source fit, Wrap Up
- [Tutorial 5: Fit Problems](scripts/chapter_3_pixelizations/tutorial_5_fit_problems.py): Investigate why compact sources can challenge mesh resolution and constant regularization even when the mass model is correct.
- Contents: When the best coefficient is not enough, Three progressively compact sources, Simulating the images, Reconstructing the sources, Finding the preferred regularization, Starting with the extended source, Making the source more compact, A very compact source, Why the mesh becomes a limitation, Why one regularization coefficient becomes a compromise, Why maximizing the evidence does not remove the compromise, Wrap Up
- [Tutorial 6: Adaptive Reconstruction](scripts/chapter_3_pixelizations/tutorial_6_adaptive_reconstruction.py): Combine Delaunay meshes, Hilbert brightness adaptation and adaptive Split regularization in a chained lens-model fit.
- Contents: Adaptive source reconstruction, Returning to the compact-source problem, From an image mesh to a source mesh, Constructing the Delaunay source mesh, Interpolating within a triangle, Regularization on an irregular mesh, Building an adapt image, Placing points with a Hilbert image mesh, Controlling the brightness weighting, Keeping resolution in the faint regions, Reconstructing with the Hilbert mesh, Comparing overlay and Hilbert reconstructions, Smoothing on an irregular mesh, Reconstructing with ConstantSplit, Allowing different smoothing strengths, Controlling the transition with `signal_scale`, Exploring the adaptive coefficients, Does adaptive regularization address the fit problem?, Starting the final modelling chain, Preparing adaptation and the positions likelihood penalty, Defining the adaptive Delaunay model, Running the adaptive Delaunay fit, Inspecting the source and smoothing pattern, Wrap Up

## chapter_4_scaling_up_lensing

Expand Down
7 changes: 2 additions & 5 deletions notebooks/chapter_3_pixelizations/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,5 @@ MGE remains valuable, especially for foreground lens light and initial source fi
- [Borders](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_3_borders.ipynb)
- [Lens Modeling](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_4_lens_modeling.ipynb)

The following tutorials explore adaptive meshes and regularization:

- [Adaptive Pixelization](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_8_adaptive_pixelization.ipynb)
- [Brightness Adaption](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_11_brightness_adaption.ipynb)
- [Adaptive Regularization](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_12_adaptive_regularization.ipynb)
- [Fit Problems](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_5_fit_problems.ipynb)
- [Adaptive Reconstruction](https://colab.research.google.com/github/PyAutoLabs/HowToLens/blob/main/notebooks/chapter_3_pixelizations/tutorial_6_adaptive_reconstruction.ipynb)
Loading
Loading