nannyml.usage_logging module

class nannyml.usage_logging.SegmentUsageTracker(write_key: Optional[str] = None, machine_metadata: Optional[Dict[str, Any]] = None)[source]

Bases: UsageLogger

SEGMENT_WRITE_KEY = 'lIVZJNAdj2ZaMzAHHnFWP76g7CuwmzGz'
write_key: str
class nannyml.usage_logging.UsageEvent(value)[source]

Bases: str, Enum

Logged usage events

CBPE_ESTIMATOR_FIT = 'CBPE estimator fit'
CBPE_ESTIMATOR_RUN = 'CBPE estimator run'
CBPE_PLOT = 'CBPE estimator plot'
CLI_RUN = 'CLI run'
DLE_ESTIMATOR_FIT = 'DLE estimator fit'
DLE_ESTIMATOR_RUN = 'DLE estimator run'
DLE_PLOT = 'DLE estimator plot'
MULTIVAR_DRIFT_CALC_FIT = 'Multivariate reconstruction error drift calculator fit'
MULTIVAR_DRIFT_CALC_RUN = 'Multivariate reconstruction error drift calculator run'
MULTIVAR_DRIFT_PLOT = 'Multivariate drift results plot'
PERFORMANCE_CALC_FIT = 'Realized performance calculator fit'
PERFORMANCE_CALC_RUN = 'Realized performance calculator run'
PERFORMANCE_PLOT = 'Realized performance calculator plot'
UNIVAR_DRIFT_CALC_FIT = 'Univariate drift calculator fit'
UNIVAR_DRIFT_CALC_RUN = 'Univariate drift calculator run'
UNIVAR_DRIFT_PLOT = 'Univariate drift results plot'
WRITE_DB = 'Exported results with DatabaseWriter'
WRITE_PICKLE = 'Exported results with PickleWriter'
WRITE_RAW = 'Exported results with RawFilesWriter'
class nannyml.usage_logging.UsageLogger[source]

Bases: ABC

log(usage_event: UsageEvent, metadata: Optional[Dict[str, Any]] = None)[source]
nannyml.usage_logging.disable_usage_logging()[source]
nannyml.usage_logging.enable_usage_logging()[source]
nannyml.usage_logging.get_logger() UsageLogger[source]
nannyml.usage_logging.log_usage(usage_event: ~nannyml.usage_logging.UsageEvent, metadata: ~typing.Optional[~typing.Dict[str, ~typing.Any]] = None, metadata_from_self: ~typing.Optional[~typing.List[str]] = None, metadata_from_kwargs: ~typing.Optional[~typing.List[str]] = None, logger: ~nannyml.usage_logging.UsageLogger = <nannyml.usage_logging.SegmentUsageTracker object>)[source]