Chapter 2: Lens Modeling
========================

In chapter 2, we'll take you through how to model strong lenses using a non-linear search.

You can start the tutorials right now by going to `our binder <https://mybinder.org/v2/gh/Jammy2211/autolens_workspace/HEAD>`_
and navigating to the folder ``notebooks/howtolens/chapter_2_lens_modeling``. They are also on the `autolens_workspace <https://github.com/Jammy2211/autolens_workspace>`_.

The chapter contains the following tutorials:

`Tutorial 1: <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_1_non_linear_search.ipynb>`_
- How a `NonLinearSearch` is used to fit a lens model.

`Tutorial 2: Parameter Space And Priors <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_2_parameter_space_and_priors.ipynb>`_
- The Concepts of a parameter space and priors.

`Tutorial 3: Realism and Complexity <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_3_realism_and_complexity.ipynb>`_
- Finding a balance between realism and complexity when composing a lens model.

`Tutorial 4: Dealing with Failure <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_4_dealing_with_failure.ipynb>`_
- What to do when PyAutoLens finds an inaccurate lens model.

`Tutorial 5: Linking Phases <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_5_linking_phases.ipynb>`_
- Breaking the lens modeling procedure down into multiple fits.

`Tutorial 6: Alternative Searches  <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_6_alternative_searches.ipynb>`_
- Using different non-linear searches to sample parameter space.

`Tutorial 7: Masking and Positions <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_7_masking_and_positions.ipynb>`_
- How to mask and mark positions on your ``data`` to improve the lens model.

`Tutorial 8: Results <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_8_results.ipynb>`_
- Overview of the results available after successfully fitting a lens model.

`Tutorial 9: Need for Speed <https://github.com/Jammy2211/autolens_workspace/blob/master/notebooks/howtolens/chapter_2_lens_modeling/tutorial_9_need_for_speed.ipynb>`_
- How to fit complex models whilst balancing efficiency and run-time.