Skip to content

Commit 624cdd1

Browse files
committed
implement tests and fix config and scheme
1 parent fd03b57 commit 624cdd1

File tree

6 files changed

+90
-19
lines changed

6 files changed

+90
-19
lines changed

conf/base.config

+5-5
Original file line numberDiff line numberDiff line change
@@ -28,29 +28,29 @@ process {
2828
// See https://www.nextflow.io/docs/latest/config.html#config-process-selectors
2929
withLabel:process_single {
3030
cpus = { 1 }
31-
memory = { 6.GB * task.attempt }
31+
memory = { 4.GB * task.attempt }
3232
time = { 4.h * task.attempt }
3333
}
3434
withLabel:process_low {
3535
cpus = { 2 * task.attempt }
36-
memory = { 12.GB * task.attempt }
36+
memory = { 4.GB * task.attempt }
3737
time = { 4.h * task.attempt }
3838
}
3939
withLabel:process_medium {
4040
cpus = { 6 * task.attempt }
41-
memory = { 36.GB * task.attempt }
41+
memory = { 8.GB * task.attempt }
4242
time = { 8.h * task.attempt }
4343
}
4444
withLabel:process_high {
4545
cpus = { 12 * task.attempt }
46-
memory = { 72.GB * task.attempt }
46+
memory = { 12.GB * task.attempt }
4747
time = { 16.h * task.attempt }
4848
}
4949
withLabel:process_long {
5050
time = { 20.h * task.attempt }
5151
}
5252
withLabel:process_high_memory {
53-
memory = { 200.GB * task.attempt }
53+
memory = { 16.GB * task.attempt }
5454
}
5555
withLabel:error_ignore {
5656
errorStrategy = 'ignore'

conf/modules.config

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ params.frf_average_from_data = params.mean_frf
2828
process {
2929

3030
publishDir = [
31-
path: { "${params.outdir}/${task.process.tokenize(":")[-1].tokenize("_")[0].toLowerCase()}" },
31+
path: { "${params.outdir}/${task.process.tokenize(":")[-1].toLowerCase()}" },
3232
mode: params.publish_dir_mode,
3333
saveAs: { filename -> filename.equals("versions.yml") ? null : filename }
3434
]

conf/test.config

+7-7
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ params {
2323
config_profile_description = 'Minimal test dataset to check pipeline function'
2424

2525
// Input data
26-
input = "https://scil.usherbrooke.ca/scil_test_data/dvc-store/files/md5/0e/edfa604bc9046ae68c9c391a577313"
26+
input = "https://scil.usherbrooke.ca/scil_test_data/dvc-store/files/md5/b9/e0f61087c5a0a8f892ac94ef452d23"
2727

2828
sh_fitting_shells = "0 1000"
29-
pft_seeding = "nt"
30-
pft_nbr_seeds = 400
31-
local_seeding = "nt"
32-
local_nbr_seeds = 400
29+
pft_seeding = "npv"
30+
pft_nbr_seeds = 1
31+
local_seeding = "npv"
32+
local_nbr_seeds = 1
3333
pft_back = 0.5
3434
pft_front = 0.5
35-
run_pft = false
36-
run_local_tracking= false
35+
run_pft_tracking = true
36+
run_local_tracking = true
3737
}

conf/test_full.config

+12-4
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,16 @@ params {
1414
config_profile_name = 'Full test profile'
1515
config_profile_description = 'Full test dataset to check pipeline function'
1616

17-
// Input data for full size test
18-
// TODO nf-core: Specify the paths to your full test data ( on nf-core/test-datasets or directly in repositories, e.g. SRA)
19-
// TODO nf-core: Give any required params for the test so that command line flags are not needed
20-
input = null
17+
// Input data
18+
input = "https://scil.usherbrooke.ca/scil_test_data/dvc-store/files/md5/c0/9dd7d33afb95068a253e3a49f810e2"
19+
20+
sh_fitting_shells = "0 1000"
21+
pft_seeding = "npv"
22+
pft_nbr_seeds = 1
23+
local_seeding = "npv"
24+
local_nbr_seeds = 1
25+
pft_back = 0.5
26+
pft_front = 0.5
27+
run_pft_tracking = true
28+
run_local_tracking= true
2129
}

modules/local/io/safecastinputs/main.nf

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ process IO_SAFECASTINPUTS {
33
label 'process_single'
44

55
input:
6-
tuple val(meta), path(dwi), path(bval), path(bvec), path(sbref), path(rev_dwi), path(rev_bval), path(rev_bvec), path(rev_sbref), path(t1), path(wmparc), path(aparc_aseg), path(lesion)
6+
tuple val(meta), path(dwi, stageAs: "dwi"), path(bval, stageAs: "bval"), path(bvec, stageAs: "bvec"), path(sbref, stageAs: "sbref"), path(rev_dwi, stageAs: "rev"), path(rev_bval, stageAs: "rval"), path(rev_bvec, stageAs: "rvec"), path(rev_sbref, stageAs: "rbref"), path(t1, stageAs: "t1"), path(wmparc, stageAs: "wmparc"), path(aparc_aseg, stageAs: "aparc+aseg"), path(lesion, stageAs: "lesion")
77
output:
88
tuple val(meta), path("$out_dwi"), path("$out_bval"), path("$out_bvec"), path("$out_sbref"), path("$out_rev_dwi"), path("$out_rev_bval"), path("$out_rev_bvec"), path("$out_rev_sbref"), path("$out_t1"), path("$out_wmparc"), path("$out_aparc_aseg"), path("$out_lesion"), emit: safe_inputs
99
script:
@@ -31,7 +31,7 @@ process IO_SAFECASTINPUTS {
3131
[ -f "$t1" ] && ln -sf $t1 t1.nii.gz
3232
[ -f "$wmparc" ] && ln -sf $wmparc wmparc.nii.gz
3333
[ -f "$aparc_aseg" ] && ln -sf $aparc_aseg aparc+aseg.nii.gz
34-
[ -f "$lesion" ] && ln -sf $lesion lesion.nii,gz
34+
[ -f "$lesion" ] && ln -sf $lesion lesion.nii.gz
3535
exit 0
3636
"""
3737
}

nextflow_schema.json

+63
Original file line numberDiff line numberDiff line change
@@ -822,6 +822,66 @@
822822
"hidden": true
823823
}
824824
}
825+
},
826+
"subworkflows_hidden_options": {
827+
"properties": {
828+
"preproc_dwi_run_denoising": {
829+
"type": "boolean",
830+
"hidden": true
831+
},
832+
"preproc_dwi_run_degibbs": {
833+
"type": "boolean",
834+
"hidden": true
835+
},
836+
"topup_eddy_run_topup": {
837+
"type": "boolean",
838+
"hidden": true
839+
},
840+
"topup_eddy_run_eddy": {
841+
"type": "boolean",
842+
"hidden": true
843+
},
844+
"preproc_dwi_run_N4": {
845+
"type": "boolean",
846+
"hidden": true
847+
},
848+
"preproc_t1_run_denoising": {
849+
"type": "boolean",
850+
"hidden": true
851+
},
852+
"preproc_t1_run_N4": {
853+
"type": "boolean",
854+
"hidden": true
855+
},
856+
"preproc_t1_run_synthbet": {
857+
"type": "boolean",
858+
"hidden": true
859+
},
860+
"preproc_t1_run_ants_bet": {
861+
"type": "boolean",
862+
"hidden": true
863+
},
864+
"preproc_t1_run_crop": {
865+
"type": "boolean",
866+
"hidden": true
867+
},
868+
"preproc_dwi_run_resampling": {
869+
"type": "boolean",
870+
"hidden": true
871+
},
872+
"preproc_t1_run_resampling": {
873+
"type": "boolean",
874+
"hidden": true
875+
},
876+
"frf_average_from_data": {
877+
"type": "boolean",
878+
"hidden": true
879+
},
880+
"run_pft": {
881+
"type": "boolean",
882+
"hidden": true
883+
}
884+
}
825885
}
826886
},
827887
"allOf": [
@@ -869,6 +929,9 @@
869929
},
870930
{
871931
"$ref": "#/$defs/local_tractography_options"
932+
},
933+
{
934+
"$ref": "#/$defs/subworkflows_hidden_options"
872935
}
873936
],
874937
"properties": {

0 commit comments

Comments
 (0)