Skip to content

Commit e2d6a31

Browse files
authored
Merge pull request #2230 from FCP-INDI/organism
👔🔧 Add "organism" to pipeline config
2 parents a2c3d2f + 2afdf21 commit e2d6a31

File tree

62 files changed

+1432
-1045
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+1432
-1045
lines changed

.circleci/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ commands:
119119
coverage-file: .coverage.docker${VARIANT}
120120
- run:
121121
name: Running pytest in Docker image
122-
command: docker exec --user $(id -u) docker_test /bin/bash /code/dev/circleci_data/test_in_image.sh
122+
command: docker exec -e OSF_DATA --user $(id -u) docker_test /bin/bash /code/dev/circleci_data/test_in_image.sh
123123
set-python-version:
124124
steps:
125125
- restore_cache:

.github/Dockerfiles/base-lite.Dockerfile

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (C) 2023 C-PAC Developers
1+
# Copyright (C) 2023-2025 C-PAC Developers
22

33
# This file is part of C-PAC.
44

@@ -14,12 +14,12 @@
1414

1515
# You should have received a copy of the GNU Lesser General Public
1616
# License along with C-PAC. If not, see <https://www.gnu.org/licenses/>.
17-
FROM ghcr.io/fcp-indi/c-pac/afni:23.3.09-jammy as AFNI
18-
FROM ghcr.io/fcp-indi/c-pac/ants:2.4.3-jammy as ANTs
19-
FROM ghcr.io/fcp-indi/c-pac/c3d:1.0.0-jammy as c3d
20-
FROM ghcr.io/fcp-indi/c-pac/connectome-workbench:1.5.0.neurodebian-jammy as connectome-workbench
21-
FROM ghcr.io/fcp-indi/c-pac/fsl:6.0.6.5-jammy as FSL
22-
FROM ghcr.io/fcp-indi/c-pac/ica-aroma:0.4.4-beta-jammy as ICA-AROMA
17+
FROM ghcr.io/fcp-indi/c-pac/afni:23.3.09-jammy AS afni
18+
FROM ghcr.io/fcp-indi/c-pac/ants:2.4.3-jammy AS ants
19+
FROM ghcr.io/fcp-indi/c-pac/c3d:1.0.0-jammy AS c3d
20+
FROM ghcr.io/fcp-indi/c-pac/connectome-workbench:1.5.0.neurodebian-jammy AS connectome-workbench
21+
FROM ghcr.io/fcp-indi/c-pac/fsl:6.0.6.5-jammy AS fsl
22+
FROM ghcr.io/fcp-indi/c-pac/ica-aroma:0.4.4-beta-jammy AS ica-aroma
2323

2424
FROM ghcr.io/fcp-indi/c-pac/ubuntu:jammy-non-free
2525
LABEL org.opencontainers.image.description="NOT INTENDED FOR USE OTHER THAN AS A STAGE IMAGE IN A MULTI-STAGE BUILD \
@@ -47,11 +47,11 @@ ENV FSLTCLSH=$FSLDIR/bin/fsltclsh \
4747
PATH=${FSLDIR}/bin:$PATH \
4848
TZ=America/New_York \
4949
USER=c-pac_user
50-
COPY --from=FSL /lib/x86_64-linux-gnu /lib/x86_64-linux-gnu
51-
COPY --from=FSL /usr/lib/x86_64-linux-gnu /usr/lib/x86_64-linux-gnu
52-
COPY --from=FSL /usr/bin /usr/bin
53-
COPY --from=FSL /usr/local/bin /usr/local/bin
54-
COPY --from=FSL /usr/share/fsl /usr/share/fsl
50+
COPY --from=fsl /lib/x86_64-linux-gnu /lib/x86_64-linux-gnu
51+
COPY --from=fsl /usr/lib/x86_64-linux-gnu /usr/lib/x86_64-linux-gnu
52+
COPY --from=fsl /usr/bin /usr/bin
53+
COPY --from=fsl /usr/local/bin /usr/local/bin
54+
COPY --from=fsl /usr/share/fsl /usr/share/fsl
5555

5656
# Installing C-PAC dependencies
5757
COPY requirements.txt /opt/requirements.txt
@@ -67,10 +67,10 @@ ENV C3DPATH /opt/c3d
6767
ENV PATH $C3DPATH/bin:$PATH
6868

6969
# Installing AFNI
70-
COPY --from=AFNI /lib/x86_64-linux-gnu/ld* /lib/x86_64-linux-gnu/
71-
COPY --from=AFNI /lib/x86_64-linux-gnu/lib*so* /lib/x86_64-linux-gnu/
72-
COPY --from=AFNI /lib64/ld* /lib64/
73-
COPY --from=AFNI /opt/afni/ /opt/afni/
70+
COPY --from=afni /lib/x86_64-linux-gnu/ld* /lib/x86_64-linux-gnu/
71+
COPY --from=afni /lib/x86_64-linux-gnu/lib*so* /lib/x86_64-linux-gnu/
72+
COPY --from=afni /lib64/ld* /lib64/
73+
COPY --from=afni /opt/afni/ /opt/afni/
7474
# set up AFNI
7575
ENV PATH=/opt/afni:$PATH
7676

@@ -79,11 +79,11 @@ ENV LANG="en_US.UTF-8" \
7979
LC_ALL="en_US.UTF-8" \
8080
ANTSPATH=/usr/lib/ants/bin \
8181
PATH=/usr/lib/ants/bin:$PATH
82-
COPY --from=ANTs /usr/lib/ants/ /usr/lib/ants/
83-
COPY --from=ANTs /ants_template/ /ants_template/
82+
COPY --from=ants /usr/lib/ants/ /usr/lib/ants/
83+
COPY --from=ants /ants_template/ /ants_template/
8484

8585
# Installing ICA-AROMA
86-
COPY --from=ICA-AROMA /opt/ICA-AROMA/ /opt/ICA-AROMA/
86+
COPY --from=ica-aroma /opt/ICA-AROMA/ /opt/ICA-AROMA/
8787
ENV PATH=/opt/ICA-AROMA:$PATH
8888

8989
# link libraries & clean up

.github/Dockerfiles/base-standard.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ COPY dev/docker_data/license.txt $FREESURFER_HOME/license.txt
4646
RUN apt-get autoremove -y \
4747
&& apt-get autoclean -y \
4848
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /root/.cache/* \
49+
&& ln -s /usr/lib/x86_64-linux-gnu/libcrypt.so.1 /usr/lib/x86_64-linux-gnu/libcrypt.so.2 \
4950
&& find / -type f -print0 | sort -t/ -k2 | xargs -0 rdfind -makehardlinks true \
5051
&& rm -rf results.txt \
51-
&& cp -l /lib/x86_64-linux-gnu/libcrypt.so.1.1.0 /lib/x86_64-linux-gnu/libcrypt.so.2 \
5252
&& ldconfig \
5353
&& chmod 777 / /home/c-pac_user \
5454
&& chmod 777 $(ls / | grep -v sys | grep -v proc)

.github/dependabot.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
# Copyright (C) 2024 - 2025 C-PAC Developers
2+
3+
# This file is part of C-PAC.
4+
5+
# C-PAC is free software: you can redistribute it and/or modify it under
6+
# the terms of the GNU Lesser General Public License as published by the
7+
# Free Software Foundation, either version 3 of the License, or (at your
8+
# option) any later version.
9+
10+
# C-PAC is distributed in the hope that it will be useful, but WITHOUT
11+
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12+
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
13+
# License for more details.
14+
15+
# You should have received a copy of the GNU Lesser General Public
16+
# License along with C-PAC. If not, see <https://www.gnu.org/licenses/>.
117
version: 2
218
registries:
319
ghcr:

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3131
- `censor_file_path` from `offending_timepoints_connector` in the `build_nuisance_regressor` node.
3232
- Switch `sink_native_transforms` under `registration_workflows` to output all `.mat` files in ANTs and FSL Transforms.
3333
- `deoblique` field in pipeline config with `warp` and `refit` options to apply `3dWarp` or `3drefit` during data initialization.
34+
- `organism` configuration option.
3435

3536
### Changed
3637

@@ -69,6 +70,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
6970
- A bug in the `freesurfer_abcd_preproc` nodeblock where the `Template` image was incorrectly used as `reference` during the `inverse_warp` step. Replacing it with the subject-specific `T1w` image resolved the issue of the `desc-restoreBrain_T1w` being chipped off.
7071
- A bug in `ideal_bandpass` where the frequency mask was incorrectly applied, which caused filter to fail in certain cases.
7172

73+
### Upgraded dependencies
74+
75+
- `voluptuous` 0.13.1 → 0.15.2
76+
7277
### Removed
7378

7479
- Variant image recipes.
@@ -83,6 +88,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
8388
- Inputs `[desc-motion_bold, bold]` from `coregistration_prep_vol` nodeblock.
8489
- `input` field from `coregistration` in blank and default config.
8590
- `reg_with_skull` swtich from `func_input_prep` in blank and default config.
91+
- Support for AFNI 3dECM < v21.1.1.
92+
- `calculate_motion_before` and `calculate_motion_after` configuration options.
8693

8794
#### Removed CI dependency
8895

CPAC/_entrypoints/run.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env python
2-
# Copyright (C) 2018-2024 C-PAC Developers
2+
# Copyright (C) 2018-2025 C-PAC Developers
33

44
# This file is part of C-PAC.
55

@@ -729,16 +729,6 @@ def run_main():
729729
args.fail_fast
730730
)
731731

732-
if c["pipeline_setup"]["output_directory"]["quality_control"][
733-
"generate_xcpqc_files"
734-
]:
735-
c["functional_preproc"]["motion_estimates_and_correction"][
736-
"motion_estimates"
737-
]["calculate_motion_first"] = True
738-
c["functional_preproc"]["motion_estimates_and_correction"][
739-
"motion_estimates"
740-
]["calculate_motion_after"] = True
741-
742732
if args.participant_label:
743733
WFLOGGER.info(
744734
"#### Running C-PAC for %s", ", ".join(args.participant_label)

CPAC/alff/alff.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# -*- coding: utf-8 -*-
2-
# Copyright (C) 2012-2024 C-PAC Developers
2+
# Copyright (C) 2012-2025 C-PAC Developers
33

44
# This file is part of C-PAC.
55

@@ -25,7 +25,6 @@
2525
from CPAC.pipeline.nodeblock import nodeblock
2626
from CPAC.registration.registration import apply_transform
2727
from CPAC.utils.interfaces import Function
28-
from CPAC.utils.utils import check_prov_for_regtool
2928

3029

3130
def create_alff(wf_name="alff_workflow"):
@@ -320,10 +319,7 @@ def alff_falff(wf, cfg, strat_pool, pipe_num, opt=None):
320319
def alff_falff_space_template(wf, cfg, strat_pool, pipe_num, opt=None):
321320
outputs = {}
322321
if strat_pool.check_rpool("desc-denoisedNofilt_bold"):
323-
xfm_prov = strat_pool.get_cpac_provenance(
324-
"from-bold_to-template_mode-image_xfm"
325-
)
326-
reg_tool = check_prov_for_regtool(xfm_prov)
322+
reg_tool = strat_pool.reg_tool("from-bold_to-template_mode-image_xfm")
327323

328324
num_cpus = cfg.pipeline_setup["system_config"]["max_cores_per_participant"]
329325

CPAC/func_preproc/__init__.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (C) 2012-2023 C-PAC Developers
1+
# Copyright (C) 2012-2025 C-PAC Developers
22

33
# This file is part of C-PAC.
44

@@ -19,20 +19,20 @@
1919
from .func_motion import (
2020
calc_motion_stats,
2121
func_motion_correct,
22-
func_motion_correct_only,
2322
func_motion_estimates,
24-
get_motion_ref,
23+
get_motion_refs,
2524
motion_estimate_filter,
25+
stack_motion_blocks,
2626
)
2727
from .func_preproc import get_idx, slice_timing_wf
2828

2929
__all__ = [
3030
"calc_motion_stats",
3131
"func_motion_correct",
32-
"func_motion_correct_only",
3332
"func_motion_estimates",
3433
"get_idx",
35-
"get_motion_ref",
34+
"get_motion_refs",
3635
"motion_estimate_filter",
3736
"slice_timing_wf",
37+
"stack_motion_blocks",
3838
]

0 commit comments

Comments
 (0)