Update Mimic4Dataset.py
Browse files- Mimic4Dataset.py +2 -2
Mimic4Dataset.py
CHANGED
@@ -10,7 +10,7 @@ from sklearn.model_selection import train_test_split
|
|
10 |
from sklearn.preprocessing import LabelEncoder
|
11 |
import yaml
|
12 |
from .dataset_utils import create_vocab,gender_vocab,vocab, concat_data, generate_deep, generate_ml
|
13 |
-
from .task_cohort import
|
14 |
|
15 |
|
16 |
|
@@ -161,7 +161,7 @@ class Mimic4Dataset(datasets.GeneratorBasedBuilder):
|
|
161 |
|
162 |
#####################create task cohort
|
163 |
if self.generate_cohort:
|
164 |
-
|
165 |
|
166 |
#####################Split data into train, test and val
|
167 |
with open(data_dir, 'rb') as fp:
|
|
|
10 |
from sklearn.preprocessing import LabelEncoder
|
11 |
import yaml
|
12 |
from .dataset_utils import create_vocab,gender_vocab,vocab, concat_data, generate_deep, generate_ml
|
13 |
+
from .task_cohort import create_cohort, check_config_file
|
14 |
|
15 |
|
16 |
|
|
|
161 |
|
162 |
#####################create task cohort
|
163 |
if self.generate_cohort:
|
164 |
+
create_cohort(self.config.name.replace(" ","_"),self.mimic_path,config)
|
165 |
|
166 |
#####################Split data into train, test and val
|
167 |
with open(data_dir, 'rb') as fp:
|