-
Notifications
You must be signed in to change notification settings - Fork 576
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] Load compcor related confounds generated from fmriprep 21.x ser…
…ies (#3285) * [TEST] add test data for fmriprep 21.x series - refactor the test file loader - add test data and make sure the corret files are loaded - apply compcor loading suggestions from @askieslinger Still need to investigate if the actual behaviour is inline with the literature * ENH refactor compcor for 21.x.x the code should now work for both before and after 21.x update. * simply _check_compcor_method by using all five options as prefix checking keys * add tests to test_load_confounds_strategy.py::test_strategy_compcor and test_load_confounds.py::test_n_compcor to make sure the correct componenets are loaded * FIX pep8 * RF factorise `test_strategy_compcor` * shorten the `test_strategy_compcor` by factorising the check on different fmriprep versions * add an entry in `latest.rst` * PEP8 * FIX typo Co-authored-by: Gensollen <nicolas.gensollen@gmail.com> * FIX typo in function name... * fix tests * lint * test on both data inputs for most tests * refactor tests --------- Co-authored-by: Gensollen <nicolas.gensollen@gmail.com> Co-authored-by: Remi Gau <remi_gau@hotmail.com>
- Loading branch information
1 parent
be0ad56
commit 2d6ff1c
Showing
10 changed files
with
379 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
134 changes: 134 additions & 0 deletions
134
nilearn/interfaces/fmriprep/data/test-v21_desc-confounds_timeseries.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,134 @@ | ||
{ | ||
"a_comp_cor_00": { | ||
"CumulativeVarianceExplained": 0.2026280323, | ||
"Mask": "combined", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 123.2000731257, | ||
"VarianceExplained": 0.2026280323 | ||
}, | ||
"a_comp_cor_01": { | ||
"CumulativeVarianceExplained": 0.3329213889, | ||
"Mask": "combined", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 98.7921275175, | ||
"VarianceExplained": 0.1302933566 | ||
}, | ||
"a_comp_cor_02": { | ||
"CumulativeVarianceExplained": 0.4240879383, | ||
"Mask": "combined", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 82.6378407134, | ||
"VarianceExplained": 0.0911665494 | ||
}, | ||
"a_comp_cor_03": { | ||
"CumulativeVarianceExplained": 0.4888242986, | ||
"Mask": "combined", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 69.6362444247, | ||
"VarianceExplained": 0.0647363603 | ||
}, | ||
"a_comp_cor_04": { | ||
"CumulativeVarianceExplained": 0.5366018375, | ||
"Mask": "combined", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 59.8236751211, | ||
"VarianceExplained": 0.0477775389 | ||
}, | ||
"c_comp_cor_00": { | ||
"CumulativeVarianceExplained": 0.2376671896, | ||
"Mask": "CSF", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 100.4509741103, | ||
"VarianceExplained": 0.2376671896 | ||
}, | ||
"c_comp_cor_01": { | ||
"CumulativeVarianceExplained": 0.416993444, | ||
"Mask": "CSF", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 87.2552317073, | ||
"VarianceExplained": 0.1793262545 | ||
}, | ||
"c_comp_cor_02": { | ||
"CumulativeVarianceExplained": 0.5132008054, | ||
"Mask": "CSF", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 63.9107168937, | ||
"VarianceExplained": 0.0962073614 | ||
}, | ||
"csf": { | ||
"Method": "Mean" | ||
}, | ||
"csf_wm": { | ||
"Method": "Mean" | ||
}, | ||
"global_signal": { | ||
"Method": "Mean" | ||
}, | ||
"t_comp_cor_00": { | ||
"CumulativeVarianceExplained": 0.3071809951, | ||
"Method": "tCompCor", | ||
"Retained": true, | ||
"SingularValue": 209.0973108093, | ||
"VarianceExplained": 0.3071809951 | ||
}, | ||
"t_comp_cor_01": { | ||
"CumulativeVarianceExplained": 0.422434229, | ||
"Method": "tCompCor", | ||
"Retained": true, | ||
"SingularValue": 128.0789729064, | ||
"VarianceExplained": 0.115253234 | ||
}, | ||
"t_comp_cor_02": { | ||
"CumulativeVarianceExplained": 0.5047450057, | ||
"Method": "tCompCor", | ||
"Retained": true, | ||
"SingularValue": 108.2379668127, | ||
"VarianceExplained": 0.0823107766 | ||
}, | ||
"tcompcor": { | ||
"Method": "Mean" | ||
}, | ||
"w_comp_cor_00": { | ||
"CumulativeVarianceExplained": 0.2600923672, | ||
"Mask": "WM", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 94.8997276396, | ||
"VarianceExplained": 0.2600923672 | ||
}, | ||
"w_comp_cor_01": { | ||
"CumulativeVarianceExplained": 0.37516225, | ||
"Mask": "WM", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 63.1221812188, | ||
"VarianceExplained": 0.1150698828 | ||
}, | ||
"w_comp_cor_02": { | ||
"CumulativeVarianceExplained": 0.4623071378, | ||
"Mask": "WM", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 54.9315836787, | ||
"VarianceExplained": 0.0871448878 | ||
}, | ||
"w_comp_cor_03": { | ||
"CumulativeVarianceExplained": 0.5166338394, | ||
"Mask": "WM", | ||
"Method": "aCompCor", | ||
"Retained": true, | ||
"SingularValue": 43.3718384282, | ||
"VarianceExplained": 0.0543267016 | ||
}, | ||
"white_matter": { | ||
"Method": "Mean" | ||
} | ||
} |
31 changes: 31 additions & 0 deletions
31
nilearn/interfaces/fmriprep/data/test-v21_desc-confounds_timeseries.tsv
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.