simrunmodular_reduced_model_inferencereduced_modelDataSplitEvaluationadd_random_split

DataSplitEvaluation.add_random_split

simrun.modular_reduced_model_inference.reduced_model.DataSplitEvaluation.add_random_split(name, percentage_train=0.7, l=None)

Set the train-test split randomly.

Parameters:
  • name (str) – Name of the split

  • percentage_train (float) – Percentage of trials to use for training

  • l (list) – List of indices to use for the split. If None, use all trials.

Raises:

AssertionError – If the split name already exists.