From 1320e1dfded6b3522c1a88baacbc24003d2a73ab Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Sat, 13 Jul 2024 11:40:07 +0200 Subject: [PATCH 1/6] run test create roi octave --- lib/CPP_ROI | 2 +- .../tests_cli/test_bidspm_create_roi.m | 20 ------------------- 2 files changed, 1 insertion(+), 21 deletions(-) diff --git a/lib/CPP_ROI b/lib/CPP_ROI index 4b4f7f2b..df855761 160000 --- a/lib/CPP_ROI +++ b/lib/CPP_ROI @@ -1 +1 @@ -Subproject commit 4b4f7f2b5614fc2b30d807a2e05b73baa2a34c0f +Subproject commit df85576134aeca9c566b0615eab7fc020ef7b846 diff --git a/tests/tests_slow/tests_cli/test_bidspm_create_roi.m b/tests/tests_slow/tests_cli/test_bidspm_create_roi.m index 039b4140..a9d58413 100644 --- a/tests/tests_slow/tests_cli/test_bidspm_create_roi.m +++ b/tests/tests_slow/tests_cli/test_bidspm_create_roi.m @@ -13,10 +13,6 @@ function test_bidsCreateROI_boilerplate_only() markTestAs('slow'); - if bids.internal.is_octave - moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.'); - end - outputPath = tempName(); bidspm(pwd, outputPath, ... @@ -40,10 +36,6 @@ function test_bidsCreateROI_glasser() markTestAs('slow'); - if bids.internal.is_octave - moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.'); - end - outputPath = tempName(); bidspm(pwd, outputPath, ... @@ -65,10 +57,6 @@ function test_bidsCreateROI_wang() markTestAs('slow'); - if bids.internal.is_octave - moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.'); - end - outputPath = tempName(); bidspm(pwd, outputPath, ... @@ -90,10 +78,6 @@ function test_bidsCreateROI_neuromorphometrics() markTestAs('slow'); - if bids.internal.is_octave - moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.'); - end - outputPath = tempName(); bidspm(pwd, outputPath, ... @@ -133,10 +117,6 @@ function test_bidsCreateROI_one_hemisphere() markTestAs('slow'); - if bids.internal.is_octave - moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.'); - end - outputPath = tempName(); bidspm(pwd, outputPath, 'subject', ... From 9c9888c13598c8b7f801c3ce8097a82048eaaaf7 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Sat, 13 Jul 2024 13:17:03 +0200 Subject: [PATCH 2/6] fix several tests in cpp roi --- lib/CPP_ROI | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/CPP_ROI b/lib/CPP_ROI index df855761..dd44b405 160000 --- a/lib/CPP_ROI +++ b/lib/CPP_ROI @@ -1 +1 @@ -Subproject commit df85576134aeca9c566b0615eab7fc020ef7b846 +Subproject commit dd44b405f1085a667593137cc54fc3c95989cc04 From 99b544da89b71537b24bc420b60ea1369dc907da Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Sat, 13 Jul 2024 13:21:06 +0200 Subject: [PATCH 3/6] reset submod --- lib/CPP_ROI | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/CPP_ROI b/lib/CPP_ROI index dd44b405..eec3c653 160000 --- a/lib/CPP_ROI +++ b/lib/CPP_ROI @@ -1 +1 @@ -Subproject commit dd44b405f1085a667593137cc54fc3c95989cc04 +Subproject commit eec3c6537bf601a2c770bb94b01de9266e7e60e6 From d5f5c20247763d7dbb6d11a652467e9d69870091 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Sat, 13 Jul 2024 14:44:44 +0200 Subject: [PATCH 4/6] update CPP_ROI --- lib/CPP_ROI | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/CPP_ROI b/lib/CPP_ROI index eec3c653..21ec30d3 160000 --- a/lib/CPP_ROI +++ b/lib/CPP_ROI @@ -1 +1 @@ -Subproject commit eec3c6537bf601a2c770bb94b01de9266e7e60e6 +Subproject commit 21ec30d3181eea25c6306e533de02eaa61722e7c From 6671a8fd918e3db751146cbaee71ac674784fc1c Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Sat, 13 Jul 2024 17:52:35 +0200 Subject: [PATCH 5/6] fix default path output create roi --- lib/CPP_ROI | 2 +- src/bidspm/bidspm.py | 2 +- tests/tests_slow/tests_cli/test_bidspm_create_roi.m | 6 ++++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/CPP_ROI b/lib/CPP_ROI index 21ec30d3..330239d3 160000 --- a/lib/CPP_ROI +++ b/lib/CPP_ROI @@ -1 +1 @@ -Subproject commit 21ec30d3181eea25c6306e533de02eaa61722e7c +Subproject commit 330239d34ecd425da5a5e10b82eb934b46d3165b diff --git a/src/bidspm/bidspm.py b/src/bidspm/bidspm.py index 62fd4e6f..d591db9c 100755 --- a/src/bidspm/bidspm.py +++ b/src/bidspm/bidspm.py @@ -186,7 +186,7 @@ def create_roi( ) -> str: roi_name = "{ '" + "', '".join(roi_name) + "' }" if roi_name is not None else None # type: ignore if roi_dir is None: - roi_dir = Path() + roi_dir = output_dir cmd = generate_cmd( bids_dir=bids_dir, diff --git a/tests/tests_slow/tests_cli/test_bidspm_create_roi.m b/tests/tests_slow/tests_cli/test_bidspm_create_roi.m index a9d58413..7bca3de1 100644 --- a/tests/tests_slow/tests_cli/test_bidspm_create_roi.m +++ b/tests/tests_slow/tests_cli/test_bidspm_create_roi.m @@ -46,6 +46,12 @@ function test_bidsCreateROI_glasser() 'space', {'IXI549Space'}, ... 'verbosity', 3); + assert(exist(fullfile(outputPath, ... + 'derivatives', ... + 'bidspm-roi', ... + 'reports', ... + 'create_roi_atlas-glasser_citation.md'), 'file') == 2); + rois = spm_select('FPList', fullfile(outputPath, ... 'derivatives', ... 'bidspm-roi', 'group'), '.*glasser.*_mask\.nii'); From da0e7aea8e39c544d2bfa2265b514945c08e2a76 Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Sat, 13 Jul 2024 18:16:48 +0200 Subject: [PATCH 6/6] fix typo --- lib/CPP_ROI | 2 +- src/workflows/roi/bidsCreateROI.m | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/CPP_ROI b/lib/CPP_ROI index 330239d3..b3cd2821 160000 --- a/lib/CPP_ROI +++ b/lib/CPP_ROI @@ -1 +1 @@ -Subproject commit 330239d34ecd425da5a5e10b82eb934b46d3165b +Subproject commit b3cd28214430e33dc4f3c1ad32a1ba325a711a9c diff --git a/src/workflows/roi/bidsCreateROI.m b/src/workflows/roi/bidsCreateROI.m index 6ba1bf99..f7cb9f0a 100644 --- a/src/workflows/roi/bidsCreateROI.m +++ b/src/workflows/roi/bidsCreateROI.m @@ -14,7 +14,7 @@ function bidsCreateROI(opt) % opt.roi.atlas = 'wang'; % opt.roi.hemi = {'L', 'R'}; % opt.roi.name = {'V1v', 'V1d'}; - % opt.roi.space = {'IXI549Space''}; + % opt.roi.space = {'IXI549Space'}; % % bidsCreateROI(opt); %