File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -967,8 +967,8 @@ def get_formatted_scans_key_row(item):
967
967
mw = ds .wrapper_from_data (dcm .read_file (dcm_fn , stop_before_pixels = True ))
968
968
# we need to store filenames and acquisition times
969
969
# parse date and time and get it into isoformat
970
- date = mw .dcm_data .AcquisitionDate
971
- time = mw .dcm_data .AcquisitionTime .split ('.' )[0 ]
970
+ date = mw .dcm_data .SeriesDate
971
+ time = mw .dcm_data .SeriesTime .split ('.' )[0 ]
972
972
td = time + date
973
973
acq_time = datetime .strptime (td , '%H%M%S%Y%m%d' ).isoformat ()
974
974
# add random string
@@ -1079,8 +1079,9 @@ def tuneup_bids_json_files(json_files):
1079
1079
for jsonfile in json_files :
1080
1080
json_ = json .load (open (jsonfile ))
1081
1081
# sanitize!
1082
- for f in ['AcquisitionDateTime' , 'AcquisitionDate' ]:
1083
- json_ .pop (f , None )
1082
+ for f1 in ['Acquisition' , 'Study' , 'Series' ]:
1083
+ for f2 in ['DateTime' , 'Date' ]:
1084
+ json_ .pop (f1 + f2 , None )
1084
1085
# TODO: should actually be placed into series file which must
1085
1086
# go under annex (not under git) and marked as sensitive
1086
1087
if 'Date' in str (json_ ):
You can’t perform that action at this time.
0 commit comments