Skip to content

Commit

Permalink
Upgraded BIDScoin from 3.7.0 to 4.2.0 + cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelzwiers authored and stebo85 committed Oct 17, 2023
1 parent e8677ce commit 01148fc
Show file tree
Hide file tree
Showing 5 changed files with 69 additions and 34 deletions.
49 changes: 32 additions & 17 deletions recipes/bidscoin/README.md
Original file line number Diff line number Diff line change
@@ -1,37 +1,52 @@

----------------------------------
## bidscoin/3.7.0 ##
## bidscoin/4.2.0 ##
Contains a collection of tools needed for DICOM to BIDS conversion, as well as MRS spectroscopy and physiological data to BIDS conversion

Example:
Tools included:
```
dcm2niix: v1.0.20230411 https://github.com/rordenlab/dcm2niix
bidscoin: https://bidscoin.readthedocs.io/en/4.2.0
bidscoin
bidscoiner
bidseditor
bidsmapper
bidsparticipants
deface
dicomsort
echocombine
medeface
physio2tsv
plotphysio
rawmapper
skullstrip
slicereport
```

Example reorganizing DICOM data:
```
dicomsort dicomfolder/sub-folder -r -e .IMA
```
dcm2niix
bidsmapper
bidscoiner
bidseditor
bidsparticipants
deface
medeface
dicomsort
rawmapper

convert dicom to bids:
dicomsort dicomfolder
Example converting dicom to BIDS:
```
Getting started:
bidscoin -h
Convert DICOM to BIDS:
bidsmapper dicomfolder bidsoutputfolder
bidscoiner dicomfolder bidsoutputfolder
```

More documentation can be found here:
https://bidscoin.readthedocs.io/en/latest/installation.html
https://github.com/rordenlab/dcm2niix
https://bidscoin.readthedocs.io/en/4.2.0


Citation:
```
Zwiers MP, Moia S, Oostenveld R. BIDScoin: A User-Friendly Application to Convert Source Data to Brain Imaging Data Structure. Front Neuroinform. 2022 Jan 13;15:770608. doi: 10.3389/fninf.2021.770608. PMID: 35095452; PMCID: PMC8792932.
```

To run container outside of this environment: ml bidscoin/3.7.0
To run container outside of this environment: ml bidscoin/4.2.0

----------------------------------
11 changes: 6 additions & 5 deletions recipes/bidscoin/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set -e

# this template file builds tools required for dicom conversion to bids
export toolName='bidscoin'
export toolVersion='3.7.0'
export toolVersion='4.2.0'
# Don't forget to update version change in README.md!!!!!

if [ "$1" != "" ]; then
Expand All @@ -13,9 +13,10 @@ fi

source ../main_setup.sh

# Changes I made to .def file:
# Changes made to .def file:
# 1. turned the apt-get install to neurodocker install
# 2. put commands with cd with && in between
# TODO: update these list items to better reflect the changes made
neurodocker generate ${neurodocker_buildMode} `# Based on Singularity .def file provided by bidscoin at https://github.com/Donders-Institute/bidscoin/blob/master/singularity.def` \
`# Install the latest dcm2niix from source` \
--pkg-manager apt \
Expand All @@ -31,12 +32,12 @@ neurodocker generate ${neurodocker_buildMode} `# Based on Singularity .def file
--install curl \
`# Install pigz (to speed up dcm2niix)` \
--install pigz \
`# Install the latest stable BIDScoin release from Python repository` \
`# Install the 4.2.0+Qt5 branch from Github` \
`# NOTE: PyQt5 is installed as Debian package to solve dependencies issues occurring when installed with pip.` \
--install python3-pyqt5 \
--miniconda version=latest \
pip_install='bidscoin[spec2nii2bids,phys2bidscoin]' \
--env DEPLOY_BINS=bidsmapper:bidscoiner:dicomsort:rawmapper:echocombine:deface:medeface:bidseditor:bidsparticipants \
pip_install='bidscoin[spec2nii2bids,deface]@git+https://github.com/Donders-Institute/[email protected]+qt5' \
--env DEPLOY_BINS=bidscoin:bidscoiner:bidseditor:bidsmapper:bidsparticipants:deface:dicomsort:echocombine:medeface:physio2tsv:plotphysio:rawmapper:skullstrip:slicereport:dcm2niix:pydeface \
--copy README.md /README.md \
> ${toolName}_${toolVersion}.Dockerfile

Expand Down
3 changes: 3 additions & 0 deletions recipes/bidscoin/test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export QT_DEBUG_PLUGINS=1
bidscoin -t
bidseditor myproject/bids
34 changes: 25 additions & 9 deletions recipes/bidstools/README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,26 @@

----------------------------------
## bidstools/toolVersion ##
## bidstools/1.0.2 ##
Contains a collection of tools useful for DICOM to BIDS conversion

Tools included:
```
dcm2niix: v1.0.20230411 https://github.com/rordenlab/dcm2niix
bidsmapper: https://bidscoin.readthedocs.io/en/latest/workflow.html#step-1a-running-the-bidsmapper
bidseditor: https://bidscoin.readthedocs.io/en/latest/workflow.html#step-1b-running-the-bidseditor
bidscoiner: https://bidscoin.readthedocs.io/en/latest/workflow.html#step-2-running-the-bidscoiner
rawmapper: https://bidscoin.readthedocs.io/en/latest/installation.html
deface: https://bidscoin.readthedocs.io/en/stable/bidsapps.html?highlight=deface#defacing
bidsparticipants: https://bidscoin.readthedocs.io/en/latest/installation.html
dicomsort: https://bidscoin.readthedocs.io/en/latest/installation.html
bidscoin: https://bidscoin.readthedocs.io
bidscoin
bidscoiner
bidseditor
bidsmapper
bidsparticipants
deface
dicomsort
echocombine
medeface
physio2tsv
plotphysio
rawmapper
skullstrip
slicereport
dcmtk: https://support.dcmtk.org/docs/pages.html
dcmdump
dump2dcm
Expand All @@ -27,9 +35,17 @@ heudiconv: https://heudiconv.readthedocs.io/en/latest/heuristics.html
Bru2Nii: https://github.com/neurolabusc/Bru2Nii
```

Example converting dicom to BIDS using bidscoin:
Example reorganizing DICOM data using BIDScoin:
```
dicomsort dicomfolder/sub-folder -r -e .IMA
```

Example converting dicom to BIDS using BIDScoin:
```
Getting started:
bidscoin -h
Convert DICOM to BIDS:
bidsmapper dicomfolder bidsoutputfolder
bidscoiner dicomfolder bidsoutputfolder
```
Expand Down
6 changes: 3 additions & 3 deletions recipes/bidstools/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set -e

# this template file builds tools required for dicom conversion to bids
export toolName='bidstools'
export toolVersion='1.0.1'
export toolVersion='1.0.2'
# Don't forget to update version change in README.md!!!!!

if [ "$1" != "" ]; then
Expand All @@ -23,14 +23,14 @@ neurodocker generate ${neurodocker_buildMode} \
--miniconda version=latest \
mamba=true \
conda_install='python=3.10 traits=6.3.2' \
pip_install='bidscoin heudiconv pydeface' \
pip_install='bidscoin[spec2nii2bids,deface] heudiconv' \
--install opts="--quiet" wget zip qt6-base-dev libgl1 libgtk2.0-0 dcmtk xmedcon pigz libxcb-cursor0 \
--workdir /opt/bru2 \
--run="wget https://github.com/neurolabusc/Bru2Nii/releases/download/v1.0.20180303/Bru2_Linux.zip" \
--run="unzip Bru2_Linux.zip" \
--dcm2niix method=source version=latest \
--env PATH='$PATH':/opt/bru2 \
--env DEPLOY_BINS=dcm2niix:bidsmapper:bidscoiner:bidseditor:bidsparticipants:bidstrainer:deface:dicomsort:pydeface:rawmapper:Bru2:Bru2Nii:heudiconv \
--env DEPLOY_BINS=bidscoin:bidscoiner:bidseditor:bidsmapper:bidsparticipants:deface:dicomsort:echocombine:medeface:physio2tsv:plotphysio:rawmapper:skullstrip:slicereport:dcm2niix:pydeface:Bru2:Bru2Nii:heudiconv \
--copy README.md /README.md \
> ${toolName}_${toolVersion}.Dockerfile

Expand Down

0 comments on commit 01148fc

Please sign in to comment.