The zeitgeist for AFNI's data layout and the zeitgeist for BIDS' data layout aren't well-matched. AFNI wants everything for the subject in one directory and BIDS wants each type of data in a separate directory. For example, for one subject, I currently have at least 6 relevant directories with the data:
sub-127608/ses-Session1/anat
sub-127608/ses-Session1/fmap
sub-127608/ses-Session1/func
derivatives/fmriprep/sub-127608/ses-Session1/anat
derivatives/fmriprep/sub-127608/ses-Session1/func
derivatives/bold/sub-127608/ses-Session1
My solution at the moment is to define a bash function (or use a shell-script) that uses find to help:
bsafni() {
afni -DAFNI_SESSTRAIL=4 `find . -type d \( -wholename "*${1}*func" -o -wholename "*${1}*anat" -o -wholename "*${1}*fmap" -o -wholename "*derivatives/bold/*${1}*" \) | tr '\n' ' '`
}
so I can
bsafni 127608 and then switch the session to "all datasets" (huge plus that feature!).
Are there other solutions people have out there to working with these two together?
Craig