refactor(Training): use date indexes instead of integers, need this to prepare for Events (#185)

This commit is contained in:
Mark Aron Szulyovszky
2022-01-24 12:22:30 +01:00
committed by GitHub
parent e80fffdb65
commit e6e2317fe0
15 changed files with 50 additions and 52 deletions
-5
View File
@@ -27,7 +27,6 @@ class RawConfig(BaseModel):
other_features: list[str]
exogenous_features: list[str]
no_of_classes: Literal['two', 'three-balanced', 'three-imbalanced']
index_column: Literal['date', 'int']
primary_models: list[str]
meta_labeling_models: list[str]
@@ -56,7 +55,6 @@ class Config(BaseModel):
other_features: list[tuple[str, FeatureExtractor, list[int]]]
exogenous_features: list[tuple[str, FeatureExtractor, list[int]]]
no_of_classes: Literal['two', 'three-balanced', 'three-imbalanced']
index_column: Literal['date', 'int']
primary_models: list[tuple[str, Model]]
meta_labeling_models: list[tuple[str, Model]]
@@ -92,7 +90,6 @@ def get_dev_config() -> RawConfig:
own_features = ['level_2', 'date_days'],
other_features = ['single_mom'],
exogenous_features = ['z_score'],
index_column= 'int',
no_of_classes= 'two',
primary_models = classification_models,
@@ -129,7 +126,6 @@ def get_default_ensemble_config() -> RawConfig:
own_features = ['level_2', 'date_days', 'lags_up_to_5'],
other_features = ['level_2', 'lags_up_to_5'],
exogenous_features = ['z_score'],
index_column= 'int',
no_of_classes= 'two',
primary_models = classification_models,
@@ -167,7 +163,6 @@ def get_lightweight_ensemble_config() -> RawConfig:
own_features = ['level_2' ],
other_features = ['level_2'],
exogenous_features = ['z_score'],
index_column= 'int',
no_of_classes= 'two',
primary_models = classification_models,
-1
View File
@@ -17,6 +17,5 @@ def hash_data_config(data_config: dict) -> str:
hash_feature_extractors(data_config['own_features']),
hash_feature_extractors(data_config['other_features']),
hash_feature_extractors(data_config['exogenous_features']),
data_config['index_column'],
data_config['no_of_classes'],
]))
-2
View File
@@ -40,8 +40,6 @@ parameters:
value: True
log_returns:
value: True
index_column:
value: 'int'
primary_models:
distribution: categorical
values:
-2
View File
@@ -46,8 +46,6 @@ parameters:
distribution: categorical
log_returns:
value: True
index_column:
value: 'int'
primary_models:
value: ["LogisticRegression_two_class", "LDA", "KNN", "CART", "NB", "AB", "RFC", "StaticMom"]
meta_labeling_models:
-2
View File
@@ -40,8 +40,6 @@ parameters:
value: True
log_returns:
value: True
index_column:
value: 'int'
primary_models:
values: [['LogisticRegression_two_class'], ['SVC'], ['LDA'], ['KNN'], ['CART'], ['MNB'], ['NB'], ['AB'], ['RFC'], ['XGB_two_class'], ['LGBM']]
distribution: categorical