feat(Config): feature extractors are enabled one-by-one with a bool, added previous model to model.fit() (#77)

* feat(Config): feature extractors are enabled one-by-one with a bool, added previous model to model.fit()

* fix(Sweep): removed unused `other_features` parameter that fails sweep

* feat(Config): using preset names for defining feature extractors again

* fix(Tests): fixed model stub classes
This commit is contained in:
Mark Aron Szulyovszky
2021-12-23 10:35:20 +01:00
committed by GitHub
parent 6ae8acf70e
commit b6cd6b14fe
14 changed files with 78 additions and 44 deletions
+1 -1
View File
@@ -10,7 +10,7 @@ class StaticAverageModel(Model):
data_scaling = 'unscaled'
only_column = 'model_'
def fit(self, X, y):
def fit(self, X, y, prev_model):
# This is a static model, it can' learn anything
pass
+2 -2
View File
@@ -11,7 +11,7 @@ class Model(ABC):
only_column: Optional[str]
@abstractmethod
def fit(self, X, y):
def fit(self, X, y, prev_model):
pass
@abstractmethod
@@ -32,7 +32,7 @@ class SKLearnModel(Model):
def __init__(self, model):
self.model = model
def fit(self, X, y):
def fit(self, X, y, prev_model):
self.model.fit(X, y)
def predict(self, X):
+1 -1
View File
@@ -14,7 +14,7 @@ class StaticMomentumModel(Model):
super().__init__()
self.allow_short = allow_short
def fit(self, X, y):
def fit(self, X, y, prev_model):
# This is a static model, it can' learn anything
pass
+1 -1
View File
@@ -10,7 +10,7 @@ class StaticNaiveModel(Model):
data_scaling = 'unscaled'
only_column = None
def fit(self, X, y):
def fit(self, X, y, prev_model):
# This is a static model, it can' learn anything
pass