gravelamps.lensing.strong_event_handling
Gravelamps Strong Lensing Event Handling
Following are functions that are model agnostic and used to handle interactions between strong lensing events and the model specific functions within the rest of the module.
Routines
- get_event_signal
Generate interferometer signal data from provided information
- get_model_generator
Create Waveform Generator for specific model to be used for likelihood calculations
- generate_source_position_interpolator
Generate interpolator function which maps relative magnification to source position.
- observables_to_model_parameters
Convert lensing observables to model specific parameters
- generate_probability_interpolator
Generate interpolator function object mapping source position and redshifted lnes mass to the probability of both occurring.
Functions
|
Generate interferometer signal data from provided information |
|
Create Waveform Generator for specific model to be used for likelihood calculations |
|
Generate interpolator function which maps relative magnification to source position. |
|
Convert lensing observables to model specific parameters |
|
Generate interpolator function object mapping source position and redshifted lnes mass to the |
Module Contents
- gravelamps.lensing.strong_event_handling.get_event_signal(args, event_data)
Generate interferometer signal data from provided information
User flags also allow the plotting of interferometric data and in the case of injections, the plotting of the true signal data.
- Parameters:
- argsargparse.Namespace
Object containing commandline arguments to the program
- event_datadict
Information about the event
- Returns:
- interferometersbilby.gw.detector.InterferometerList
Object containing interferometer data for specified detectors
- gravelamps.lensing.strong_event_handling.get_model_generator(args, module, event_data)
Create Waveform Generator for specific model to be used for likelihood calculations
Flags will also allow the plotting of the frequency domain strain for injections
- Parameters:
- argsargparse.Namespace
Object containing commandline arguments to the program
- modulemodule
Module containing lens model functions
- event_datadict
Information about the event
- Returns:
- lensed_waveform_generatorgravelamps.lensing.waveform_generator.SingleImageGenerator
Object containing signal data
- gravelamps.lensing.strong_event_handling.generate_source_position_interpolator(module, source_position_array, plot=False)
Generate interpolator function which maps relative magnification to source position.
- Parameters:
- modulemodule
Module containing lens model functions
- source_position_arrayArrayLike
Source position range over which to generate interpolator
- plotbool, optional
Generate plot of data that forms interpolator. Default is false
- Returns:
- source_position_interpolatorscipy.interpolate.interp1d
Interpolating function taking relative magnification and returning source position
- gravelamps.lensing.strong_event_handling.observables_to_model_parameters(module, args, relative_magnification_data, time_delay_data)
Convert lensing observables to model specific parameters
- Parameters:
- modulemodule
Module containing lens model functions
- argsargparse.Namespace
Object containing commandline arguments to the program
- relative_magnification_dataArrayLike
Sample relative magnification values
- time_delay_dataArrayLike
Sample time delay values
- Returns:
- source_position_dataArrayLike
Calculated sample source position values
- mass_dataArrayLike
Calculated sample redshited lens mass values
- gravelamps.lensing.strong_event_handling.generate_probability_interpolator(source_position_data, mass_data, number_of_bins=30, plot=False, model=None)
Generate interpolator function object mapping source position and redshifted lnes mass to the probability of both occurring.
This is done by taking a normalised histogram of the occurrances of each parameter in the data. User flag allows the plotting of the histogram data that forms the basis fo the interpolator.