You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Hello :) I am trying to convert in BIDS an old dataset acquired with pv 5.1. I created the .csv file and the .json template with bids_helper, but when I tried to convert the dataset with bids_convert I received this error:
Traceback (most recent call last): File "/home/imaging/anaconda3/bin/brkraw", line 8, in <module> sys.exit(main()) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/scripts/brkraw.py", line 476, in main build_bids_json(dset, row, fname, json_fname, slope=slope, offset=offset) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 411, in build_bids_json dset.save_json(row.ScanID, row.RecoID, fname, dir=row.Dir, File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/loader.py", line 548, in save_json json_obj = self._parse_json(scan_id, reco_id, metadata) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/loader.py", line 506, in _parse_json val = meta_get_value(v, acqp, method, visu_pars) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 180, in meta_get_value val = meta_get_value(vi, acqp, method, visu_pars) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 170, in meta_get_value return meta_check_express(value, acqp, method, visu_pars) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 252, in meta_check_express exec('{} = {}'.format(k, val)) File "<string>", line 1, in <module> NameError: name 'VisuAcqGradEncoding' is not defined
Looking into the visu_pars of that dataset (attached here visu_pars.txt ) I realized the parameter 'VisuAcqGradEncoding' is missing and overall the file 'visu_pars' seems to be different from the one created with pv6.
Do you have any suggestion on how to overcome this problem and still use bids_convert?
Thank you :)
The text was updated successfully, but these errors were encountered:
@biancadepifanio Sorry for the late respond to this issue. I think it is same issue reported by other, but could you share the rawdata which the error (it would be helpful if you remove all other non-relevant scans) and corresponding json and csv files, so I can test and ensure the patch works for your case?
Hi, shlee, I met the same error of 'VisuAcqGradEncoding' is not defined when using brkraw on the Bruker 7.0T MRI data, is there any effective manner to solve the question? Thanks.
In addition, besides brkraw, do you know any other batch code to reorient the orignial rat mri data to match the SIGMA template? I need to change the Bruker data to BIDS data, but brkraw met the abovementioned error, so I have to change the data into nifti data first, and then reorient the nifti data to match SIGMA template, and finally change all nifti data into BIDS data. I find a 'orient.py' in the brkraw github, but I don't find how to use it.
Describe the bug
Hello :) I am trying to convert in BIDS an old dataset acquired with pv 5.1. I created the .csv file and the .json template with bids_helper, but when I tried to convert the dataset with bids_convert I received this error:
Traceback (most recent call last): File "/home/imaging/anaconda3/bin/brkraw", line 8, in <module> sys.exit(main()) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/scripts/brkraw.py", line 476, in main build_bids_json(dset, row, fname, json_fname, slope=slope, offset=offset) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 411, in build_bids_json dset.save_json(row.ScanID, row.RecoID, fname, dir=row.Dir, File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/loader.py", line 548, in save_json json_obj = self._parse_json(scan_id, reco_id, metadata) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/loader.py", line 506, in _parse_json val = meta_get_value(v, acqp, method, visu_pars) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 180, in meta_get_value val = meta_get_value(vi, acqp, method, visu_pars) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 170, in meta_get_value return meta_check_express(value, acqp, method, visu_pars) File "/home/imaging/anaconda3/lib/python3.9/site-packages/brkraw/lib/utils.py", line 252, in meta_check_express exec('{} = {}'.format(k, val)) File "<string>", line 1, in <module> NameError: name 'VisuAcqGradEncoding' is not defined
Looking into the visu_pars of that dataset (attached here visu_pars.txt ) I realized the parameter 'VisuAcqGradEncoding' is missing and overall the file 'visu_pars' seems to be different from the one created with pv6.
Do you have any suggestion on how to overcome this problem and still use bids_convert?
Thank you :)
The text was updated successfully, but these errors were encountered: