- feature_files = Path.cwd() / 'config' / 'features'
- self._features = {feat : {'numerical': False} for feat in self._features}
- for feature_file in listdir(feature_files):
- if feature_file.endswith('csv'):
- with open(feature_files / feature_file , "r") as f:
- reader = DictReader(f, delimiter=',')
- typed_names = {row['name']: row['type'] for row in reader}
- for feature in self._features:
- if feature.split('_')[0] in typed_names:
- self._features[feature]['type'] = int(typed_names[feature.split('_')[0]])
- elif feature_file.endswith('cfg'):
+ #feature_files = Path.cwd() / 'config' / 'features'
+ self._features = {feat : {'numerical': False, 'categorical': False}
+ for feat in self._features}
+
+ for feature in self._config['FEATURES']:
+ if self._config['FEATURES'][feature]:
+ feature_file = self._config['FEATURE_CONFIG'][feature]