caikit.interfaces.ts.data_model.backends.base ============================================= .. py:module:: caikit.interfaces.ts.data_model.backends.base .. autoapi-nested-parse:: Base classes to share between data model backends Attributes ---------- .. autoapisummary:: caikit.interfaces.ts.data_model.backends.base.log caikit.interfaces.ts.data_model.backends.base.error Classes ------- .. autoapisummary:: caikit.interfaces.ts.data_model.backends.base.UncachedBackendMixin caikit.interfaces.ts.data_model.backends.base.StrictFieldBackendMixin caikit.interfaces.ts.data_model.backends.base.TimeSeriesBackendBase caikit.interfaces.ts.data_model.backends.base.MultiTimeSeriesBackendBase Module Contents --------------- .. py:data:: log .. py:data:: error .. py:class:: UncachedBackendMixin Bases: :py:obj:`caikit.core.data_model.data_backends.DataModelBackendBase` Intermediate base class that disables attribute caching .. py:method:: cache_attribute(*_, **__) -> bool Never cache attributes .. py:class:: StrictFieldBackendMixin Bases: :py:obj:`caikit.core.data_model.data_backends.DataModelBackendBase` Intermediate base class that raises attribute errors for unknown fields .. py:method:: get_attribute(data_model_class: Type, name: str) -> Any Base implementation that raises an AttributeError on bad attr names. It should be called after object-specific logic. .. py:class:: TimeSeriesBackendBase Bases: :py:obj:`UncachedBackendMixin`, :py:obj:`StrictFieldBackendMixin` Abstract base class for all backends of the central TimeSeries data model type .. py:method:: as_pandas() -> Tuple[pandas.DataFrame, str, Iterable[str]] :abstractmethod: All backends must implement the ability to coerce their underlying data into a pandas DataFrame and provide the pointers to the timeseries source and value source(s) Returns: df: pd.DataFrame The data frame itself timestamp_source: str The column name (or None) indicating where the timestamp sequence can be found value_source: Iterable[str] The names of the columns holding value sequences .. py:class:: MultiTimeSeriesBackendBase Bases: :py:obj:`UncachedBackendMixin`, :py:obj:`StrictFieldBackendMixin` Abstract base class for all backends of the central MultiTimeSeries data model type .. py:method:: as_pandas() -> Tuple[pandas.DataFrame, Iterable[str], str, Iterable[str]] :abstractmethod: All backends must implement the ability to coerce their underlying data into a pandas DataFrame and provide the pointers to the timeseries source and value source(s) Returns: df: pd.DataFrame The data frame itself key_source: Iterable[str] the names of the columns holding key values timestamp_source: str The column name (or None) indicating where the timestamp sequence can be found value_source: Iterable[str] The names of the columns holding value sequences