Open mattcieslak opened 5 months ago
Yes, you are correct, I wrote something for the CLI that handles this. It would make sense to add a call to pyAFQ to the docker image like this:
pyAFQ download
That causes the CLI to call this function which will download all the templates for babyAFQ and normal AFQ: https://github.com/yeatmanlab/pyAFQ/blob/899d504c7b75cca7a41f3c48daed9c614754d762/bin/pyAFQ#L117
@36000 pyAFQ download
is amazing. Did that get the baby atlases too?
Yup! It gets the baby atlases. I wrote it for my own docker images, this is its exact intended use.
@36000 I think something may have changed in pyAFQ such that the config from qsiprep doesn't work anymore. I added pyAFQ download
to the DockerFile and there is a /home/qsiprep/AFQ_data
that has the ROIs.
Here the error always ends with TypeError: bundle_info must be a dict, or a BundleDict. I tried changing the config file here but there is still a problematic bundle_info somewhere. Any ideas?
aha, it looks like in the CI tests when using the --sloppy
flag bundle_info
gets set to 'bundle_info': ['SLF_L', 'ARC_L', 'CST_L', 'CST_R'],
which is indeed not a dict. What is this arg supposed to look like if I only want to test for a couple bundles?
Ah! Them being a list is actually fine as the software should convert them to a dict. The problem is we got rid of the acronyms. There is a way to calculate an updated JSON. You run pyAFQ -q
. For this list, you would need to update it to:
['Left Superior Longitudinal', 'Left Arcuate', 'Left Corticospinal', 'Right Corticospinal']
I went ahead and generated some updated JSON's off the pyAFQ master. pyafq_input_trk.json pyafq.json
Oh - actually - i lied. You do need to instantiate a bundledict and pass it to pyAFQ if you want a subset. Please hold while I find the syntax.
The line should be:
"bundle_info": 'default18_bd()["Left Superior Longitudinal", "Left Arcuate", "Left Corticospinal", "Right Corticospinal"]'
That did it! Thank you @36000
One more question - do I need to install pyafq in a different way in order to be able to make the plots? I'm installing pyafq here
which plots? For the plotly html files we generate, this will work. There are other plots that require optional installations.
I hope to add a BabyAFQ recon workflow. @arokem and @36000 I have a question:
Does the current AFQ workflow download the bundle ROIs on the fly? If it does, would it make sense to add them to the qsiprep docker image? I will do the same with the BabyAFQ regions, whichever you prefer.