Converting Philips PAR/REC files with heudiconv

Can you help with this heudiconv conversion? I’m having trouble getting heudiconv to find a set of PAR/REC files. When I run

docker run --rm -it -v $PWD:/data nipy/heudiconv -d /data/sourcedata/sub-{subject}/*/*PAR -s 01 -f /data/code/heuristics/convertall.py -c none -b -o /data

The dicominfo.tsv file inside of .heudiconv is empty. Is there a typo I can’t see in that command? Note that the files are definitely there:

tree

.
├── code
│ └── heuristics
│ ├── convertall.py
│ ├── convertall.pyc
│ ├── convert.txt
└── sourcedata
└── sub-01
├── AE_behav
│ ├── 01AE_r1.txt
│ ├── AE_1_FHO_local.txt
│ ├── AE_1_FHO.mat
│ ├── AE_2_FHO_local.txt
│ ├── AE_2_FHO.mat
│ ├── AE_FeatFamExpt_fMRIlocalizer_Block1.mat
│ ├── AE_FeatFamExpt_fMRIlocalizer_Block2.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block1.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block2.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block3.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block4.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block5.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block6.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block7.mat
│ ├── AE_FeatFamExpt_fMRI_Subject1_Block8.mat
│ └── AE_FeatFamExpt_Training_Subject1_Block1.mat
├── Anat
│ ├── 09mar15ks_03_1-T1TFE.PAR
│ └── 09mar15ks_03_1-T1TFE.REC
├── FHO_loc1
│ ├── 09mar15ks_08_1-FEEPI.PAR
│ └── 09mar15ks_08_1-FEEPI.REC
├── FHO_loc2
│ ├── 09mar15ks_14_1-FEEPI.PAR
│ └── 09mar15ks_14_1-FEEPI.REC
├── loc1
│ ├── 09mar15ks_09_1-FEEPI.PAR
│ └── 09mar15ks_09_1-FEEPI.REC
├── loc2
│ ├── 09mar15ks_16_1-FEEPI.PAR
│ └── 09mar15ks_16_1-FEEPI.REC
├── r1
│ ├── 09mar15ks_04_1-FEEPI.PAR
│ └── 09mar15ks_04_1-FEEPI.REC
├── r2
│ ├── 09mar15ks_05_1-FEEPI.PAR
│ └── 09mar15ks_05_1-FEEPI.REC
├── r3
│ ├── 09mar15ks_06_1-FEEPI.PAR
│ └── 09mar15ks_06_1-FEEPI.REC
├── r4
│ ├── 09mar15ks_07_1-FEEPI.PAR
│ └── 09mar15ks_07_1-FEEPI.REC
├── r5
│ ├── 09mar15ks_10_1-FEEPI.PAR
│ └── 09mar15ks_10_1-FEEPI.REC
├── r6
│ ├── 09mar15ks_11_1-FEEPI.PAR
│ └── 09mar15ks_11_1-FEEPI.REC
├── r7
│ ├── 09mar15ks_12_1-FEEPI.PAR
│ └── 09mar15ks_12_1-FEEPI.REC
├── r8
│ ├── 09mar15ks_13_1-FEEPI.PAR
│ └── 09mar15ks_13_1-FEEPI.REC
└── ret1
├── 09mar15ks_15_1-FEEPI.PAR
├── 09mar15ks_15_1-FEEPI.REC
├── r1_test.json
└── r1_test.nii.gz
19 directories, 51 files

@psadil at the moment, heudiconv does not support PAR/REC files - however if you are interested in working towards adding this feature to a future version I would be more than happy to help!

@mgxd yeah, I’d be down to work towards adding this. Where would you recommend starting?

I’ve made an issue on the heudiconv repo to discuss this in more depth