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

👽 Set up outputs in Brainlife to specific types #10

Open
shnizzedy opened this issue Mar 16, 2021 · 4 comments
Open

👽 Set up outputs in Brainlife to specific types #10

shnizzedy opened this issue Mar 16, 2021 · 4 comments
Labels
enhancement New feature or request Hacktoberfest https://hacktoberfest.digitalocean.com/

Comments

@shnizzedy
Copy link
Member

Related problem

Currently C-PAC on Brainlife outputs "raw" "c-pac" data:

current "raw" output

Proposed feature

Now that we have BIDS Derivatives outputs in C-PAC, we can specify multiple outputs in Brainlife to afford chaining Brainlife apps after C-PAC.

Alternatives

contact #datatype channel on brainlife.slack.com to register new datatype
https://brainlife.io/docs/apps/register/#raw-datatype

that incorporates all of C-PAC 1.8's outputs in one datatype?

@shnizzedy shnizzedy added the enhancement New feature or request label Mar 16, 2021
@sgiavasis
Copy link
Contributor

Seems like there are a lot of options here, looking at their examples.
I think it may be worth to at least separate into anat and func, much like how the directory structure is in BIDS.

However I see it may be a good idea to specify masks, etc. - maybe another option is setting it up so that the suffix of the outputs are set as the data type? So, _T1w, _bold, _mask, _timeseries, etc. (obviously without the _).

@sgiavasis
Copy link
Contributor

Looking more at this:

You can add specificities / context to the selected datatype. For example, the above screenshot shows this App outputs anat/t1w datatype with a tag acpc_aligned. If there is an App that only works with ACPC aligned anat/t1w as an input data, it can specify the same tag as a required input datatype tag to be more specific about its input data.

Sounds like it may also be feasible to make a data type for every unique resource label we have in C-PAC? Like desc-preproc_T1w, space-T1w_desc-brain_mask, etc.?

If I understand that right, it would be worth seeing if there are other Brainlife.io compatible apps that are already using BIDS-Derivatives and getting a sense of how they've named their outputs. Because it looks like the point of creating these tags is to facilitate interoperability.

@soichih
Copy link
Contributor

soichih commented Mar 18, 2021

I second the idea to register separate output data objects - much like the fmriprep app (https://brainlife.io/app/5c61c69f14027a01b14adcb3) You can go ahead and register anat/func as new outputs and update the main script so that it will organize (or symlink) the output files under various sub directory / expected file names. For example, if you register anat output to be stored anat sub directory, then you can setup this directory at the bottom of main script and symlink it from the output directory.

#expose output t1 as brainlife's neuro/anat dataype
mkdir -p anat
ln -s output/somewhere/t1.nii.gz anat/t1.nii.gz

And yes, you can set whatever the datatype tag to add specificity/context to the datatype. But I recommend making those an official datatype tags for neuro/anat by consulting in #datatype channel. In brainlife, we don't really call our output "derivatives" like BIDS does, because most App works on output from other Apps. You can start out by having no datatype tags, and when developers identify issues, data incompatibility, then we add datatype tags to prevent certain issues from happening.

@shnizzedy shnizzedy added the Hacktoberfest https://hacktoberfest.digitalocean.com/ label Sep 30, 2021
@shnizzedy
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Hacktoberfest https://hacktoberfest.digitalocean.com/
Projects
Status: No status
Development

No branches or pull requests

3 participants