Viewer¶
- class eazy.hdf5.Viewer(h5file, verbose=True)[source]¶
Bases:
object
Tool to replicate functionality of
PhotoZ.show_fit
but with data read from a stored HDF5 file rather than a “live” objectAttributes Summary
Array data type from
ARRAY_NBITS
parameterGalactic extinction E(B-V)
Filter pivot wavelengths (deprecated, use
pivot
)Conversion factor to \(10^{-19} erg/s/cm^2/Å\)
Conversion of observed fluxes to
microJansky
Methods Summary
Create a full catalog table from the photometry data in the HDF5 file
get_dataset
(name[, sl, verbose])Get a single column of data from the HDF5 file
get_lnp
(ix)Compute ln P(z) directly from chi2.
get_object_data
(ix)Pull out data for a given array index (not id!) corresponding to a particular object
get_table
(names[, sl, verbose, strip_slash, ...])Build a table from multiple dataset names
info
()Print file contents
Set additional attributes needed for the Dash/Plotly tool.
Set fixed attributes needed for
show_fit
Generate the
eazy.photoz.TemlpateGrid
object needed for plotting SEDs and refitting at other redshifts.Set the Template Error Function from
fit/tef_x
andfit/tef_y
data in the HDF5 fileshow_fit
(id, **kwargs)Wrapper around
eazy.photoz.PhotoZ.show_fit
show_fit_plotly
(id, **kwargs)Wrapper around
eazy.photoz.PhotoZ.show_fit_plotly
Attributes Documentation
- ARRAY_DTYPE¶
Array data type from
ARRAY_NBITS
parameter
- MW_EBV¶
Galactic extinction E(B-V)
- lc¶
Filter pivot wavelengths (deprecated, use
pivot
)
- to_flam¶
Conversion factor to \(10^{-19} erg/s/cm^2/Å\)
- to_uJy¶
Conversion of observed fluxes to
microJansky
Methods Documentation
- get_dataset(name, sl=None, verbose=True)[source]¶
Get a single column of data from the HDF5 file
If
name
is in theself.flux_columns
orself.err_columns
lists, then compute the appropriate index of thefit/fnu
orfit/efnu_orig
datasets, respectively.- Parameters:
- namestr
Dataset name in
h5file
- slslice-like
Array slice
- verbosebool
Print some status info
- Returns:
- dataarray-like
Sliced dataset data
- get_object_data(ix)[source]¶
Pull out data for a given array index (not id!) corresponding to a particular object
- Returns:
- z_i, fnu_i, efnu_i, ra_i, dec_i, chi2_i, zspec_i, ok_i
- get_table(names, sl=None, verbose=True, strip_slash=True, as_table=True)[source]¶
Build a table from multiple dataset names
- Parameters:
- namesstr
Dataset names in
h5file
- slslice-like
Array slice
- verbosebool
Print some status info
- Returns:
- dataarray-like
Sliced dataset data
- set_attrs_for_dash()[source]¶
Set additional attributes needed for the Dash/Plotly tool. They’re not set in
set_attrs_from_hdf5
as they may be memory-intensive for very large catalogs and aren’t explicitly necessary for justshow_fit
showing SEDs.
- set_tempfilt()[source]¶
Generate the
eazy.photoz.TemlpateGrid
object needed for plotting SEDs and refitting at other redshifts.
- set_template_error()[source]¶
Set the Template Error Function from
fit/tef_x
andfit/tef_y
data in the HDF5 file- Returns:
- Sets
TEF
attributes
- Sets
- show_fit(id, **kwargs)[source]¶
Wrapper around
eazy.photoz.PhotoZ.show_fit
- show_fit_plotly(id, **kwargs)[source]¶
Wrapper around
eazy.photoz.PhotoZ.show_fit_plotly