ctapipe is not stable yet, so expect large and rapid changes to structure and functionality as we explore various design choices before the 1.0 release.

Traitlet Implementations for ctapipe#

Introduction#

Custom Traitlets implemented for ctapipe.

Reference/API#

ctapipe.core.traits Module#

Traitlet implementations for ctapipe

Functions#

classes_with_traits(base_class)

Returns a list of the base class plus its non-abstract children if they have traits

create_class_enum_trait(base_class, ...[, ...])

create a configurable CaselessStrEnum traitlet from baseclass

has_traits(cls[, ignore])

True if cls has any traits apart from the usual ones

flag(name, configurable[, set_help, unset_help])

Helper for building basic --trait, --no-trait flags.

observe(*names[, type])

A decorator which can be used to observe Traits on a class.

Classes#

AstroQuantity([physical_type])

A trait containing an astropy.units quantity.

AstroTime([default_value, allow_none, ...])

A trait representing a point in Time, as understood by astropy.time.

BoolTelescopeParameter(**kwargs)

a TelescopeParameter with Bool trait type

IntTelescopeParameter(**kwargs)

a TelescopeParameter with Int trait type

FloatTelescopeParameter(**kwargs)

a TelescopeParameter with Float trait type

Path([default_value, exists, directory_ok, ...])

A path Trait for input/output files.

Bool([default_value, allow_none, read_only, ...])

A boolean (True, False) trait.

CRegExp([default_value, allow_none, ...])

A casting compiled regular expression trait.

CaselessStrEnum(values[, default_value])

An enum of strings where the case should be ignored.

CInt([default_value, allow_none, read_only, ...])

A casting version of the int trait.

Dict()

An instance of a Python dict.

Enum(values[, default_value, allow_none, ...])

An enum whose value must be in a given sequence.

Float([default_value, allow_none, ...])

A float trait.

Int

alias of Int

Integer

alias of Int

List()

An instance of a Python list.

Long([default_value, allow_none, read_only, ...])

An int trait.

Set()

An instance of a Python set.

TraitError

Tuple()

An instance of a Python tuple.

Unicode([default_value, allow_none, ...])

A trait for unicode strings.