rail.utils.testing_utils module
Utility functions to test alogrithms
- rail.utils.testing_utils.build_and_read_pipeline(pipeline_class, **kwargs)
- Parameters:
pipeline_class (str)
kwargs (Any)
- Return type:
None
- rail.utils.testing_utils.check_stage_params(stage_class)
- Parameters:
stage_class (type[RailStage])
- Return type:
str | None
- rail.utils.testing_utils.one_algo(key, single_trainer, single_estimator, train_kwargs, estim_kwargs, is_classifier=False)
A basic test of running an estimator subclass. Run inform, write temporary trained model to ‘tempmodelfile.tmp’, run photo-z algorithm. Then, load tempmodelfile.tmp and re-run, return both datasets.
- Parameters:
key (str)
single_trainer (type[CatInformer])
single_estimator (type[CatEstimator])
train_kwargs (dict)
estim_kwargs (dict)
is_classifier (bool)
- Return type:
Any