pdmlabs.loadAnomalyDetectionDataset#

Functions

create_preferencies(labels, datalabels, ...)

generate_RUL_labels(dataset[, cut_off, ...])

generate_labels(dataset)

load_dataset_from_dataframe(df, labels_col)

load_dataset_single_source_dataframe(dfor, ...)

load_pickle(name[, generate_labels])

load_run_to_failure(column_of_timestamp, ...)

Used for Run to failure datasets :param list_df: :type list_df: list of dataframes with data (each one ending in falure) :param predictive_horizon: :type predictive_horizon: the predictive horizon before the failure, to consider valid alarms (e.g. '10 days','5 minutes') :param max_wait_time: :type max_wait_time: maximum value for the length of the initial data to consider for training in online flavor and sliding.

pdmlabs.loadAnomalyDetectionDataset.create_preferencies(labels, datalabels, source_name)#
pdmlabs.loadAnomalyDetectionDataset.generate_RUL_labels(dataset, cut_off=0, percentage=True)#
pdmlabs.loadAnomalyDetectionDataset.generate_labels(dataset)#
pdmlabs.loadAnomalyDetectionDataset.load_dataset_from_dataframe(df, labels_col, index_col=None, source_column=None, reset_after_anomaly=False)#
Parameters:
  • df – data (along with timestamps and labels

  • labels_col – column with label

  • index_col – column of dates to index the timeseries

  • source_column – column that indicates different sources (that should be separated)

  • reset_after_anomaly – weather we should trigger rest event after anomaly (e.g. to fit again in some experiemnts)

Returns:

pdmlabs.loadAnomalyDetectionDataset.load_dataset_single_source_dataframe(dfor, labels_col, index_col, source_name)#
pdmlabs.loadAnomalyDetectionDataset.load_pickle(name, generate_labels=False)#
pdmlabs.loadAnomalyDetectionDataset.load_run_to_failure(column_of_timestamp, list_df, predictive_horizon, sources_names=None, max_wait_time=0.1, lead='1 seconds', slide=10)#

Used for Run to failure datasets :param list_df: :type list_df: list of dataframes with data (each one ending in falure) :param predictive_horizon: :type predictive_horizon: the predictive horizon before the failure, to consider valid alarms (e.g. ‘10 days’,’5 minutes’) :param max_wait_time: :type max_wait_time: maximum value for the length of the initial data to consider for training in online flavor and sliding. Either portion (<1) or the length e.g. 0.1, 100. :param lead: :type lead: the lead time before the failure, to ignore alarms too close to failures (e.g. ‘10 days’,’5 minutes’) :param slide: :type slide: the slide parameter for VUS :param sources_names: :type sources_names: the name of each df (default none), if set to value need to be same length as list_df. :param Returns dataset dictionary: :param ——-: