From 167ec19cb6283036f616faadf7c936eb231cb070 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 31 Jul 2023 20:01:22 -0400 Subject: [PATCH 1/7] add workflow to test latest --- .github/workflows/test_latest.yml | 68 +++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 .github/workflows/test_latest.yml diff --git a/.github/workflows/test_latest.yml b/.github/workflows/test_latest.yml new file mode 100644 index 0000000..68ec7fe --- /dev/null +++ b/.github/workflows/test_latest.yml @@ -0,0 +1,68 @@ +--- +name: test latest image + +on: + push: + branches: ['*'] + schedule: + - cron: 0 0 1 * * + workflow_dispatch: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + + test_dataset_without_session: + + runs-on: ubuntu-latest + + steps: + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y tree + + - name: pull docker image + run: docker pull bids/hcppipeline + + - name: print version + run: | + docker run -t --rm --read-only \ + --tmpfs /tmp \ + --tmpfs /var/tmp \ + bids/hcppipelines --help + docker run -t --rm --read-only \ + --tmpfs /tmp \ + --tmpfs /var/tmp \ + bids/hcppipelines --version + + - name: get data + run: | + wget https://raw.githubusercontent.com/bids-apps/maintenance-tools/main/utils/get_data_from_osf.sh + bash get_data_from_osf.sh hcp_example_bids_v3 + + - name: prepare output dir + run: | + mkdir -p ${HOME}/outputs + + - name: participant 01 + run: | + docker run -t --rm --read-only \ + -v ${HOME}/data/hcp_example_bids_v3:/bids_dataset \ + -v ${HOME}/outputs:/outputs \ + --tmpfs /tmp \ + --tmpfs /var/tmp \ + bids/hcppipelines \ + /bids_dataset \ + /outputs \ + participant \ + --participant_label 100307 \ + --stages PreFreeSurfer \ + --license_key="*CxjskRdd7" \ + --n_cpus 2 + + - name: check output + run: tree ${HOME}/outputs + From 4de3500fa383653838a77e0aba04991c6091a9fd Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 31 Jul 2023 20:04:41 -0400 Subject: [PATCH 2/7] lint --- .github/workflows/test_latest.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/test_latest.yml b/.github/workflows/test_latest.yml index 68ec7fe..ca85e73 100644 --- a/.github/workflows/test_latest.yml +++ b/.github/workflows/test_latest.yml @@ -65,4 +65,3 @@ jobs: - name: check output run: tree ${HOME}/outputs - From da36742cc284bb3ec2e538f5eff446fb754f1774 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 31 Jul 2023 20:06:05 -0400 Subject: [PATCH 3/7] fix typo --- .github/workflows/test_latest.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_latest.yml b/.github/workflows/test_latest.yml index ca85e73..bf996e7 100644 --- a/.github/workflows/test_latest.yml +++ b/.github/workflows/test_latest.yml @@ -25,7 +25,7 @@ jobs: sudo apt-get install -y tree - name: pull docker image - run: docker pull bids/hcppipeline + run: docker pull bids/hcppipelines - name: print version run: | From 4b3f8b14f38b90b40882be5dffaae6534626b84a Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 31 Jul 2023 20:06:54 -0400 Subject: [PATCH 4/7] update README --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 39fb15f..a9ebfee 100644 --- a/README.md +++ b/README.md @@ -101,10 +101,10 @@ This App has the following command line arguments: To run it in participant level mode (for one participant): docker run -i --rm \ - -v /Users/filo/data/ds005:/bids_dataset:ro \ - -v /Users/filo/outputs:/outputs \ - bids/hcppipelines \ - /bids_dataset /outputs participant --participant_label 01 --license_key "XXXXXX" + -v /Users/filo/data/ds005:/bids_dataset:ro \ + -v /Users/filo/outputs:/outputs \ + bids/hcppipelines \ + /bids_dataset /outputs participant --participant_label 01 --license_key "XXXXXX" ### Commercial use From 8c9f3a3ea8c1da15f867f8a82014aaa7e2003c75 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 31 Jul 2023 20:21:23 -0400 Subject: [PATCH 5/7] try running in circle ci --- .circleci/config.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7d52483..7b593fa 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -74,10 +74,36 @@ jobs: wget https://raw.githubusercontent.com/bids-apps/maintenance-tools/main/circleci/push_docker.sh bash push_docker.sh + test_latest: + machine: + image: ubuntu-2204:2022.10.2 + steps: + - run: + name: Get test data + command: | + wget https://raw.githubusercontent.com/bids-apps/maintenance-tools/main/utils/get_data_from_osf.sh + bash get_data_from_osf.sh hcp_example_bids_v3 + - run: + name: Get test data + command: docker pull bids/${CIRCLE_PROJECT_REPONAME,,} + - run: + name: participant level tests for single session dataset + command: | + docker run -ti --rm --read-only \ + -v ~/data/hcp_example_bids_v3:/bids_dataset \ + bids/${CIRCLE_PROJECT_REPONAME,,} \ + /bids_dataset \ + /outputs \ + participant --participant_label 100307 \ + --stages PreFreeSurfer \ + --license_key="*CxjskRdd7" \ + --n_cpus 2 + workflows: build-test-deploy: jobs: - build + - test_latest - test: requires: - build From cff6e230c2c4c68499ccdc5e6be99c2423d63787 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Mon, 31 Jul 2023 20:22:20 -0400 Subject: [PATCH 6/7] fix name step --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7b593fa..7ef38a2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -84,7 +84,7 @@ jobs: wget https://raw.githubusercontent.com/bids-apps/maintenance-tools/main/utils/get_data_from_osf.sh bash get_data_from_osf.sh hcp_example_bids_v3 - run: - name: Get test data + name: Pull image command: docker pull bids/${CIRCLE_PROJECT_REPONAME,,} - run: name: participant level tests for single session dataset From 6d685b9a6b6a765cbc27dd7dd1ca6ce99b828514 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Wed, 30 Aug 2023 22:54:43 -0400 Subject: [PATCH 7/7] try without dwell time --- .circleci/config.yml | 1 + .travis.yml | 25 ------------------------- 2 files changed, 1 insertion(+), 25 deletions(-) delete mode 100644 .travis.yml diff --git a/.circleci/config.yml b/.circleci/config.yml index 7ef38a2..fd83499 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -96,6 +96,7 @@ jobs: /outputs \ participant --participant_label 100307 \ --stages PreFreeSurfer \ + --processing_mode legacy \ --license_key="*CxjskRdd7" \ --n_cpus 2 diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 8e547e4..0000000 --- a/.travis.yml +++ /dev/null @@ -1,25 +0,0 @@ ---- -sudo: required - -cache: - directories: - - ${HOME}/data - -services: -- docker - -before_install: -- export REPO_NAME=$( echo $TRAVIS_REPO_SLUG | cut -d'/' -f2 ) -- if [[ ! -d ~/data/hcp_example_bids ]]; then travis_retry wget --retry-connrefused --waitretry=1 --read-timeout=20 --timeout=15 -t 10 -c -P ${HOME}/downloads/ - "https://googledrive.com/host/0B2JWN60ZLkgkMGlUY3B4MXZIZW8/hcp_example_bids.tar" && mkdir -p ${HOME}/data && tar xf ${HOME}/downloads/hcp_example_bids.tar - -C ${HOME}/data; fi -- git describe --tags > version -- docker build -t bids/${REPO_NAME,,} . -- mkdir -p ${HOME}/outputs - -script: - # print version -- docker run -ti --rm --read-only -v /tmp:/tmp -v /var/tmp:/var/tmp -v ${HOME}/data/hcp_example_bids:/bids_dataset bids/${REPO_NAME,,} --version - # participant level tests for single session dataset -- travis_wait docker run -ti --rm --read-only -v /tmp:/tmp -v /var/tmp:/var/tmp -v ${HOME}/data/hcp_example_bids:/bids_dataset -v ${HOME}/outputs1:/outputs - bids/${REPO_NAME,,} /bids_dataset /outputs participant --participant_label 100307 --stages PreFreeSurfer --license_key="*CxjskRdd7"