TsoPhotModel

class stdatamodels.jwst.datamodels.TsoPhotModel(init=None, radii=None, **kwargs)

Bases: ReferenceFileModel

A model for a reference file of type “tsophot”.

Initialize the model.

Parameters:
initstr, tuple, ~astropy.io.fits.HDUList, ndarray, dict, None, optional

The data from which to initialize the model. Can be of any type that is supported by DataModel.

radiilist, optional

List of one or more dictionaries, each with keys ‘pupil’, ‘radius’, ‘radius_inner’, and ‘radius_outer’.

**kwargs

Additional keyword arguments passed to ReferenceFileModel.

Attributes Summary

reftype

schema_url

The schema URI to validate the model against.

Methods Summary

on_save([path])

Run a hook before writing a model to a file (FITS or ASDF).

to_fits()

Write a data model to a FITS file.

validate()

Check that required reference file keywords are set.

Attributes Documentation

reftype = 'tsophot'
schema_url = 'http://stsci.edu/schemas/jwst_datamodel/tsophot.schema'

The schema URI to validate the model against. If None, only basic validation of required metadata properties (filename, model_type) will occur.

Methods Documentation

on_save(path=None)

Run a hook before writing a model to a file (FITS or ASDF).

Parameters:
initstr

The path to the file that we’re about to save to.

to_fits()

Write a data model to a FITS file.

Parameters:
initfile path or file object

The file to write to.

*args

Additional positional arguments passed to astropy.io.fits.writeto.

**kwargs

Additional keyword arguments passed to astropy.io.fits.writeto.

validate()

Check that required reference file keywords are set.