threeML.utils.photometry package

Submodules

threeML.utils.photometry.filter_library module

class threeML.utils.photometry.filter_library.FilterLibrary[source]

Bases: object

property instruments
class threeML.utils.photometry.filter_library.ObservatoryNode(sub_dict)[source]

Bases: object

threeML.utils.photometry.filter_library.get_photometric_filter_library()[source]

Get the 3ML filter library

threeML.utils.photometry.filter_library.get_speclite_filter_library() Path[source]
threeML.utils.photometry.filter_library.get_speclite_filter_path() Path[source]

threeML.utils.photometry.filter_set module

class threeML.utils.photometry.filter_set.FilterSet(filter, mask=None)[source]

Bases: object

ab_magnitudes()[source]

return the effective stimulus of the model and filter for the given magnitude system :return: np.ndarray of ab magnitudes

property effective_wavelength

the average wave length of the filters

Type:

return

property filter_names

the filter names

Type:

return

property n_bands

the number of bands

Type:

return

property native_filter_names

the native filter names :return:

plot_filters()[source]

plot the filter/ transmission curves :return: fig

set_model(differential_flux)[source]

set the model of that will be used during the convolution. Not that speclite considers a differential flux to be in units of erg/s/cm2/lambda so we must convert astromodels into the proper units (using astropy units!)

property speclite_filters

exposes the speclite fitlers for simulations

Returns:

property wavelength_bounds

IntervalSet of FWHM bounds of the filters :return:

property waveunits

the pysynphot wave units

Type:

return

exception threeML.utils.photometry.filter_set.NotASpeclikeFilter[source]

Bases: RuntimeError

threeML.utils.photometry.photometric_observation module

class threeML.utils.photometry.photometric_observation.PhotometericObservation(band_names: List[str], ab_magnitudes: Iterable[float], ab_magnitude_errors: Iterable[float])[source]

Bases: object

classmethod from_dict(data: dict) PhotometericObservation[source]

Create an observation from a dict in the form data = dict(a=(mag, mag_err), b=(mag, mag_err))

classmethod from_hdf5(file_name: str) PhotometericObservation[source]

Load an observation from an hdf5 file

classmethod from_kwargs(**kwargs: dict) PhotometericObservation[source]

Create an observation from a kwargs in the form (a=(mag, mag_err), b=(mag, mag_err))

get_mask_from_filter_sequence(filter_set: FilterSequence) Iterable[bool][source]
is_compatible_with_filter_set(filter_set: Union[FilterSet, FilterSequence]) bool[source]
items()[source]
keys()[source]
to_hdf5(file_name: str, overwrite: bool = False) None[source]

Save the data to an HDF5 file

Module contents