thbndi commited on
Commit
6489a03
1 Parent(s): b361960

Update Mimic4Dataset.py

Browse files
Files changed (1) hide show
  1. Mimic4Dataset.py +3 -6
Mimic4Dataset.py CHANGED
@@ -185,19 +185,16 @@ class Mimic4Dataset(datasets.GeneratorBasedBuilder):
185
  if not os.path.exists('./preprocessing/day_intervals_preproc/day_intervals_cohort_v22.py'):
186
  file_path, head = urlretrieve(_DAY_INT, "day_intervals_cohort_v22.py")
187
  shutil.move(file_path, './preprocessing/day_intervals_preproc')
188
- print(self.config.name)
189
- print(os.getcwd())
190
  file_path, head = urlretrieve(_COHORT, "cohort.py")
191
  if not os.path.exists('cohort.py'):
192
  shutil.move(file_path, './')
193
 
194
- data_dir = "./data/dataDic"
195
  sys.path.append(path_bench)
196
  config = self.config_path.split('/')[-1]
197
  script = 'python cohort.py '+ self.config.name +" "+ self.mimic_path+ " "+path_bench+ " "+config
198
- #os.system(script)
199
- print('script : '+script)
200
- print('last pos'+os.getcwd())
201
  return [
202
  datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"filepath": data_dir}),
203
  ]
 
185
  if not os.path.exists('./preprocessing/day_intervals_preproc/day_intervals_cohort_v22.py'):
186
  file_path, head = urlretrieve(_DAY_INT, "day_intervals_cohort_v22.py")
187
  shutil.move(file_path, './preprocessing/day_intervals_preproc')
188
+
 
189
  file_path, head = urlretrieve(_COHORT, "cohort.py")
190
  if not os.path.exists('cohort.py'):
191
  shutil.move(file_path, './')
192
 
193
+ data_dir = "./data/dict/"+self.config.name+"/dataDic"
194
  sys.path.append(path_bench)
195
  config = self.config_path.split('/')[-1]
196
  script = 'python cohort.py '+ self.config.name +" "+ self.mimic_path+ " "+path_bench+ " "+config
197
+ os.system(script)
 
 
198
  return [
199
  datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"filepath": data_dir}),
200
  ]