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.
- niwrap_mrtrix/mrtrix/__init__.py +130 -0
- niwrap_mrtrix/mrtrix/afdconnectivity.py +445 -0
- niwrap_mrtrix/mrtrix/amp2response.py +453 -0
- niwrap_mrtrix/mrtrix/amp2sh.py +656 -0
- niwrap_mrtrix/mrtrix/connectome2tck.py +470 -0
- niwrap_mrtrix/mrtrix/connectomeedit.py +338 -0
- niwrap_mrtrix/mrtrix/connectomestats.py +767 -0
- niwrap_mrtrix/mrtrix/dcmedit.py +440 -0
- niwrap_mrtrix/mrtrix/dcminfo.py +416 -0
- niwrap_mrtrix/mrtrix/dirflip.py +362 -0
- niwrap_mrtrix/mrtrix/dirgen.py +423 -0
- niwrap_mrtrix/mrtrix/dirmerge.py +365 -0
- niwrap_mrtrix/mrtrix/dirorder.py +347 -0
- niwrap_mrtrix/mrtrix/dirsplit.py +358 -0
- niwrap_mrtrix/mrtrix/dirstat.py +530 -0
- niwrap_mrtrix/mrtrix/dwi2adc.py +428 -0
- niwrap_mrtrix/mrtrix/dwi2fod.py +879 -0
- niwrap_mrtrix/mrtrix/dwi2mask.py +463 -0
- niwrap_mrtrix/mrtrix/dwi2response.py +1295 -0
- niwrap_mrtrix/mrtrix/dwi2tensor.py +587 -0
- niwrap_mrtrix/mrtrix/dwibiascorrect.py +467 -0
- niwrap_mrtrix/mrtrix/dwidenoise.py +478 -0
- niwrap_mrtrix/mrtrix/dwiextract.py +825 -0
- niwrap_mrtrix/mrtrix/dwigradcheck.py +534 -0
- niwrap_mrtrix/mrtrix/fixel2peaks.py +452 -0
- niwrap_mrtrix/mrtrix/fixel2sh.py +357 -0
- niwrap_mrtrix/mrtrix/fixel2tsf.py +357 -0
- niwrap_mrtrix/mrtrix/fixel2voxel.py +437 -0
- niwrap_mrtrix/mrtrix/fixelcfestats.py +893 -0
- niwrap_mrtrix/mrtrix/fixelconnectivity.py +391 -0
- niwrap_mrtrix/mrtrix/fixelconvert.py +588 -0
- niwrap_mrtrix/mrtrix/fixelcorrespondence.py +371 -0
- niwrap_mrtrix/mrtrix/fixelcrop.py +348 -0
- niwrap_mrtrix/mrtrix/fixelfilter.py +616 -0
- niwrap_mrtrix/mrtrix/fixelreorient.py +361 -0
- niwrap_mrtrix/mrtrix/fod2dec.py +469 -0
- niwrap_mrtrix/mrtrix/fod2fixel.py +530 -0
- niwrap_mrtrix/mrtrix/label2colour.py +351 -0
- niwrap_mrtrix/mrtrix/label2mesh.py +343 -0
- niwrap_mrtrix/mrtrix/labelconvert.py +377 -0
- niwrap_mrtrix/mrtrix/labelstats.py +344 -0
- niwrap_mrtrix/mrtrix/maskdump.py +336 -0
- niwrap_mrtrix/mrtrix/maskfilter.py +537 -0
- niwrap_mrtrix/mrtrix/mesh2voxel.py +348 -0
- niwrap_mrtrix/mrtrix/meshconvert.py +410 -0
- niwrap_mrtrix/mrtrix/meshfilter.py +370 -0
- niwrap_mrtrix/mrtrix/mraverageheader.py +396 -0
- niwrap_mrtrix/mrtrix/mrcalc.py +3047 -0
- niwrap_mrtrix/mrtrix/mrcat.py +382 -0
- niwrap_mrtrix/mrtrix/mrcentroid.py +344 -0
- niwrap_mrtrix/mrtrix/mrcheckerboardmask.py +363 -0
- niwrap_mrtrix/mrtrix/mrclusterstats.py +736 -0
- niwrap_mrtrix/mrtrix/mrcolour.py +401 -0
- niwrap_mrtrix/mrtrix/mrconvert.py +1423 -0
- niwrap_mrtrix/mrtrix/mrdegibbs.py +443 -0
- niwrap_mrtrix/mrtrix/mrdump.py +351 -0
- niwrap_mrtrix/mrtrix/mredit.py +546 -0
- niwrap_mrtrix/mrtrix/mrfilter.py +716 -0
- niwrap_mrtrix/mrtrix/mrgrid.py +819 -0
- niwrap_mrtrix/mrtrix/mrhistmatch.py +403 -0
- niwrap_mrtrix/mrtrix/mrhistogram.py +393 -0
- niwrap_mrtrix/mrtrix/mrinfo.py +990 -0
- niwrap_mrtrix/mrtrix/mrmath.py +413 -0
- niwrap_mrtrix/mrtrix/mrmetric.py +425 -0
- niwrap_mrtrix/mrtrix/mrregister.py +1676 -0
- niwrap_mrtrix/mrtrix/mrstats.py +427 -0
- niwrap_mrtrix/mrtrix/mrthreshold.py +549 -0
- niwrap_mrtrix/mrtrix/mrtransform.py +1061 -0
- niwrap_mrtrix/mrtrix/mtnormalise.py +596 -0
- niwrap_mrtrix/mrtrix/peaks2amp.py +334 -0
- niwrap_mrtrix/mrtrix/peaks2fixel.py +349 -0
- niwrap_mrtrix/mrtrix/responsemean.py +316 -0
- niwrap_mrtrix/mrtrix/sh2amp.py +640 -0
- niwrap_mrtrix/mrtrix/sh2peaks.py +505 -0
- niwrap_mrtrix/mrtrix/sh2power.py +353 -0
- niwrap_mrtrix/mrtrix/sh2response.py +394 -0
- niwrap_mrtrix/mrtrix/shbasis.py +373 -0
- niwrap_mrtrix/mrtrix/shconv.py +498 -0
- niwrap_mrtrix/mrtrix/tck2connectome.py +580 -0
- niwrap_mrtrix/mrtrix/tck2fixel.py +363 -0
- niwrap_mrtrix/mrtrix/tckconvert.py +580 -0
- niwrap_mrtrix/mrtrix/tckdfc.py +551 -0
- niwrap_mrtrix/mrtrix/tckedit.py +1003 -0
- niwrap_mrtrix/mrtrix/tckgen.py +1983 -0
- niwrap_mrtrix/mrtrix/tckglobal.py +758 -0
- niwrap_mrtrix/mrtrix/tckinfo.py +329 -0
- niwrap_mrtrix/mrtrix/tckmap.py +772 -0
- niwrap_mrtrix/mrtrix/tckresample.py +580 -0
- niwrap_mrtrix/mrtrix/tcksample.py +404 -0
- niwrap_mrtrix/mrtrix/tcksift.py +592 -0
- niwrap_mrtrix/mrtrix/tcksift2.py +730 -0
- niwrap_mrtrix/mrtrix/tckstats.py +441 -0
- niwrap_mrtrix/mrtrix/tcktransform.py +340 -0
- niwrap_mrtrix/mrtrix/tensor2metric.py +544 -0
- niwrap_mrtrix/mrtrix/transformcalc.py +344 -0
- niwrap_mrtrix/mrtrix/transformcompose.py +465 -0
- niwrap_mrtrix/mrtrix/transformconvert.py +346 -0
- niwrap_mrtrix/mrtrix/tsfdivide.py +340 -0
- niwrap_mrtrix/mrtrix/tsfinfo.py +344 -0
- niwrap_mrtrix/mrtrix/tsfmult.py +340 -0
- niwrap_mrtrix/mrtrix/tsfsmooth.py +347 -0
- niwrap_mrtrix/mrtrix/tsfthreshold.py +349 -0
- niwrap_mrtrix/mrtrix/tsfvalidate.py +328 -0
- niwrap_mrtrix/mrtrix/v_5tt2gmwmi.py +359 -0
- niwrap_mrtrix/mrtrix/v_5tt2vis.py +412 -0
- niwrap_mrtrix/mrtrix/v_5ttcheck.py +337 -0
- niwrap_mrtrix/mrtrix/v_5ttedit.py +420 -0
- niwrap_mrtrix/mrtrix/v_5ttgen.py +816 -0
- niwrap_mrtrix/mrtrix/vectorstats.py +585 -0
- niwrap_mrtrix/mrtrix/voxel2fixel.py +350 -0
- niwrap_mrtrix/mrtrix/voxel2mesh.py +376 -0
- niwrap_mrtrix/mrtrix/warp2metric.py +449 -0
- niwrap_mrtrix/mrtrix/warpconvert.py +411 -0
- niwrap_mrtrix/mrtrix/warpcorrect.py +368 -0
- niwrap_mrtrix/mrtrix/warpinit.py +356 -0
- niwrap_mrtrix/mrtrix/warpinvert.py +370 -0
- niwrap_mrtrix-0.5.0.dist-info/METADATA +8 -0
- niwrap_mrtrix-0.5.0.dist-info/RECORD +119 -0
- niwrap_mrtrix-0.5.0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,394 @@
|
|
|
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
|
+
SH2RESPONSE_METADATA = Metadata(
|
|
9
|
+
id="73af982ff7a9439d2a7181a0cb546efa4f302105.boutiques",
|
|
10
|
+
name="sh2response",
|
|
11
|
+
package="mrtrix",
|
|
12
|
+
container_image_tag="mrtrix3/mrtrix3:3.0.4",
|
|
13
|
+
)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
Sh2responseConfigParameters = typing.TypedDict('Sh2responseConfigParameters', {
|
|
17
|
+
"__STYX_TYPE__": typing.Literal["config"],
|
|
18
|
+
"key": str,
|
|
19
|
+
"value": str,
|
|
20
|
+
})
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
Sh2responseParameters = typing.TypedDict('Sh2responseParameters', {
|
|
24
|
+
"__STYX_TYPE__": typing.Literal["sh2response"],
|
|
25
|
+
"lmax": typing.NotRequired[int | None],
|
|
26
|
+
"dump": typing.NotRequired[str | None],
|
|
27
|
+
"info": bool,
|
|
28
|
+
"quiet": bool,
|
|
29
|
+
"debug": bool,
|
|
30
|
+
"force": bool,
|
|
31
|
+
"nthreads": typing.NotRequired[int | None],
|
|
32
|
+
"config": typing.NotRequired[list[Sh2responseConfigParameters] | None],
|
|
33
|
+
"help": bool,
|
|
34
|
+
"version": bool,
|
|
35
|
+
"SH": InputPathType,
|
|
36
|
+
"mask": InputPathType,
|
|
37
|
+
"directions": InputPathType,
|
|
38
|
+
"response": str,
|
|
39
|
+
})
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def dyn_cargs(
|
|
43
|
+
t: str,
|
|
44
|
+
) -> typing.Any:
|
|
45
|
+
"""
|
|
46
|
+
Get build cargs function by command type.
|
|
47
|
+
|
|
48
|
+
Args:
|
|
49
|
+
t: Command type.
|
|
50
|
+
Returns:
|
|
51
|
+
Build cargs function.
|
|
52
|
+
"""
|
|
53
|
+
return {
|
|
54
|
+
"sh2response": sh2response_cargs,
|
|
55
|
+
"config": sh2response_config_cargs,
|
|
56
|
+
}.get(t)
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
def dyn_outputs(
|
|
60
|
+
t: str,
|
|
61
|
+
) -> typing.Any:
|
|
62
|
+
"""
|
|
63
|
+
Get build outputs function by command type.
|
|
64
|
+
|
|
65
|
+
Args:
|
|
66
|
+
t: Command type.
|
|
67
|
+
Returns:
|
|
68
|
+
Build outputs function.
|
|
69
|
+
"""
|
|
70
|
+
return {
|
|
71
|
+
"sh2response": sh2response_outputs,
|
|
72
|
+
}.get(t)
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
def sh2response_config_params(
|
|
76
|
+
key: str,
|
|
77
|
+
value: str,
|
|
78
|
+
) -> Sh2responseConfigParameters:
|
|
79
|
+
"""
|
|
80
|
+
Build parameters.
|
|
81
|
+
|
|
82
|
+
Args:
|
|
83
|
+
key: temporarily set the value of an MRtrix config file entry.
|
|
84
|
+
value: temporarily set the value of an MRtrix config file entry.
|
|
85
|
+
Returns:
|
|
86
|
+
Parameter dictionary
|
|
87
|
+
"""
|
|
88
|
+
params = {
|
|
89
|
+
"__STYXTYPE__": "config",
|
|
90
|
+
"key": key,
|
|
91
|
+
"value": value,
|
|
92
|
+
}
|
|
93
|
+
return params
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
def sh2response_config_cargs(
|
|
97
|
+
params: Sh2responseConfigParameters,
|
|
98
|
+
execution: Execution,
|
|
99
|
+
) -> list[str]:
|
|
100
|
+
"""
|
|
101
|
+
Build command-line arguments from parameters.
|
|
102
|
+
|
|
103
|
+
Args:
|
|
104
|
+
params: The parameters.
|
|
105
|
+
execution: The execution object for resolving input paths.
|
|
106
|
+
Returns:
|
|
107
|
+
Command-line arguments.
|
|
108
|
+
"""
|
|
109
|
+
cargs = []
|
|
110
|
+
cargs.append("-config")
|
|
111
|
+
cargs.append(params.get("key"))
|
|
112
|
+
cargs.append(params.get("value"))
|
|
113
|
+
return cargs
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
class Sh2responseOutputs(typing.NamedTuple):
|
|
117
|
+
"""
|
|
118
|
+
Output object returned when calling `sh2response(...)`.
|
|
119
|
+
"""
|
|
120
|
+
root: OutputPathType
|
|
121
|
+
"""Output root folder. This is the root folder for all outputs."""
|
|
122
|
+
response: OutputPathType
|
|
123
|
+
"""the output axially-symmetric spherical harmonic coefficients"""
|
|
124
|
+
dump: OutputPathType | None
|
|
125
|
+
"""dump the m=0 SH coefficients from all voxels in the mask to the output
|
|
126
|
+
file, rather than their mean """
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
def sh2response_params(
|
|
130
|
+
sh: InputPathType,
|
|
131
|
+
mask: InputPathType,
|
|
132
|
+
directions: InputPathType,
|
|
133
|
+
response: str,
|
|
134
|
+
lmax: int | None = None,
|
|
135
|
+
dump: str | None = None,
|
|
136
|
+
info: bool = False,
|
|
137
|
+
quiet: bool = False,
|
|
138
|
+
debug: bool = False,
|
|
139
|
+
force: bool = False,
|
|
140
|
+
nthreads: int | None = None,
|
|
141
|
+
config: list[Sh2responseConfigParameters] | None = None,
|
|
142
|
+
help_: bool = False,
|
|
143
|
+
version: bool = False,
|
|
144
|
+
) -> Sh2responseParameters:
|
|
145
|
+
"""
|
|
146
|
+
Build parameters.
|
|
147
|
+
|
|
148
|
+
Args:
|
|
149
|
+
sh: the spherical harmonic decomposition of the diffusion-weighted\
|
|
150
|
+
images.
|
|
151
|
+
mask: the mask containing the voxels from which to estimate the\
|
|
152
|
+
response function.
|
|
153
|
+
directions: a 4D image containing the direction vectors along which to\
|
|
154
|
+
estimate the response function.
|
|
155
|
+
response: the output axially-symmetric spherical harmonic coefficients.
|
|
156
|
+
lmax: specify the maximum harmonic degree of the response function to\
|
|
157
|
+
estimate.
|
|
158
|
+
dump: dump the m=0 SH coefficients from all voxels in the mask to the\
|
|
159
|
+
output file, rather than their mean.
|
|
160
|
+
info: display information messages.
|
|
161
|
+
quiet: do not display information messages or progress status;\
|
|
162
|
+
alternatively, this can be achieved by setting the MRTRIX_QUIET\
|
|
163
|
+
environment variable to a non-empty string.
|
|
164
|
+
debug: display debugging messages.
|
|
165
|
+
force: force overwrite of output files (caution: using the same file as\
|
|
166
|
+
input and output might cause unexpected behaviour).
|
|
167
|
+
nthreads: use this number of threads in multi-threaded applications\
|
|
168
|
+
(set to 0 to disable multi-threading).
|
|
169
|
+
config: temporarily set the value of an MRtrix config file entry.
|
|
170
|
+
help_: display this information page and exit.
|
|
171
|
+
version: display version information and exit.
|
|
172
|
+
Returns:
|
|
173
|
+
Parameter dictionary
|
|
174
|
+
"""
|
|
175
|
+
params = {
|
|
176
|
+
"__STYXTYPE__": "sh2response",
|
|
177
|
+
"info": info,
|
|
178
|
+
"quiet": quiet,
|
|
179
|
+
"debug": debug,
|
|
180
|
+
"force": force,
|
|
181
|
+
"help": help_,
|
|
182
|
+
"version": version,
|
|
183
|
+
"SH": sh,
|
|
184
|
+
"mask": mask,
|
|
185
|
+
"directions": directions,
|
|
186
|
+
"response": response,
|
|
187
|
+
}
|
|
188
|
+
if lmax is not None:
|
|
189
|
+
params["lmax"] = lmax
|
|
190
|
+
if dump is not None:
|
|
191
|
+
params["dump"] = dump
|
|
192
|
+
if nthreads is not None:
|
|
193
|
+
params["nthreads"] = nthreads
|
|
194
|
+
if config is not None:
|
|
195
|
+
params["config"] = config
|
|
196
|
+
return params
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
def sh2response_cargs(
|
|
200
|
+
params: Sh2responseParameters,
|
|
201
|
+
execution: Execution,
|
|
202
|
+
) -> list[str]:
|
|
203
|
+
"""
|
|
204
|
+
Build command-line arguments from parameters.
|
|
205
|
+
|
|
206
|
+
Args:
|
|
207
|
+
params: The parameters.
|
|
208
|
+
execution: The execution object for resolving input paths.
|
|
209
|
+
Returns:
|
|
210
|
+
Command-line arguments.
|
|
211
|
+
"""
|
|
212
|
+
cargs = []
|
|
213
|
+
cargs.append("sh2response")
|
|
214
|
+
if params.get("lmax") is not None:
|
|
215
|
+
cargs.extend([
|
|
216
|
+
"-lmax",
|
|
217
|
+
str(params.get("lmax"))
|
|
218
|
+
])
|
|
219
|
+
if params.get("dump") is not None:
|
|
220
|
+
cargs.extend([
|
|
221
|
+
"-dump",
|
|
222
|
+
params.get("dump")
|
|
223
|
+
])
|
|
224
|
+
if params.get("info"):
|
|
225
|
+
cargs.append("-info")
|
|
226
|
+
if params.get("quiet"):
|
|
227
|
+
cargs.append("-quiet")
|
|
228
|
+
if params.get("debug"):
|
|
229
|
+
cargs.append("-debug")
|
|
230
|
+
if params.get("force"):
|
|
231
|
+
cargs.append("-force")
|
|
232
|
+
if params.get("nthreads") is not None:
|
|
233
|
+
cargs.extend([
|
|
234
|
+
"-nthreads",
|
|
235
|
+
str(params.get("nthreads"))
|
|
236
|
+
])
|
|
237
|
+
if params.get("config") is not None:
|
|
238
|
+
cargs.extend([a for c in [dyn_cargs(s["__STYXTYPE__"])(s, execution) for s in params.get("config")] for a in c])
|
|
239
|
+
if params.get("help"):
|
|
240
|
+
cargs.append("-help")
|
|
241
|
+
if params.get("version"):
|
|
242
|
+
cargs.append("-version")
|
|
243
|
+
cargs.append(execution.input_file(params.get("SH")))
|
|
244
|
+
cargs.append(execution.input_file(params.get("mask")))
|
|
245
|
+
cargs.append(execution.input_file(params.get("directions")))
|
|
246
|
+
cargs.append(params.get("response"))
|
|
247
|
+
return cargs
|
|
248
|
+
|
|
249
|
+
|
|
250
|
+
def sh2response_outputs(
|
|
251
|
+
params: Sh2responseParameters,
|
|
252
|
+
execution: Execution,
|
|
253
|
+
) -> Sh2responseOutputs:
|
|
254
|
+
"""
|
|
255
|
+
Build outputs object containing output file paths and possibly stdout/stderr.
|
|
256
|
+
|
|
257
|
+
Args:
|
|
258
|
+
params: The parameters.
|
|
259
|
+
execution: The execution object for resolving input paths.
|
|
260
|
+
Returns:
|
|
261
|
+
Outputs object.
|
|
262
|
+
"""
|
|
263
|
+
ret = Sh2responseOutputs(
|
|
264
|
+
root=execution.output_file("."),
|
|
265
|
+
response=execution.output_file(params.get("response")),
|
|
266
|
+
dump=execution.output_file(params.get("dump")) if (params.get("dump") is not None) else None,
|
|
267
|
+
)
|
|
268
|
+
return ret
|
|
269
|
+
|
|
270
|
+
|
|
271
|
+
def sh2response_execute(
|
|
272
|
+
params: Sh2responseParameters,
|
|
273
|
+
execution: Execution,
|
|
274
|
+
) -> Sh2responseOutputs:
|
|
275
|
+
"""
|
|
276
|
+
Generate an appropriate response function from the image data for spherical
|
|
277
|
+
deconvolution.
|
|
278
|
+
|
|
279
|
+
The spherical harmonic coefficients are stored according the conventions
|
|
280
|
+
described the main documentation, which can be found at the following link:
|
|
281
|
+
https://mrtrix.readthedocs.io/en/3.0.4/concepts/spherical_harmonics.html
|
|
282
|
+
|
|
283
|
+
References:
|
|
284
|
+
|
|
285
|
+
.
|
|
286
|
+
|
|
287
|
+
Author: MRTrix3 Developers
|
|
288
|
+
|
|
289
|
+
URL: https://www.mrtrix.org/
|
|
290
|
+
|
|
291
|
+
Args:
|
|
292
|
+
params: The parameters.
|
|
293
|
+
execution: The execution object.
|
|
294
|
+
Returns:
|
|
295
|
+
NamedTuple of outputs (described in `Sh2responseOutputs`).
|
|
296
|
+
"""
|
|
297
|
+
params = execution.params(params)
|
|
298
|
+
cargs = sh2response_cargs(params, execution)
|
|
299
|
+
ret = sh2response_outputs(params, execution)
|
|
300
|
+
execution.run(cargs)
|
|
301
|
+
return ret
|
|
302
|
+
|
|
303
|
+
|
|
304
|
+
def sh2response(
|
|
305
|
+
sh: InputPathType,
|
|
306
|
+
mask: InputPathType,
|
|
307
|
+
directions: InputPathType,
|
|
308
|
+
response: str,
|
|
309
|
+
lmax: int | None = None,
|
|
310
|
+
dump: str | None = None,
|
|
311
|
+
info: bool = False,
|
|
312
|
+
quiet: bool = False,
|
|
313
|
+
debug: bool = False,
|
|
314
|
+
force: bool = False,
|
|
315
|
+
nthreads: int | None = None,
|
|
316
|
+
config: list[Sh2responseConfigParameters] | None = None,
|
|
317
|
+
help_: bool = False,
|
|
318
|
+
version: bool = False,
|
|
319
|
+
runner: Runner | None = None,
|
|
320
|
+
) -> Sh2responseOutputs:
|
|
321
|
+
"""
|
|
322
|
+
Generate an appropriate response function from the image data for spherical
|
|
323
|
+
deconvolution.
|
|
324
|
+
|
|
325
|
+
The spherical harmonic coefficients are stored according the conventions
|
|
326
|
+
described the main documentation, which can be found at the following link:
|
|
327
|
+
https://mrtrix.readthedocs.io/en/3.0.4/concepts/spherical_harmonics.html
|
|
328
|
+
|
|
329
|
+
References:
|
|
330
|
+
|
|
331
|
+
.
|
|
332
|
+
|
|
333
|
+
Author: MRTrix3 Developers
|
|
334
|
+
|
|
335
|
+
URL: https://www.mrtrix.org/
|
|
336
|
+
|
|
337
|
+
Args:
|
|
338
|
+
sh: the spherical harmonic decomposition of the diffusion-weighted\
|
|
339
|
+
images.
|
|
340
|
+
mask: the mask containing the voxels from which to estimate the\
|
|
341
|
+
response function.
|
|
342
|
+
directions: a 4D image containing the direction vectors along which to\
|
|
343
|
+
estimate the response function.
|
|
344
|
+
response: the output axially-symmetric spherical harmonic coefficients.
|
|
345
|
+
lmax: specify the maximum harmonic degree of the response function to\
|
|
346
|
+
estimate.
|
|
347
|
+
dump: dump the m=0 SH coefficients from all voxels in the mask to the\
|
|
348
|
+
output file, rather than their mean.
|
|
349
|
+
info: display information messages.
|
|
350
|
+
quiet: do not display information messages or progress status;\
|
|
351
|
+
alternatively, this can be achieved by setting the MRTRIX_QUIET\
|
|
352
|
+
environment variable to a non-empty string.
|
|
353
|
+
debug: display debugging messages.
|
|
354
|
+
force: force overwrite of output files (caution: using the same file as\
|
|
355
|
+
input and output might cause unexpected behaviour).
|
|
356
|
+
nthreads: use this number of threads in multi-threaded applications\
|
|
357
|
+
(set to 0 to disable multi-threading).
|
|
358
|
+
config: temporarily set the value of an MRtrix config file entry.
|
|
359
|
+
help_: display this information page and exit.
|
|
360
|
+
version: display version information and exit.
|
|
361
|
+
runner: Command runner.
|
|
362
|
+
Returns:
|
|
363
|
+
NamedTuple of outputs (described in `Sh2responseOutputs`).
|
|
364
|
+
"""
|
|
365
|
+
runner = runner or get_global_runner()
|
|
366
|
+
execution = runner.start_execution(SH2RESPONSE_METADATA)
|
|
367
|
+
params = sh2response_params(
|
|
368
|
+
lmax=lmax,
|
|
369
|
+
dump=dump,
|
|
370
|
+
info=info,
|
|
371
|
+
quiet=quiet,
|
|
372
|
+
debug=debug,
|
|
373
|
+
force=force,
|
|
374
|
+
nthreads=nthreads,
|
|
375
|
+
config=config,
|
|
376
|
+
help_=help_,
|
|
377
|
+
version=version,
|
|
378
|
+
sh=sh,
|
|
379
|
+
mask=mask,
|
|
380
|
+
directions=directions,
|
|
381
|
+
response=response,
|
|
382
|
+
)
|
|
383
|
+
return sh2response_execute(params, execution)
|
|
384
|
+
|
|
385
|
+
|
|
386
|
+
__all__ = [
|
|
387
|
+
"SH2RESPONSE_METADATA",
|
|
388
|
+
"Sh2responseConfigParameters",
|
|
389
|
+
"Sh2responseOutputs",
|
|
390
|
+
"Sh2responseParameters",
|
|
391
|
+
"sh2response",
|
|
392
|
+
"sh2response_config_params",
|
|
393
|
+
"sh2response_params",
|
|
394
|
+
]
|