-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[EEG] extract archive script #970
Conversation
4f547c1
to
dc5855c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@laemtl see my initial review.
A few general comments (in addition to the ones in line with the code changes):
- path should be assembly_bids not bids_assembly (if you want to copy the data with the MRI BIDS structure)
- I think the notifications will be show under the imaging uploader and not the EEG uploader (see comment in the write_to_notification_table function of Imaging IO)
- what happens if people do not have the Config
EEGS3DataPath
? Maybe you could add an if statement early in the script to check if the config exists, if not, exit with error?
I did not test it yet, wanted to do the review first. Let me know your thoughts.
94ec764
to
cab2357
Compare
The script checks if the config exists and is set otherwise {dataDirBasepath}/assembly_bids is used. |
@laemtl I encountered a few issues when testing. See below:
However, the file exists in my s3:
Could it be because the default bucket is pointing to the S3 bucket with the assembly_bids files? Do I need to add a config in my database_config.py file?
Is there a patch somewhere to add the enum? Also, in general, we try to avoid enum in LORIS so we are not depending on doing a major or minor release for a data change. Instead, it might be best to create a separate table with the list of status and use the ID of the statuses in
Once I modified the ENUM status column, I rerun the script and the extraction happens, however, it extracts it with the PSCID instead of the CandID which will be an issue for HBCD as all data are under CandID. Is there a config to use the CandID when extracting instead of the PSCID? If so, need to document that for deployment
The script still prints:
However, nothing get uploaded since s3://loris_demo_f/ does not exist. Also, seems like the message
|
FYI: list of tests performed:
|
@laemtl I just remembered about the permissions of the extract script. See point 5 in #970 (comment) |
Extracting using the CandID will be possible if the BIDS dataset is set to use the CandId as the BIDs subject_id. The dataset is probably not setup this way. To cover the conversion of subject-id for the previously uploaded dataset, another script can be created. |
Yes, here is the link to the PR for the patch: https://github.com/aces/HBCD/pull/895 |
cab2357
to
6fc4c4f
Compare
This PR requires the mysql patch in LORIS #8685
Test cases:
extract_eeg_bids_archive.py -p <profile> -u <upload_id>