niwrap-mrtrix 0.5.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of niwrap-mrtrix might be problematic. Click here for more details.

Files changed (119) hide show
  1. niwrap_mrtrix/mrtrix/__init__.py +130 -0
  2. niwrap_mrtrix/mrtrix/afdconnectivity.py +445 -0
  3. niwrap_mrtrix/mrtrix/amp2response.py +453 -0
  4. niwrap_mrtrix/mrtrix/amp2sh.py +656 -0
  5. niwrap_mrtrix/mrtrix/connectome2tck.py +470 -0
  6. niwrap_mrtrix/mrtrix/connectomeedit.py +338 -0
  7. niwrap_mrtrix/mrtrix/connectomestats.py +767 -0
  8. niwrap_mrtrix/mrtrix/dcmedit.py +440 -0
  9. niwrap_mrtrix/mrtrix/dcminfo.py +416 -0
  10. niwrap_mrtrix/mrtrix/dirflip.py +362 -0
  11. niwrap_mrtrix/mrtrix/dirgen.py +423 -0
  12. niwrap_mrtrix/mrtrix/dirmerge.py +365 -0
  13. niwrap_mrtrix/mrtrix/dirorder.py +347 -0
  14. niwrap_mrtrix/mrtrix/dirsplit.py +358 -0
  15. niwrap_mrtrix/mrtrix/dirstat.py +530 -0
  16. niwrap_mrtrix/mrtrix/dwi2adc.py +428 -0
  17. niwrap_mrtrix/mrtrix/dwi2fod.py +879 -0
  18. niwrap_mrtrix/mrtrix/dwi2mask.py +463 -0
  19. niwrap_mrtrix/mrtrix/dwi2response.py +1295 -0
  20. niwrap_mrtrix/mrtrix/dwi2tensor.py +587 -0
  21. niwrap_mrtrix/mrtrix/dwibiascorrect.py +467 -0
  22. niwrap_mrtrix/mrtrix/dwidenoise.py +478 -0
  23. niwrap_mrtrix/mrtrix/dwiextract.py +825 -0
  24. niwrap_mrtrix/mrtrix/dwigradcheck.py +534 -0
  25. niwrap_mrtrix/mrtrix/fixel2peaks.py +452 -0
  26. niwrap_mrtrix/mrtrix/fixel2sh.py +357 -0
  27. niwrap_mrtrix/mrtrix/fixel2tsf.py +357 -0
  28. niwrap_mrtrix/mrtrix/fixel2voxel.py +437 -0
  29. niwrap_mrtrix/mrtrix/fixelcfestats.py +893 -0
  30. niwrap_mrtrix/mrtrix/fixelconnectivity.py +391 -0
  31. niwrap_mrtrix/mrtrix/fixelconvert.py +588 -0
  32. niwrap_mrtrix/mrtrix/fixelcorrespondence.py +371 -0
  33. niwrap_mrtrix/mrtrix/fixelcrop.py +348 -0
  34. niwrap_mrtrix/mrtrix/fixelfilter.py +616 -0
  35. niwrap_mrtrix/mrtrix/fixelreorient.py +361 -0
  36. niwrap_mrtrix/mrtrix/fod2dec.py +469 -0
  37. niwrap_mrtrix/mrtrix/fod2fixel.py +530 -0
  38. niwrap_mrtrix/mrtrix/label2colour.py +351 -0
  39. niwrap_mrtrix/mrtrix/label2mesh.py +343 -0
  40. niwrap_mrtrix/mrtrix/labelconvert.py +377 -0
  41. niwrap_mrtrix/mrtrix/labelstats.py +344 -0
  42. niwrap_mrtrix/mrtrix/maskdump.py +336 -0
  43. niwrap_mrtrix/mrtrix/maskfilter.py +537 -0
  44. niwrap_mrtrix/mrtrix/mesh2voxel.py +348 -0
  45. niwrap_mrtrix/mrtrix/meshconvert.py +410 -0
  46. niwrap_mrtrix/mrtrix/meshfilter.py +370 -0
  47. niwrap_mrtrix/mrtrix/mraverageheader.py +396 -0
  48. niwrap_mrtrix/mrtrix/mrcalc.py +3047 -0
  49. niwrap_mrtrix/mrtrix/mrcat.py +382 -0
  50. niwrap_mrtrix/mrtrix/mrcentroid.py +344 -0
  51. niwrap_mrtrix/mrtrix/mrcheckerboardmask.py +363 -0
  52. niwrap_mrtrix/mrtrix/mrclusterstats.py +736 -0
  53. niwrap_mrtrix/mrtrix/mrcolour.py +401 -0
  54. niwrap_mrtrix/mrtrix/mrconvert.py +1423 -0
  55. niwrap_mrtrix/mrtrix/mrdegibbs.py +443 -0
  56. niwrap_mrtrix/mrtrix/mrdump.py +351 -0
  57. niwrap_mrtrix/mrtrix/mredit.py +546 -0
  58. niwrap_mrtrix/mrtrix/mrfilter.py +716 -0
  59. niwrap_mrtrix/mrtrix/mrgrid.py +819 -0
  60. niwrap_mrtrix/mrtrix/mrhistmatch.py +403 -0
  61. niwrap_mrtrix/mrtrix/mrhistogram.py +393 -0
  62. niwrap_mrtrix/mrtrix/mrinfo.py +990 -0
  63. niwrap_mrtrix/mrtrix/mrmath.py +413 -0
  64. niwrap_mrtrix/mrtrix/mrmetric.py +425 -0
  65. niwrap_mrtrix/mrtrix/mrregister.py +1676 -0
  66. niwrap_mrtrix/mrtrix/mrstats.py +427 -0
  67. niwrap_mrtrix/mrtrix/mrthreshold.py +549 -0
  68. niwrap_mrtrix/mrtrix/mrtransform.py +1061 -0
  69. niwrap_mrtrix/mrtrix/mtnormalise.py +596 -0
  70. niwrap_mrtrix/mrtrix/peaks2amp.py +334 -0
  71. niwrap_mrtrix/mrtrix/peaks2fixel.py +349 -0
  72. niwrap_mrtrix/mrtrix/responsemean.py +316 -0
  73. niwrap_mrtrix/mrtrix/sh2amp.py +640 -0
  74. niwrap_mrtrix/mrtrix/sh2peaks.py +505 -0
  75. niwrap_mrtrix/mrtrix/sh2power.py +353 -0
  76. niwrap_mrtrix/mrtrix/sh2response.py +394 -0
  77. niwrap_mrtrix/mrtrix/shbasis.py +373 -0
  78. niwrap_mrtrix/mrtrix/shconv.py +498 -0
  79. niwrap_mrtrix/mrtrix/tck2connectome.py +580 -0
  80. niwrap_mrtrix/mrtrix/tck2fixel.py +363 -0
  81. niwrap_mrtrix/mrtrix/tckconvert.py +580 -0
  82. niwrap_mrtrix/mrtrix/tckdfc.py +551 -0
  83. niwrap_mrtrix/mrtrix/tckedit.py +1003 -0
  84. niwrap_mrtrix/mrtrix/tckgen.py +1983 -0
  85. niwrap_mrtrix/mrtrix/tckglobal.py +758 -0
  86. niwrap_mrtrix/mrtrix/tckinfo.py +329 -0
  87. niwrap_mrtrix/mrtrix/tckmap.py +772 -0
  88. niwrap_mrtrix/mrtrix/tckresample.py +580 -0
  89. niwrap_mrtrix/mrtrix/tcksample.py +404 -0
  90. niwrap_mrtrix/mrtrix/tcksift.py +592 -0
  91. niwrap_mrtrix/mrtrix/tcksift2.py +730 -0
  92. niwrap_mrtrix/mrtrix/tckstats.py +441 -0
  93. niwrap_mrtrix/mrtrix/tcktransform.py +340 -0
  94. niwrap_mrtrix/mrtrix/tensor2metric.py +544 -0
  95. niwrap_mrtrix/mrtrix/transformcalc.py +344 -0
  96. niwrap_mrtrix/mrtrix/transformcompose.py +465 -0
  97. niwrap_mrtrix/mrtrix/transformconvert.py +346 -0
  98. niwrap_mrtrix/mrtrix/tsfdivide.py +340 -0
  99. niwrap_mrtrix/mrtrix/tsfinfo.py +344 -0
  100. niwrap_mrtrix/mrtrix/tsfmult.py +340 -0
  101. niwrap_mrtrix/mrtrix/tsfsmooth.py +347 -0
  102. niwrap_mrtrix/mrtrix/tsfthreshold.py +349 -0
  103. niwrap_mrtrix/mrtrix/tsfvalidate.py +328 -0
  104. niwrap_mrtrix/mrtrix/v_5tt2gmwmi.py +359 -0
  105. niwrap_mrtrix/mrtrix/v_5tt2vis.py +412 -0
  106. niwrap_mrtrix/mrtrix/v_5ttcheck.py +337 -0
  107. niwrap_mrtrix/mrtrix/v_5ttedit.py +420 -0
  108. niwrap_mrtrix/mrtrix/v_5ttgen.py +816 -0
  109. niwrap_mrtrix/mrtrix/vectorstats.py +585 -0
  110. niwrap_mrtrix/mrtrix/voxel2fixel.py +350 -0
  111. niwrap_mrtrix/mrtrix/voxel2mesh.py +376 -0
  112. niwrap_mrtrix/mrtrix/warp2metric.py +449 -0
  113. niwrap_mrtrix/mrtrix/warpconvert.py +411 -0
  114. niwrap_mrtrix/mrtrix/warpcorrect.py +368 -0
  115. niwrap_mrtrix/mrtrix/warpinit.py +356 -0
  116. niwrap_mrtrix/mrtrix/warpinvert.py +370 -0
  117. niwrap_mrtrix-0.5.0.dist-info/METADATA +8 -0
  118. niwrap_mrtrix-0.5.0.dist-info/RECORD +119 -0
  119. niwrap_mrtrix-0.5.0.dist-info/WHEEL +4 -0
@@ -0,0 +1,469 @@
1
+ # This file was auto generated by Styx.
2
+ # Do not edit this file directly.
3
+
4
+ import typing
5
+ import pathlib
6
+ from styxdefs import *
7
+
8
+ FOD2DEC_METADATA = Metadata(
9
+ id="464092d0c46e0f6d44851c80e38f43548c357c00.boutiques",
10
+ name="fod2dec",
11
+ package="mrtrix",
12
+ container_image_tag="mrtrix3/mrtrix3:3.0.4",
13
+ )
14
+
15
+
16
+ Fod2decConfigParameters = typing.TypedDict('Fod2decConfigParameters', {
17
+ "__STYX_TYPE__": typing.Literal["config"],
18
+ "key": str,
19
+ "value": str,
20
+ })
21
+
22
+
23
+ Fod2decParameters = typing.TypedDict('Fod2decParameters', {
24
+ "__STYX_TYPE__": typing.Literal["fod2dec"],
25
+ "mask": typing.NotRequired[InputPathType | None],
26
+ "contrast": typing.NotRequired[InputPathType | None],
27
+ "lum": bool,
28
+ "lum_coefs": typing.NotRequired[list[float] | None],
29
+ "lum_gamma": typing.NotRequired[float | None],
30
+ "threshold": typing.NotRequired[float | None],
31
+ "no_weight": bool,
32
+ "info": bool,
33
+ "quiet": bool,
34
+ "debug": bool,
35
+ "force": bool,
36
+ "nthreads": typing.NotRequired[int | None],
37
+ "config": typing.NotRequired[list[Fod2decConfigParameters] | None],
38
+ "help": bool,
39
+ "version": bool,
40
+ "input": InputPathType,
41
+ "output": str,
42
+ })
43
+
44
+
45
+ def dyn_cargs(
46
+ t: str,
47
+ ) -> typing.Any:
48
+ """
49
+ Get build cargs function by command type.
50
+
51
+ Args:
52
+ t: Command type.
53
+ Returns:
54
+ Build cargs function.
55
+ """
56
+ return {
57
+ "fod2dec": fod2dec_cargs,
58
+ "config": fod2dec_config_cargs,
59
+ }.get(t)
60
+
61
+
62
+ def dyn_outputs(
63
+ t: str,
64
+ ) -> typing.Any:
65
+ """
66
+ Get build outputs function by command type.
67
+
68
+ Args:
69
+ t: Command type.
70
+ Returns:
71
+ Build outputs function.
72
+ """
73
+ return {
74
+ "fod2dec": fod2dec_outputs,
75
+ }.get(t)
76
+
77
+
78
+ def fod2dec_config_params(
79
+ key: str,
80
+ value: str,
81
+ ) -> Fod2decConfigParameters:
82
+ """
83
+ Build parameters.
84
+
85
+ Args:
86
+ key: temporarily set the value of an MRtrix config file entry.
87
+ value: temporarily set the value of an MRtrix config file entry.
88
+ Returns:
89
+ Parameter dictionary
90
+ """
91
+ params = {
92
+ "__STYXTYPE__": "config",
93
+ "key": key,
94
+ "value": value,
95
+ }
96
+ return params
97
+
98
+
99
+ def fod2dec_config_cargs(
100
+ params: Fod2decConfigParameters,
101
+ execution: Execution,
102
+ ) -> list[str]:
103
+ """
104
+ Build command-line arguments from parameters.
105
+
106
+ Args:
107
+ params: The parameters.
108
+ execution: The execution object for resolving input paths.
109
+ Returns:
110
+ Command-line arguments.
111
+ """
112
+ cargs = []
113
+ cargs.append("-config")
114
+ cargs.append(params.get("key"))
115
+ cargs.append(params.get("value"))
116
+ return cargs
117
+
118
+
119
+ class Fod2decOutputs(typing.NamedTuple):
120
+ """
121
+ Output object returned when calling `fod2dec(...)`.
122
+ """
123
+ root: OutputPathType
124
+ """Output root folder. This is the root folder for all outputs."""
125
+ output: OutputPathType
126
+ """The output DEC image (weighted RGB triplets)."""
127
+
128
+
129
+ def fod2dec_params(
130
+ input_: InputPathType,
131
+ output: str,
132
+ mask: InputPathType | None = None,
133
+ contrast: InputPathType | None = None,
134
+ lum: bool = False,
135
+ lum_coefs: list[float] | None = None,
136
+ lum_gamma: float | None = None,
137
+ threshold: float | None = None,
138
+ no_weight: bool = False,
139
+ info: bool = False,
140
+ quiet: bool = False,
141
+ debug: bool = False,
142
+ force: bool = False,
143
+ nthreads: int | None = None,
144
+ config: list[Fod2decConfigParameters] | None = None,
145
+ help_: bool = False,
146
+ version: bool = False,
147
+ ) -> Fod2decParameters:
148
+ """
149
+ Build parameters.
150
+
151
+ Args:
152
+ input_: The input FOD image (spherical harmonic coefficients).
153
+ output: The output DEC image (weighted RGB triplets).
154
+ mask: Only perform DEC computation within the specified mask image.
155
+ contrast: Weight the computed DEC map by the provided image contrast.\
156
+ If the contrast has a different image grid, the DEC map is first\
157
+ resliced and renormalised. To achieve panchromatic sharpening, provide\
158
+ an image with a higher spatial resolution than the input FOD image;\
159
+ e.g., a T1 anatomical volume. Only the DEC is subject to the mask, so\
160
+ as to allow for partial colouring of the contrast image.\
161
+ Default when this option is *not* provided: integral of input FOD,\
162
+ subject to the same mask/threshold as used for DEC computation.
163
+ lum: Correct for luminance/perception, using default values Cr,Cg,Cb =\
164
+ 0.3,0.5,0.2 and gamma = 2.2 (*not* correcting is the theoretical\
165
+ equivalent of Cr,Cg,Cb = 1,1,1 and gamma = 2).
166
+ lum_coefs: The coefficients Cr,Cg,Cb to correct for\
167
+ luminance/perception.\
168
+ Note: this implicitly switches on luminance/perception correction,\
169
+ using a default gamma = 2.2 unless specified otherwise.
170
+ lum_gamma: The gamma value to correct for luminance/perception.\
171
+ Note: this implicitly switches on luminance/perception correction,\
172
+ using a default Cr,Cg,Cb = 0.3,0.5,0.2 unless specified otherwise.
173
+ threshold: FOD amplitudes below the threshold value are considered\
174
+ zero.
175
+ no_weight: Do not weight the DEC map; just output the unweighted\
176
+ colours. Reslicing and renormalising of colours will still happen when\
177
+ providing the -contrast option as a template.
178
+ info: display information messages.
179
+ quiet: do not display information messages or progress status;\
180
+ alternatively, this can be achieved by setting the MRTRIX_QUIET\
181
+ environment variable to a non-empty string.
182
+ debug: display debugging messages.
183
+ force: force overwrite of output files (caution: using the same file as\
184
+ input and output might cause unexpected behaviour).
185
+ nthreads: use this number of threads in multi-threaded applications\
186
+ (set to 0 to disable multi-threading).
187
+ config: temporarily set the value of an MRtrix config file entry.
188
+ help_: display this information page and exit.
189
+ version: display version information and exit.
190
+ Returns:
191
+ Parameter dictionary
192
+ """
193
+ params = {
194
+ "__STYXTYPE__": "fod2dec",
195
+ "lum": lum,
196
+ "no_weight": no_weight,
197
+ "info": info,
198
+ "quiet": quiet,
199
+ "debug": debug,
200
+ "force": force,
201
+ "help": help_,
202
+ "version": version,
203
+ "input": input_,
204
+ "output": output,
205
+ }
206
+ if mask is not None:
207
+ params["mask"] = mask
208
+ if contrast is not None:
209
+ params["contrast"] = contrast
210
+ if lum_coefs is not None:
211
+ params["lum_coefs"] = lum_coefs
212
+ if lum_gamma is not None:
213
+ params["lum_gamma"] = lum_gamma
214
+ if threshold is not None:
215
+ params["threshold"] = threshold
216
+ if nthreads is not None:
217
+ params["nthreads"] = nthreads
218
+ if config is not None:
219
+ params["config"] = config
220
+ return params
221
+
222
+
223
+ def fod2dec_cargs(
224
+ params: Fod2decParameters,
225
+ execution: Execution,
226
+ ) -> list[str]:
227
+ """
228
+ Build command-line arguments from parameters.
229
+
230
+ Args:
231
+ params: The parameters.
232
+ execution: The execution object for resolving input paths.
233
+ Returns:
234
+ Command-line arguments.
235
+ """
236
+ cargs = []
237
+ cargs.append("fod2dec")
238
+ if params.get("mask") is not None:
239
+ cargs.extend([
240
+ "-mask",
241
+ execution.input_file(params.get("mask"))
242
+ ])
243
+ if params.get("contrast") is not None:
244
+ cargs.extend([
245
+ "-contrast",
246
+ execution.input_file(params.get("contrast"))
247
+ ])
248
+ if params.get("lum"):
249
+ cargs.append("-lum")
250
+ if params.get("lum_coefs") is not None:
251
+ cargs.extend([
252
+ "-lum_coefs",
253
+ *map(str, params.get("lum_coefs"))
254
+ ])
255
+ if params.get("lum_gamma") is not None:
256
+ cargs.extend([
257
+ "-lum_gamma",
258
+ str(params.get("lum_gamma"))
259
+ ])
260
+ if params.get("threshold") is not None:
261
+ cargs.extend([
262
+ "-threshold",
263
+ str(params.get("threshold"))
264
+ ])
265
+ if params.get("no_weight"):
266
+ cargs.append("-no_weight")
267
+ if params.get("info"):
268
+ cargs.append("-info")
269
+ if params.get("quiet"):
270
+ cargs.append("-quiet")
271
+ if params.get("debug"):
272
+ cargs.append("-debug")
273
+ if params.get("force"):
274
+ cargs.append("-force")
275
+ if params.get("nthreads") is not None:
276
+ cargs.extend([
277
+ "-nthreads",
278
+ str(params.get("nthreads"))
279
+ ])
280
+ if params.get("config") is not None:
281
+ cargs.extend([a for c in [dyn_cargs(s["__STYXTYPE__"])(s, execution) for s in params.get("config")] for a in c])
282
+ if params.get("help"):
283
+ cargs.append("-help")
284
+ if params.get("version"):
285
+ cargs.append("-version")
286
+ cargs.append(execution.input_file(params.get("input")))
287
+ cargs.append(params.get("output"))
288
+ return cargs
289
+
290
+
291
+ def fod2dec_outputs(
292
+ params: Fod2decParameters,
293
+ execution: Execution,
294
+ ) -> Fod2decOutputs:
295
+ """
296
+ Build outputs object containing output file paths and possibly stdout/stderr.
297
+
298
+ Args:
299
+ params: The parameters.
300
+ execution: The execution object for resolving input paths.
301
+ Returns:
302
+ Outputs object.
303
+ """
304
+ ret = Fod2decOutputs(
305
+ root=execution.output_file("."),
306
+ output=execution.output_file(params.get("output")),
307
+ )
308
+ return ret
309
+
310
+
311
+ def fod2dec_execute(
312
+ params: Fod2decParameters,
313
+ execution: Execution,
314
+ ) -> Fod2decOutputs:
315
+ """
316
+ Generate FOD-based DEC maps, with optional panchromatic sharpening and/or
317
+ luminance/perception correction.
318
+
319
+ By default, the FOD-based DEC is weighted by the integral of the FOD. To
320
+ weight by another scalar map, use the -contrast option. This option can also
321
+ be used for panchromatic sharpening, e.g., by supplying a T1 (or other
322
+ sensible) anatomical volume with a higher spatial resolution.
323
+
324
+ References:
325
+
326
+ Dhollander T, Smith RE, Tournier JD, Jeurissen B, Connelly A. Time to move
327
+ on: an FOD-based DEC map to replace DTI's trademark DEC FA. Proc Intl Soc
328
+ Mag Reson Med, 2015, 23, 1027
329
+
330
+ Dhollander T, Raffelt D, Smith RE, Connelly A. Panchromatic sharpening of
331
+ FOD-based DEC maps by structural T1 information. Proc Intl Soc Mag Reson
332
+ Med, 2015, 23, 566.
333
+
334
+ Author: MRTrix3 Developers
335
+
336
+ URL: https://www.mrtrix.org/
337
+
338
+ Args:
339
+ params: The parameters.
340
+ execution: The execution object.
341
+ Returns:
342
+ NamedTuple of outputs (described in `Fod2decOutputs`).
343
+ """
344
+ params = execution.params(params)
345
+ cargs = fod2dec_cargs(params, execution)
346
+ ret = fod2dec_outputs(params, execution)
347
+ execution.run(cargs)
348
+ return ret
349
+
350
+
351
+ def fod2dec(
352
+ input_: InputPathType,
353
+ output: str,
354
+ mask: InputPathType | None = None,
355
+ contrast: InputPathType | None = None,
356
+ lum: bool = False,
357
+ lum_coefs: list[float] | None = None,
358
+ lum_gamma: float | None = None,
359
+ threshold: float | None = None,
360
+ no_weight: bool = False,
361
+ info: bool = False,
362
+ quiet: bool = False,
363
+ debug: bool = False,
364
+ force: bool = False,
365
+ nthreads: int | None = None,
366
+ config: list[Fod2decConfigParameters] | None = None,
367
+ help_: bool = False,
368
+ version: bool = False,
369
+ runner: Runner | None = None,
370
+ ) -> Fod2decOutputs:
371
+ """
372
+ Generate FOD-based DEC maps, with optional panchromatic sharpening and/or
373
+ luminance/perception correction.
374
+
375
+ By default, the FOD-based DEC is weighted by the integral of the FOD. To
376
+ weight by another scalar map, use the -contrast option. This option can also
377
+ be used for panchromatic sharpening, e.g., by supplying a T1 (or other
378
+ sensible) anatomical volume with a higher spatial resolution.
379
+
380
+ References:
381
+
382
+ Dhollander T, Smith RE, Tournier JD, Jeurissen B, Connelly A. Time to move
383
+ on: an FOD-based DEC map to replace DTI's trademark DEC FA. Proc Intl Soc
384
+ Mag Reson Med, 2015, 23, 1027
385
+
386
+ Dhollander T, Raffelt D, Smith RE, Connelly A. Panchromatic sharpening of
387
+ FOD-based DEC maps by structural T1 information. Proc Intl Soc Mag Reson
388
+ Med, 2015, 23, 566.
389
+
390
+ Author: MRTrix3 Developers
391
+
392
+ URL: https://www.mrtrix.org/
393
+
394
+ Args:
395
+ input_: The input FOD image (spherical harmonic coefficients).
396
+ output: The output DEC image (weighted RGB triplets).
397
+ mask: Only perform DEC computation within the specified mask image.
398
+ contrast: Weight the computed DEC map by the provided image contrast.\
399
+ If the contrast has a different image grid, the DEC map is first\
400
+ resliced and renormalised. To achieve panchromatic sharpening, provide\
401
+ an image with a higher spatial resolution than the input FOD image;\
402
+ e.g., a T1 anatomical volume. Only the DEC is subject to the mask, so\
403
+ as to allow for partial colouring of the contrast image.\
404
+ Default when this option is *not* provided: integral of input FOD,\
405
+ subject to the same mask/threshold as used for DEC computation.
406
+ lum: Correct for luminance/perception, using default values Cr,Cg,Cb =\
407
+ 0.3,0.5,0.2 and gamma = 2.2 (*not* correcting is the theoretical\
408
+ equivalent of Cr,Cg,Cb = 1,1,1 and gamma = 2).
409
+ lum_coefs: The coefficients Cr,Cg,Cb to correct for\
410
+ luminance/perception.\
411
+ Note: this implicitly switches on luminance/perception correction,\
412
+ using a default gamma = 2.2 unless specified otherwise.
413
+ lum_gamma: The gamma value to correct for luminance/perception.\
414
+ Note: this implicitly switches on luminance/perception correction,\
415
+ using a default Cr,Cg,Cb = 0.3,0.5,0.2 unless specified otherwise.
416
+ threshold: FOD amplitudes below the threshold value are considered\
417
+ zero.
418
+ no_weight: Do not weight the DEC map; just output the unweighted\
419
+ colours. Reslicing and renormalising of colours will still happen when\
420
+ providing the -contrast option as a template.
421
+ info: display information messages.
422
+ quiet: do not display information messages or progress status;\
423
+ alternatively, this can be achieved by setting the MRTRIX_QUIET\
424
+ environment variable to a non-empty string.
425
+ debug: display debugging messages.
426
+ force: force overwrite of output files (caution: using the same file as\
427
+ input and output might cause unexpected behaviour).
428
+ nthreads: use this number of threads in multi-threaded applications\
429
+ (set to 0 to disable multi-threading).
430
+ config: temporarily set the value of an MRtrix config file entry.
431
+ help_: display this information page and exit.
432
+ version: display version information and exit.
433
+ runner: Command runner.
434
+ Returns:
435
+ NamedTuple of outputs (described in `Fod2decOutputs`).
436
+ """
437
+ runner = runner or get_global_runner()
438
+ execution = runner.start_execution(FOD2DEC_METADATA)
439
+ params = fod2dec_params(
440
+ mask=mask,
441
+ contrast=contrast,
442
+ lum=lum,
443
+ lum_coefs=lum_coefs,
444
+ lum_gamma=lum_gamma,
445
+ threshold=threshold,
446
+ no_weight=no_weight,
447
+ info=info,
448
+ quiet=quiet,
449
+ debug=debug,
450
+ force=force,
451
+ nthreads=nthreads,
452
+ config=config,
453
+ help_=help_,
454
+ version=version,
455
+ input_=input_,
456
+ output=output,
457
+ )
458
+ return fod2dec_execute(params, execution)
459
+
460
+
461
+ __all__ = [
462
+ "FOD2DEC_METADATA",
463
+ "Fod2decConfigParameters",
464
+ "Fod2decOutputs",
465
+ "Fod2decParameters",
466
+ "fod2dec",
467
+ "fod2dec_config_params",
468
+ "fod2dec_params",
469
+ ]