API for the glworia.amp.interpolate
module
interpolate(settings, save_dir=None, strong=True, weak=True, interp_crit=True)
Interpolate the time domain amplification factor and save the interpolation tables.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
settings |
Dict[str, Union[str, int, float]]
|
a dictionary containing the settings for the interpolation. |
required |
save_dir |
Optional[str]
|
the directory to save the interpolation tables. |
None
|
strong |
bool
|
whether to compute and interpolate the strong-lensing points. |
True
|
weak |
bool
|
whether to compute and interpolate the weak-lensing points. |
True
|
interp_crit |
bool
|
whether to interpolate the caustic curve. |
True
|
interpolate_im(settings, save_dir=None)
Interpolate the time delay and magnification of images.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
settings |
Dict[str, Union[str, float, int]]
|
a dictionary containing the settings for the interpolation. |
required |
save_dir |
Optional[str]
|
the directory to save the interpolation tables. |
None
|
make_grid_points(settings, functions_dict=None, mid_point=False)
Make the interpolation node grid points of the amplification factor.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
settings |
Dict[str, Union[str, float, int]]
|
a dictionary containing the settings for the interpolation. |
required |
functions_dict |
Optional[Dict[str, Dict[str, Callable]]]
|
a dictionary of dictionaries containing relevant functions for computing the amplification factor. |
None
|
mid_point |
bool
|
whether to use the mid-points of the grid instead of the grid points themselves. Useful for estimating the error of the interpolation. |
False
|
Returns:
Name | Type | Description |
---|---|---|
weak_points |
ndarray
|
the interpolation nodes in the weak-lensing regime. |
strong_points |
ndarray
|
the interpolation nodes in the strong-lensing regime. |
crit_points_in_bound |
ndarray
|
the interpolation nodes on the caustic curve. |
crit_T_vir |
ndarray
|
the time delay of the saddle/maximum image on the caustic curve. The saddle and maximum images merge on the caustic. |
lens_param_to_y_crit |
Callable
|
a function that maps the lens parameter to y on the caustic curve. |