InventoryModel

class of dascore.models.base
inherits from: DascoreBaseModel, pydantic.main.BaseModel
source

InventoryModel(
    description: str = ““,
    extra_fields: collections.abc.Mapping[str, str | int | float | bool[str, int, float, bool]] = ,
)-> None

Base class for immutable DASDAE inventory objects.

Every inventory object carries two uniform attachment points for information the model does not otherwise represent: description (free prose for humans, matching StationXML’s Description element) and extra_fields (typed key-values, e.g. for round-tripping unmodeled metadata from external formats).

Every field is immutable: collections are tuples and mappings are frozen, so instances are safe to hold by reference. They hash on their field values whenever those values are themselves hashable.

Methods

Name Description
get_summary_df Get dataframe of attributes and descriptions for display.
new Create a new instance with some attributes updated.
get_summary_df Get dataframe of attributes and descriptions for display.