Skip to content
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

Validation error during rois upload (validator-neuro-rois) #48

Open
rjpuzniak opened this issue Dec 7, 2020 · 1 comment
Open

Validation error during rois upload (validator-neuro-rois) #48

rjpuzniak opened this issue Dec 7, 2020 · 1 comment

Comments

@rjpuzniak
Copy link

Hello, recently I've tried to upload several rois to BL using CLI, however I'm constantly encountering the error during data validation step, which prevents me for doing so. Below I'll describe the way I'm processing and what happens:

  1. I create a folder tmp which contains a subfolder named rois (tmp/rois). Inside rois folder there are several files with binary masks, all in .nii.gz format
  2. I'm uploading the data with given command

bl dataset upload --directory Tmp/${subj_BL}/tmp \
	--project $project_id \
	--datatype neuro/rois \
	--datatype_tag 'aligned' \
	--subject $subj_BL \
	--desc 'Test' \
	--tag  'test' \
	--force
  1. On the terminal prompt I receive a following message
__dtv(brainlife/validator-neuro-rois)   Brain Life  
__dtv(brainlife/validator-neuro-rois)
 failed
loading error.log
(node:1954) UnhandledPromiseRejectionWarning: Error: Traceback (most recent call last):
  File "/mnt/datalad/upload/5fbf83ed47b8ca08393100cf/5fce6c3ad89d012ca55d0c19/validate.py", line 27, in <module>
    roispath=config["rois"]
KeyError: 'rois'

    at util.waitForFinish (/usr/lib/node_modules/brainlife/bl-dataset-upload.js:239:43)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
(node:1954) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:1954) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
  1. I can't figure out why config variable has no field rois, nor what I can do to change that. I've also tried uploading the rois together with associated label.json, but this didn't make a difference.
    Thank You very much,

Robert

@soichih
Copy link
Contributor

soichih commented Dec 7, 2020

--directory is for uploading bids data. Since you are uploading an individual data object, please use --rois instead.

Like..

$ bl data upload --datatype neuro/rois --project (project ID) --subject (subject name) --rois (file path for rois) 

Also, "dataset" command is deprecated by "data" command. So please use that instead.

Lastly, I just released a new version of brainlife CLI (1.5.5). Please update your CLI if you have not done so recently.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants