das.evaluate

das.evaluate.evaluate_probabilities(x, y, model: Optional[tensorflow.python.keras.engine.training.Model] = None, params: Optional[Dict] = None, model_savename: Optional[str] = None, verbose: int = 1)[source]

[summary]

evaluate_probabilities(x, y, model=keras_model, params=params_dict) evaluate_probabilities(x, y, model_savename=save_string) -> will load model and params

Parameters
  • x ([type]) – [description]

  • y ([type]) – [description]

  • model (Union[models.keras.models.Model], optional) – [description]. Defaults to None.

  • params (Union[Dict], optional) – [description]. Defaults to None.

  • model_savename (Union[str], optional) – [description]. Defaults to None.

  • verbose (int, optional) – [description]. Defaults to 1.

Returns

[description]

Return type

[type]

das.evaluate.evaluate_segment_timing(segment_labels_true, segment_labels_pred, samplerate, event_tol)[source]

[summary]

Parameters
  • segment_labels_true ([type]) – [description]

  • segment_labels_pred ([type]) – [description]

  • samplerate ([type]) – Hz [description]

  • event_tol ([type]) – seconds [description]

Returns

[description]

Return type

[type]

das.evaluate.evaluate_segments(labels_test, labels_pred, class_names, confmat_as_pandas: bool = False, report_as_dict: bool = False, labels=None)[source]
Parameters
  • labels_test (List) – [nb_samples,]

  • labels_pred (List) – [nb_samples,]

  • class_names ([type]) – [description]

  • confmat_as_pandas (bool, optional) – [description]. Defaults to False.

  • report_as_dict (bool, optional) – [description]. Defaults to False.

  • labels ([type], optional) – [description]. Defaults to None.

Returns

conf_mat report

das.evaluate.segment_timing(labels, samplerate)[source]

Get onset and offset time (in seconds) for each segment.