Closed bakhtos closed 4 months ago
Reset this PR to the situation where train_MODELNAME
functions are still available and existing scripts using them would not break AND train_model
can now accept arbitrary model class and its kwargs while retaining backwards-compatibility with some scripts that could have used the previous version.
This version is only 3 commits ahead of #18
The PR is ready.
train_model
function now accepts a model class and its kwargs
train_*
functions use the new way to call the train_model
function.train_*
functions are cleaned up`evaluate_all_ads
uses a set comprehension internally to iterate over all train_*
functions.
Fixes #15 Only accept this PR after closing #18.
Many
train_MODEL
functions inAnomalyDetection
are refactored away. Instead, a single functiontrain_model
accepts a model class and keyword arguments that should be passed to the model constructor.train_model
populates the keyword arguments with the default values that were used intrain_MODEL
functions. This allows to pass any model to theAnomalyDetection
class, as well as give any kwargs to models that were already implemented before.