forked from corticometrics/fs-docker
-
Notifications
You must be signed in to change notification settings - Fork 2
/
makefile
151 lines (132 loc) · 4.41 KB
/
makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
FS_LICENSE_BASE64 ?= ""
FS_REPO ?= "https://github.com/freesurfer/freesurfer"
FS_BRANCH ?= "dev"
ND ?= "neurodocker"
#all: fs-build
#all: fs-build fs-run
fs-build:
cd ./build && docker build -t pwighton/fs-dev-build .
fs-build-nc:
cd ./build && docker build --no-cache -t pwighton/fs-dev-build .
fs-run:
cd ./run && docker build -t pwighton/fs-dev-run .
fs-run-nc:
cd ./run && docker build --no-cache -t pwighton/fs-dev-run .
fs-720:
${ND} generate docker \
--base-image ubuntu:xenial \
--pkg-manager apt \
--freesurfer version=7.2.0 \
--matlabmcr version=2014b install_path=/opt/MCRv84 \
--run "ln -s /opt/MCRv84/v84 /opt/freesurfer-7.2.0/MCRv84" \
| docker build -t pwighton/freesurfer:7.2.0 -
# via neurodocker (WIP) https://github.com/pwighton/neurodocker/tree/20210226-fs-source
fs-infant-dev:
${ND} generate docker \
--base-image ubuntu:xenial \
--pkg-manager apt \
--yes \
--niftyreg \
version=master \
--fsl \
version=5.0.10 \
method=binaries \
--freesurfer \
method=source \
repo=https://github.com/pwighton/freesurfer.git \
branch=20220224-gems-cmake-rework \
license_base64=${FS_LICENSE_BASE64} \
infant_module=ON \
dev_tools=ON \
--entrypoint '/bin/infant-container-entrypoint-aws.bash' \
| docker build --no-cache --network host -t pwighton/fs-infant-dev -
# Same as above, but the h5 skullstripped files are copied into the container
fs-infant-dev-model-inside:
${ND} generate docker \
--base-image ubuntu:xenial \
--pkg-manager apt \
--yes \
--niftyreg \
version=master \
--fsl \
version=5.0.10 \
method=binaries \
--freesurfer \
method=source \
repo=https://github.com/pwighton/freesurfer.git \
branch=20220224-gems-cmake-rework \
license_base64=${FS_LICENSE_BASE64} \
infant_module=ON \
dev_tools=ON \
infant_model_s3=s3://freesurfer-annex/infant/model/dev/ \
infant_model_s3_region=us-east-2 \
--entrypoint '/bin/infant-container-entrypoint-aws.bash' \
| docker build --no-cache --network host -t pwighton/fs-infant-dev -
# alt:
# --entrypoint '/bin/infant-container-entrypoint-aws.bash' \
fs-baby: fs-baby-base
cd ./baby && docker build -t pwighton/fs-baby .
fs-baby-nc: fs-baby-base-nc
cd ./baby && docker build --no-cache -t pwighton/fs-baby .
# Notes:
# 1) FreeSurfer python reqs
# - https://github.com/freesurfer/freesurfer/blob/dev/python/requirements.txt
# 2) Python version should match version in `build/Dockerfile` for python bindings to work
fs-baby-base-dockerfile:
docker run repronim/neurodocker \
generate docker \
--base ubuntu:xenial \
--pkg-manager apt \
--neurodebian \
os_codename=xenial \
version=usa-nh \
--fsl \
version=5.0.10 \
method=binaries \
--miniconda \
create_env=freesurfer \
conda_install="python=3.6.6" \
activate=true \
> baby/dockerfile.fs-baby-base
fs-baby-base: fs-baby-base-dockerfile
cd ./baby && docker build -t pwighton/fs-baby-base -f dockerfile.fs-baby-base .
fs-baby-base-nc: fs-baby-base-dockerfile
cd ./baby && docker build --no-cache -t pwighton/fs-baby-base -f dockerfile.fs-baby-base .
petsurfer:
${ND} generate docker \
--yes \
--base-image python:3.8-buster \
--pkg-manager apt \
--fsl \
version=5.0.10 \
method=binaries \
--freesurfer \
version=7.2.0 \
| docker build -t pwighton/petsurfer:7.2.0 -
petsurfer-bids: petsurfer-bids/dockerfile
cd ./petsurfer-bids && docker build -f dockerfile --no-cache -t pwighton/petsurfer-bids:7.2.0 .
petsurfer-bids-dev:
cd ./petsurfer-bids && docker build -f dockerfile-dev --no-cache -t pwighton/petsurfer-bids-vb:7.2.0 .
fs-pet-dev-nipype-base:
${ND} generate docker \
--yes \
--base-image ubuntu:xenial \
--pkg-manager apt \
--neurodebian \
os_codename=xenial \
version=usa-nh \
--freesurfer \
method=source \
repo=https://github.com/freesurfer/freesurfer.git \
branch=dev \
license_base64=${FS_LICENSE_BASE64} \
dev_tools=ON \
minimal=OFF \
samseg_atlas_build=OFF \
infant_module=OFF \
--fsl \
version=5.0.10 \
method=binaries \
| docker build --no-cache -t pwighton/petsurfer-bids-base:dev -
fs-pet-dev-nipype:
cd ./petsurfer-bids && docker build -f dockerfile-dev --no-cache -t pwighton/petsurfer-bids:dev .