qsiprep icon indicating copy to clipboard operation
qsiprep copied to clipboard

Download AFQ templates into the docker container

Open arokem opened this issue 1 year ago • 2 comments

It would make sense to download the templates (e.g., waypoint ROIs, prob maps, etc.) when building the container, rather than in runtime. I think that would mean adding a section to this section that sets the AFQ_HOME variable (this is not implemented yet, but see also https://github.com/yeatmanlab/pyAFQ/issues/1036) and then running something like python -c "from AFQ.data.fetch import fetch_template(); fetch_template()"

The question I have is what should we set AFQ_HOME to be in this context?

arokem avatar Sep 28 '23 20:09 arokem

Maybe it can be in the derivatives folder? They are not real derivatives, but this is a location that has to be mounted in the container (unlike the user home folder). so you would have derivatives/qsiprep; derivatives/qsirecon; derivatives/afq_misc or something? I know that pyafq uses derivatives/afq so something to avoid confusion between the two

mayayab avatar Sep 28 '23 21:09 mayayab

If it's being built in the container, then it could be mounted anywhere since a user will never realistically need to access it or change the flags (for example, all of the atlases are mounted in /atlas/qsirecon_atlases/ relative to the root of the container). So setting up the Dockerfile to make a folder in the root of the container such as /pyafq_rois and exporting the AFQ_HOME env to match should work (as long as no one overrides it with export SINGULARITYENV_AFQ_HOME=/some/other/path).

smeisler avatar Oct 11 '23 20:10 smeisler