chemicalchecker.tool.targetmate.evaluation.validation.BaseValidation

class BaseValidation(splitter, is_cv, is_stratified, n_splits, test_size, explain, model_type, only_train, only_validation, train_size=None, is_tmp=False, is_tmp_bases=True, is_tmp_signatures=True, is_tmp_predictions=True)[source]

Bases: object

Validation class.

Initialize validation class.

Parameters:
  • splitter (object) – If none specified, the corresponding TargetMate splitter is used.

  • is_cv (bool) – If False, a simple train-test split is done.

  • is_stratified (bool) – Do stratified split.

  • n_splits (int) – Number of splits to perform.

  • explain (bool) – Calculate Shapley values for predictions.

  • test_size (float) – Proportion of samples in the test set.

  • is_tmp (bool) – Store all in temporary path

  • is_tmp_bases|signatures|predictions (bool) – Store bases|signatures|predictions in temporary path

Methods

as_dict

fit

gather

get_splits

predict

save

score

setup