Skip to content

Commit

Permalink
Update README for coolest.api
Browse files Browse the repository at this point in the history
  • Loading branch information
aymgal committed Apr 18, 2024
1 parent dad1cca commit 60828b6
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
19 changes: 5 additions & 14 deletions coolest/api/README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,13 @@
# COOLEST API: `coolest.api` submodule

## Analysis with `coolest.api.analysis`

## Analysis: `coolest.api.analysis`
Based on a `coolest` object, the `Analysis` class handles computation of model-independent quantities, including the Einstein radius, mass density slope, effective radius, axis ratio from central moments, etc.

- load the content of a COOLEST file
- perform computations of model-independent quantities:
- effective Einstein radius
- effective mass density slope
- effective (half-light) radius
## Models: `coolest.api.composable_model`

Based on a `coolest` object, a "composable model" selects the required light and mass model components, and performs lens model computations, including convolution by the PSF, ray-tracing and supersampling.

## Plotting: `coolest.api.plotting`

- instantiate an `Analysis` object from a COOLEST file
- defines general settings for all plots (colors, cmaps, etc...)
- could have child classes
- Obervationlotter(Plotter)
- LightPlotter(Plotter)
- LensLightPlotter(LightPlotter)
- SourcePlotter(LightPlotter)
- MassPlotter(Plotter)
The plotting routines, separated into different classes, allow the user to visualize the lens models, optionally evaluating the model components on different types of grid (`ModelPlotter`, `MultiModelPlotter`), or generate posterior distributions plots (`ParametersPlotter`).
4 changes: 4 additions & 0 deletions coolest/api/analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@
# logging settings
logging.getLogger().setLevel(logging.INFO)

__all__ = [
'Analysis',
]

class Analysis(object):
"""Handles computation of model-independent quantities
and other analysis computations.
Expand Down
5 changes: 5 additions & 0 deletions coolest/api/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@

# TODO: separate ParametersPlotter from ModelPlotter to avoid dependencies on getdist

__all__ = [
'ModelPlotter',
'MultiModelPlotter',
'ParametersPlotter',
]

class ModelPlotter(object):
"""Create pyplot panels from a lens model stored in the COOLEST format.
Expand Down
File renamed without changes.

0 comments on commit 60828b6

Please sign in to comment.