niwrap-freesurfer 0.5.1__py3-none-any.whl → 0.5.2__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-freesurfer might be problematic. Click here for more details.

Files changed (153) hide show
  1. niwrap_freesurfer/freesurfer/__init__.py +0 -11
  2. niwrap_freesurfer/freesurfer/annot2std.py +32 -1
  3. niwrap_freesurfer/freesurfer/aparc2feat.py +19 -1
  4. niwrap_freesurfer/freesurfer/bbregister.py +143 -4
  5. niwrap_freesurfer/freesurfer/bmedits2surf.py +2 -2
  6. niwrap_freesurfer/freesurfer/compute_interrater_variability_csh.py +20 -2
  7. niwrap_freesurfer/freesurfer/compute_label_volumes_csh.py +17 -2
  8. niwrap_freesurfer/freesurfer/conf2hires.py +59 -1
  9. niwrap_freesurfer/freesurfer/connected_components.py +34 -2
  10. niwrap_freesurfer/freesurfer/dcmdir_info_mgh.py +3 -2
  11. niwrap_freesurfer/freesurfer/dcmdjpeg_fs.py +2 -2
  12. niwrap_freesurfer/freesurfer/dcmdrle_fs.py +2 -2
  13. niwrap_freesurfer/freesurfer/dicom_rename.py +21 -2
  14. niwrap_freesurfer/freesurfer/dmri_bset.py +14 -2
  15. niwrap_freesurfer/freesurfer/dmri_forrest.py +10 -1
  16. niwrap_freesurfer/freesurfer/dmri_mergepaths.py +2 -2
  17. niwrap_freesurfer/freesurfer/dmri_pathstats.py +2 -2
  18. niwrap_freesurfer/freesurfer/dmri_stats_ac.py +1 -3
  19. niwrap_freesurfer/freesurfer/exvivo_hemi_proc.py +10 -1
  20. niwrap_freesurfer/freesurfer/fiducials_calibration.py +15 -1
  21. niwrap_freesurfer/freesurfer/fiducials_correction.py +10 -3
  22. niwrap_freesurfer/freesurfer/fix_subject_corrected_rh.py +3 -2
  23. niwrap_freesurfer/freesurfer/fix_subject_rh.py +3 -2
  24. niwrap_freesurfer/freesurfer/fs_check_version.py +19 -1
  25. niwrap_freesurfer/freesurfer/fs_spmreg_glnxa64.py +19 -4
  26. niwrap_freesurfer/freesurfer/fs_temp_file.py +36 -1
  27. niwrap_freesurfer/freesurfer/fs_update.py +19 -1
  28. niwrap_freesurfer/freesurfer/fsl_sub_mgh.py +1 -2
  29. niwrap_freesurfer/freesurfer/fsr_import.py +55 -5
  30. niwrap_freesurfer/freesurfer/fvcompare.py +10 -1
  31. niwrap_freesurfer/freesurfer/gca_apply.py +3 -2
  32. niwrap_freesurfer/freesurfer/gdcmconv_fs.py +2 -2
  33. niwrap_freesurfer/freesurfer/get_label_thickness.py +1 -2
  34. niwrap_freesurfer/freesurfer/groupstats.py +97 -1
  35. niwrap_freesurfer/freesurfer/groupstatsdiff.py +4 -4
  36. niwrap_freesurfer/freesurfer/hiam_make_surfaces.py +1 -2
  37. niwrap_freesurfer/freesurfer/histo_synthesize.py +1 -2
  38. niwrap_freesurfer/freesurfer/inflate_subject_lh.py +3 -2
  39. niwrap_freesurfer/freesurfer/inflate_subject_new_lh.py +3 -3
  40. niwrap_freesurfer/freesurfer/inflate_subject_new_rh.py +3 -2
  41. niwrap_freesurfer/freesurfer/inflate_subject_rh.py +3 -2
  42. niwrap_freesurfer/freesurfer/inflate_subject_sc.py +28 -3
  43. niwrap_freesurfer/freesurfer/irepifitvol_glnx64.py +2 -2
  44. niwrap_freesurfer/freesurfer/is_surface.py +3 -2
  45. niwrap_freesurfer/freesurfer/isolate_labels_csh.py +17 -2
  46. niwrap_freesurfer/freesurfer/label_subject_flash.py +2 -2
  47. niwrap_freesurfer/freesurfer/label_subject_mixed.py +2 -2
  48. niwrap_freesurfer/freesurfer/listsubj.py +82 -2
  49. niwrap_freesurfer/freesurfer/long_stats_combine.py +1 -2
  50. niwrap_freesurfer/freesurfer/long_stats_tps.py +7 -7
  51. niwrap_freesurfer/freesurfer/long_submit_jobs.py +1 -5
  52. niwrap_freesurfer/freesurfer/longmc.py +10 -1
  53. niwrap_freesurfer/freesurfer/lta_convert.py +157 -1
  54. niwrap_freesurfer/freesurfer/make_average_volume.py +19 -1
  55. niwrap_freesurfer/freesurfer/make_folding_atlas.py +10 -1
  56. niwrap_freesurfer/freesurfer/map_all_labels_lh.py +11 -3
  57. niwrap_freesurfer/freesurfer/map_central_sulcus.py +2 -2
  58. niwrap_freesurfer/freesurfer/merge_stats_tables.py +58 -35
  59. niwrap_freesurfer/freesurfer/mideface.py +121 -14
  60. niwrap_freesurfer/freesurfer/mni152reg.py +2 -2
  61. niwrap_freesurfer/freesurfer/morph_only_subject_lh.py +3 -2
  62. niwrap_freesurfer/freesurfer/morph_only_subject_rh.py +3 -2
  63. niwrap_freesurfer/freesurfer/morph_rgb_lh.py +3 -2
  64. niwrap_freesurfer/freesurfer/morph_rgb_rh.py +3 -2
  65. niwrap_freesurfer/freesurfer/morph_subject_lh.py +3 -2
  66. niwrap_freesurfer/freesurfer/morph_subject_rh.py +3 -2
  67. niwrap_freesurfer/freesurfer/morph_tables_lh.py +3 -2
  68. niwrap_freesurfer/freesurfer/morph_tables_rh.py +3 -2
  69. niwrap_freesurfer/freesurfer/mri_aparc2aseg.py +10 -1
  70. niwrap_freesurfer/freesurfer/mri_apply_bias.py +1 -2
  71. niwrap_freesurfer/freesurfer/mri_average.py +10 -1
  72. niwrap_freesurfer/freesurfer/mri_brain_volume.py +23 -2
  73. niwrap_freesurfer/freesurfer/mri_ca_label.py +603 -2
  74. niwrap_freesurfer/freesurfer/mri_ca_train.py +10 -1
  75. niwrap_freesurfer/freesurfer/mri_convert.py +188 -2
  76. niwrap_freesurfer/freesurfer/mri_fuse_segmentations.py +10 -3
  77. niwrap_freesurfer/freesurfer/mri_gcab_train.py +15 -1
  78. niwrap_freesurfer/freesurfer/mri_gdfglm.py +13 -1
  79. niwrap_freesurfer/freesurfer/mri_gtmpvc.py +19 -1
  80. niwrap_freesurfer/freesurfer/mri_hausdorff_dist.py +1 -2
  81. niwrap_freesurfer/freesurfer/mri_head.py +19 -1
  82. niwrap_freesurfer/freesurfer/mri_jacobian.py +10 -1
  83. niwrap_freesurfer/freesurfer/mri_nl_align.py +27 -1
  84. niwrap_freesurfer/freesurfer/mri_relabel_nonwm_hypos.py +3 -3
  85. niwrap_freesurfer/freesurfer/mri_reorient_lr_csh.py +2 -2
  86. niwrap_freesurfer/freesurfer/mri_seg_diff.py +14 -1
  87. niwrap_freesurfer/freesurfer/mri_twoclass.py +1 -2
  88. niwrap_freesurfer/freesurfer/mri_validate_skull_stripped.py +2 -2
  89. niwrap_freesurfer/freesurfer/mri_warp_convert.py +131 -1
  90. niwrap_freesurfer/freesurfer/mri_z2p.py +37 -1
  91. niwrap_freesurfer/freesurfer/mris_add_template.py +11 -1
  92. niwrap_freesurfer/freesurfer/mris_apply_reg.py +1 -2
  93. niwrap_freesurfer/freesurfer/mris_curvature_stats.py +419 -7
  94. niwrap_freesurfer/freesurfer/mris_diff.py +255 -1
  95. niwrap_freesurfer/freesurfer/mris_distance_map.py +1 -2
  96. niwrap_freesurfer/freesurfer/mris_errors.py +1 -2
  97. niwrap_freesurfer/freesurfer/mris_info.py +45 -46
  98. niwrap_freesurfer/freesurfer/mris_label_calc.py +14 -1
  99. niwrap_freesurfer/freesurfer/mris_map_cuts.py +1 -2
  100. niwrap_freesurfer/freesurfer/mris_nudge.py +1 -2
  101. niwrap_freesurfer/freesurfer/mris_place_surface.py +1 -2
  102. niwrap_freesurfer/freesurfer/mris_preproc.py +16 -2
  103. niwrap_freesurfer/freesurfer/mris_spherical_average.py +93 -8
  104. niwrap_freesurfer/freesurfer/mris_thickness_diff.py +1 -5
  105. niwrap_freesurfer/freesurfer/mris_volmask_vtk.py +2 -2
  106. niwrap_freesurfer/freesurfer/pctsurfcon.py +2 -2
  107. niwrap_freesurfer/freesurfer/plot_structure_stats_tcl.py +2 -2
  108. niwrap_freesurfer/freesurfer/post_recon_all.py +39 -2
  109. niwrap_freesurfer/freesurfer/predict_v1_sh.py +11 -2
  110. niwrap_freesurfer/freesurfer/print_unique_labels_csh.py +34 -3
  111. niwrap_freesurfer/freesurfer/rbbr.py +37 -1
  112. niwrap_freesurfer/freesurfer/rca_base_init.py +3 -2
  113. niwrap_freesurfer/freesurfer/rca_config.py +3 -2
  114. niwrap_freesurfer/freesurfer/rca_config2csh.py +3 -2
  115. niwrap_freesurfer/freesurfer/recon_all.py +75 -1
  116. niwrap_freesurfer/freesurfer/register_elderly_subject.py +2 -2
  117. niwrap_freesurfer/freesurfer/reinflate_subject_lh.py +3 -2
  118. niwrap_freesurfer/freesurfer/reinflate_subject_rh.py +3 -2
  119. niwrap_freesurfer/freesurfer/renormalize_subject_keep_editting.py +13 -1
  120. niwrap_freesurfer/freesurfer/rtview.py +34 -1
  121. niwrap_freesurfer/freesurfer/run_qdec_glm.py +3 -2
  122. niwrap_freesurfer/freesurfer/samseg.py +14 -1
  123. niwrap_freesurfer/freesurfer/samseg_long.py +17 -8
  124. niwrap_freesurfer/freesurfer/samsegmesh2surf.py +5 -7
  125. niwrap_freesurfer/freesurfer/seg2filled.py +4 -4
  126. niwrap_freesurfer/freesurfer/segment_subject.py +2 -2
  127. niwrap_freesurfer/freesurfer/segment_subject_old_skull_strip.py +4 -4
  128. niwrap_freesurfer/freesurfer/segment_subject_sc.py +4 -4
  129. niwrap_freesurfer/freesurfer/segment_subject_t2_auto_estimate_alveus_ml.py +11 -1
  130. niwrap_freesurfer/freesurfer/segpons.py +2 -2
  131. niwrap_freesurfer/freesurfer/sphere_subject_lh.py +3 -2
  132. niwrap_freesurfer/freesurfer/sphere_subject_rh.py +3 -2
  133. niwrap_freesurfer/freesurfer/talairach.py +4 -4
  134. niwrap_freesurfer/freesurfer/trac_all.py +283 -1
  135. niwrap_freesurfer/freesurfer/train_gcs_atlas.py +19 -1
  136. niwrap_freesurfer/freesurfer/update_needed.py +13 -2
  137. niwrap_freesurfer/freesurfer/vertexvol.py +19 -1
  138. niwrap_freesurfer/freesurfer/vol2subfield.py +72 -1
  139. niwrap_freesurfer/freesurfer/wmsaseg.py +2 -2
  140. {niwrap_freesurfer-0.5.1.dist-info → niwrap_freesurfer-0.5.2.dist-info}/METADATA +1 -1
  141. {niwrap_freesurfer-0.5.1.dist-info → niwrap_freesurfer-0.5.2.dist-info}/RECORD +142 -153
  142. niwrap_freesurfer/freesurfer/bet_fsl.py +0 -441
  143. niwrap_freesurfer/freesurfer/epidewarp_fsl.py +0 -439
  144. niwrap_freesurfer/freesurfer/flirt_fsl.py +0 -604
  145. niwrap_freesurfer/freesurfer/fscalc_fsl.py +0 -196
  146. niwrap_freesurfer/freesurfer/fsfirst_fsl.py +0 -166
  147. niwrap_freesurfer/freesurfer/fslmaths_fsl.py +0 -196
  148. niwrap_freesurfer/freesurfer/fslorient_fsl.py +0 -207
  149. niwrap_freesurfer/freesurfer/fslswapdim_fsl.py +0 -216
  150. niwrap_freesurfer/freesurfer/fspython.py +0 -175
  151. niwrap_freesurfer/freesurfer/mri_motion_correct_fsl.py +0 -185
  152. niwrap_freesurfer/freesurfer/slicetimer_fsl.py +0 -291
  153. {niwrap_freesurfer-0.5.1.dist-info → niwrap_freesurfer-0.5.2.dist-info}/WHEEL +0 -0
@@ -1,207 +0,0 @@
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
- FSLORIENT_FSL_METADATA = Metadata(
9
- id="91c87d301655f1a487272843a72c1efbca6dd79a.boutiques",
10
- name="fslorient.fsl",
11
- package="freesurfer",
12
- container_image_tag="freesurfer/freesurfer:7.4.1",
13
- )
14
-
15
-
16
- FslorientFslParameters = typing.TypedDict('FslorientFslParameters', {
17
- "__STYX_TYPE__": typing.Literal["fslorient.fsl"],
18
- "swap_orient": bool,
19
- "filename": InputPathType,
20
- "set_qform": typing.NotRequired[list[float] | None],
21
- "set_qform_code": typing.NotRequired[str | None],
22
- })
23
-
24
-
25
- def dyn_cargs(
26
- t: str,
27
- ) -> typing.Any:
28
- """
29
- Get build cargs function by command type.
30
-
31
- Args:
32
- t: Command type.
33
- Returns:
34
- Build cargs function.
35
- """
36
- return {
37
- "fslorient.fsl": fslorient_fsl_cargs,
38
- }.get(t)
39
-
40
-
41
- def dyn_outputs(
42
- t: str,
43
- ) -> typing.Any:
44
- """
45
- Get build outputs function by command type.
46
-
47
- Args:
48
- t: Command type.
49
- Returns:
50
- Build outputs function.
51
- """
52
- return {
53
- }.get(t)
54
-
55
-
56
- class FslorientFslOutputs(typing.NamedTuple):
57
- """
58
- Output object returned when calling `fslorient_fsl(...)`.
59
- """
60
- root: OutputPathType
61
- """Output root folder. This is the root folder for all outputs."""
62
-
63
-
64
- def fslorient_fsl_params(
65
- filename: InputPathType,
66
- swap_orient: bool = False,
67
- set_qform: list[float] | None = None,
68
- set_qform_code: str | None = None,
69
- ) -> FslorientFslParameters:
70
- """
71
- Build parameters.
72
-
73
- Args:
74
- filename: Input image filename.
75
- swap_orient: Swaps FSL radiological and FSL neurological.
76
- set_qform: Sets the 16 elements of the qform matrix.
77
- set_qform_code: Sets qform integer code.
78
- Returns:
79
- Parameter dictionary
80
- """
81
- params = {
82
- "__STYXTYPE__": "fslorient.fsl",
83
- "swap_orient": swap_orient,
84
- "filename": filename,
85
- }
86
- if set_qform is not None:
87
- params["set_qform"] = set_qform
88
- if set_qform_code is not None:
89
- params["set_qform_code"] = set_qform_code
90
- return params
91
-
92
-
93
- def fslorient_fsl_cargs(
94
- params: FslorientFslParameters,
95
- execution: Execution,
96
- ) -> list[str]:
97
- """
98
- Build command-line arguments from parameters.
99
-
100
- Args:
101
- params: The parameters.
102
- execution: The execution object for resolving input paths.
103
- Returns:
104
- Command-line arguments.
105
- """
106
- cargs = []
107
- cargs.append("fslorient")
108
- if params.get("swap_orient"):
109
- cargs.append("-swaporient")
110
- cargs.append(execution.input_file(params.get("filename")))
111
- if params.get("set_qform") is not None:
112
- cargs.extend([
113
- "-setqform",
114
- *map(str, params.get("set_qform"))
115
- ])
116
- if params.get("set_qform_code") is not None:
117
- cargs.extend([
118
- "-setqformcode",
119
- params.get("set_qform_code")
120
- ])
121
- return cargs
122
-
123
-
124
- def fslorient_fsl_outputs(
125
- params: FslorientFslParameters,
126
- execution: Execution,
127
- ) -> FslorientFslOutputs:
128
- """
129
- Build outputs object containing output file paths and possibly stdout/stderr.
130
-
131
- Args:
132
- params: The parameters.
133
- execution: The execution object for resolving input paths.
134
- Returns:
135
- Outputs object.
136
- """
137
- ret = FslorientFslOutputs(
138
- root=execution.output_file("."),
139
- )
140
- return ret
141
-
142
-
143
- def fslorient_fsl_execute(
144
- params: FslorientFslParameters,
145
- execution: Execution,
146
- ) -> FslorientFslOutputs:
147
- """
148
- A tool for managing the orientations and orientation headers of NIFTI images.
149
-
150
- Author: FreeSurfer Developers
151
-
152
- URL: https://github.com/freesurfer/freesurfer
153
-
154
- Args:
155
- params: The parameters.
156
- execution: The execution object.
157
- Returns:
158
- NamedTuple of outputs (described in `FslorientFslOutputs`).
159
- """
160
- params = execution.params(params)
161
- cargs = fslorient_fsl_cargs(params, execution)
162
- ret = fslorient_fsl_outputs(params, execution)
163
- execution.run(cargs)
164
- return ret
165
-
166
-
167
- def fslorient_fsl(
168
- filename: InputPathType,
169
- swap_orient: bool = False,
170
- set_qform: list[float] | None = None,
171
- set_qform_code: str | None = None,
172
- runner: Runner | None = None,
173
- ) -> FslorientFslOutputs:
174
- """
175
- A tool for managing the orientations and orientation headers of NIFTI images.
176
-
177
- Author: FreeSurfer Developers
178
-
179
- URL: https://github.com/freesurfer/freesurfer
180
-
181
- Args:
182
- filename: Input image filename.
183
- swap_orient: Swaps FSL radiological and FSL neurological.
184
- set_qform: Sets the 16 elements of the qform matrix.
185
- set_qform_code: Sets qform integer code.
186
- runner: Command runner.
187
- Returns:
188
- NamedTuple of outputs (described in `FslorientFslOutputs`).
189
- """
190
- runner = runner or get_global_runner()
191
- execution = runner.start_execution(FSLORIENT_FSL_METADATA)
192
- params = fslorient_fsl_params(
193
- swap_orient=swap_orient,
194
- filename=filename,
195
- set_qform=set_qform,
196
- set_qform_code=set_qform_code,
197
- )
198
- return fslorient_fsl_execute(params, execution)
199
-
200
-
201
- __all__ = [
202
- "FSLORIENT_FSL_METADATA",
203
- "FslorientFslOutputs",
204
- "FslorientFslParameters",
205
- "fslorient_fsl",
206
- "fslorient_fsl_params",
207
- ]
@@ -1,216 +0,0 @@
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
- FSLSWAPDIM_FSL_METADATA = Metadata(
9
- id="7302b08bc4d86f9914f7a8203cbaf36cc9515b0c.boutiques",
10
- name="fslswapdim.fsl",
11
- package="freesurfer",
12
- container_image_tag="freesurfer/freesurfer:7.4.1",
13
- )
14
-
15
-
16
- FslswapdimFslParameters = typing.TypedDict('FslswapdimFslParameters', {
17
- "__STYX_TYPE__": typing.Literal["fslswapdim.fsl"],
18
- "input_file": InputPathType,
19
- "axis_a": str,
20
- "axis_b": str,
21
- "axis_c": str,
22
- "output_file": typing.NotRequired[str | None],
23
- })
24
-
25
-
26
- def dyn_cargs(
27
- t: str,
28
- ) -> typing.Any:
29
- """
30
- Get build cargs function by command type.
31
-
32
- Args:
33
- t: Command type.
34
- Returns:
35
- Build cargs function.
36
- """
37
- return {
38
- "fslswapdim.fsl": fslswapdim_fsl_cargs,
39
- }.get(t)
40
-
41
-
42
- def dyn_outputs(
43
- t: str,
44
- ) -> typing.Any:
45
- """
46
- Get build outputs function by command type.
47
-
48
- Args:
49
- t: Command type.
50
- Returns:
51
- Build outputs function.
52
- """
53
- return {
54
- "fslswapdim.fsl": fslswapdim_fsl_outputs,
55
- }.get(t)
56
-
57
-
58
- class FslswapdimFslOutputs(typing.NamedTuple):
59
- """
60
- Output object returned when calling `fslswapdim_fsl(...)`.
61
- """
62
- root: OutputPathType
63
- """Output root folder. This is the root folder for all outputs."""
64
- output_image: OutputPathType | None
65
- """Output image with swapped dimensions"""
66
-
67
-
68
- def fslswapdim_fsl_params(
69
- input_file: InputPathType,
70
- axis_a: str,
71
- axis_b: str,
72
- axis_c: str,
73
- output_file: str | None = None,
74
- ) -> FslswapdimFslParameters:
75
- """
76
- Build parameters.
77
-
78
- Args:
79
- input_file: Input image file.
80
- axis_a: New X-axis in terms of the old axes; can be one of -x, x, y,\
81
- -y, z, -z or RL, LR, AP, PA, SI, IS.
82
- axis_b: New Y-axis in terms of the old axes; can be one of -x, x, y,\
83
- -y, z, -z or RL, LR, AP, PA, SI, IS.
84
- axis_c: New Z-axis in terms of the old axes; can be one of -x, x, y,\
85
- -y, z, -z or RL, LR, AP, PA, SI, IS.
86
- output_file: Output image file.
87
- Returns:
88
- Parameter dictionary
89
- """
90
- params = {
91
- "__STYXTYPE__": "fslswapdim.fsl",
92
- "input_file": input_file,
93
- "axis_a": axis_a,
94
- "axis_b": axis_b,
95
- "axis_c": axis_c,
96
- }
97
- if output_file is not None:
98
- params["output_file"] = output_file
99
- return params
100
-
101
-
102
- def fslswapdim_fsl_cargs(
103
- params: FslswapdimFslParameters,
104
- execution: Execution,
105
- ) -> list[str]:
106
- """
107
- Build command-line arguments from parameters.
108
-
109
- Args:
110
- params: The parameters.
111
- execution: The execution object for resolving input paths.
112
- Returns:
113
- Command-line arguments.
114
- """
115
- cargs = []
116
- cargs.append("fslswapdim")
117
- cargs.append(execution.input_file(params.get("input_file")))
118
- cargs.append(params.get("axis_a"))
119
- cargs.append(params.get("axis_b"))
120
- cargs.append(params.get("axis_c"))
121
- if params.get("output_file") is not None:
122
- cargs.append(params.get("output_file"))
123
- return cargs
124
-
125
-
126
- def fslswapdim_fsl_outputs(
127
- params: FslswapdimFslParameters,
128
- execution: Execution,
129
- ) -> FslswapdimFslOutputs:
130
- """
131
- Build outputs object containing output file paths and possibly stdout/stderr.
132
-
133
- Args:
134
- params: The parameters.
135
- execution: The execution object for resolving input paths.
136
- Returns:
137
- Outputs object.
138
- """
139
- ret = FslswapdimFslOutputs(
140
- root=execution.output_file("."),
141
- output_image=execution.output_file(params.get("output_file")) if (params.get("output_file") is not None) else None,
142
- )
143
- return ret
144
-
145
-
146
- def fslswapdim_fsl_execute(
147
- params: FslswapdimFslParameters,
148
- execution: Execution,
149
- ) -> FslswapdimFslOutputs:
150
- """
151
- FSLSwapdim allows swapping and flipping of dimensions of an image.
152
-
153
- Author: FreeSurfer Developers
154
-
155
- URL: https://github.com/freesurfer/freesurfer
156
-
157
- Args:
158
- params: The parameters.
159
- execution: The execution object.
160
- Returns:
161
- NamedTuple of outputs (described in `FslswapdimFslOutputs`).
162
- """
163
- params = execution.params(params)
164
- cargs = fslswapdim_fsl_cargs(params, execution)
165
- ret = fslswapdim_fsl_outputs(params, execution)
166
- execution.run(cargs)
167
- return ret
168
-
169
-
170
- def fslswapdim_fsl(
171
- input_file: InputPathType,
172
- axis_a: str,
173
- axis_b: str,
174
- axis_c: str,
175
- output_file: str | None = None,
176
- runner: Runner | None = None,
177
- ) -> FslswapdimFslOutputs:
178
- """
179
- FSLSwapdim allows swapping and flipping of dimensions of an image.
180
-
181
- Author: FreeSurfer Developers
182
-
183
- URL: https://github.com/freesurfer/freesurfer
184
-
185
- Args:
186
- input_file: Input image file.
187
- axis_a: New X-axis in terms of the old axes; can be one of -x, x, y,\
188
- -y, z, -z or RL, LR, AP, PA, SI, IS.
189
- axis_b: New Y-axis in terms of the old axes; can be one of -x, x, y,\
190
- -y, z, -z or RL, LR, AP, PA, SI, IS.
191
- axis_c: New Z-axis in terms of the old axes; can be one of -x, x, y,\
192
- -y, z, -z or RL, LR, AP, PA, SI, IS.
193
- output_file: Output image file.
194
- runner: Command runner.
195
- Returns:
196
- NamedTuple of outputs (described in `FslswapdimFslOutputs`).
197
- """
198
- runner = runner or get_global_runner()
199
- execution = runner.start_execution(FSLSWAPDIM_FSL_METADATA)
200
- params = fslswapdim_fsl_params(
201
- input_file=input_file,
202
- axis_a=axis_a,
203
- axis_b=axis_b,
204
- axis_c=axis_c,
205
- output_file=output_file,
206
- )
207
- return fslswapdim_fsl_execute(params, execution)
208
-
209
-
210
- __all__ = [
211
- "FSLSWAPDIM_FSL_METADATA",
212
- "FslswapdimFslOutputs",
213
- "FslswapdimFslParameters",
214
- "fslswapdim_fsl",
215
- "fslswapdim_fsl_params",
216
- ]
@@ -1,175 +0,0 @@
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
- FSPYTHON_METADATA = Metadata(
9
- id="2424f19a382cf96fd7771ce3d7180d81a8324105.boutiques",
10
- name="fspython",
11
- package="freesurfer",
12
- container_image_tag="freesurfer/freesurfer:7.4.1",
13
- )
14
-
15
-
16
- FspythonParameters = typing.TypedDict('FspythonParameters', {
17
- "__STYX_TYPE__": typing.Literal["fspython"],
18
- "args": typing.NotRequired[list[str] | None],
19
- })
20
-
21
-
22
- def dyn_cargs(
23
- t: str,
24
- ) -> typing.Any:
25
- """
26
- Get build cargs function by command type.
27
-
28
- Args:
29
- t: Command type.
30
- Returns:
31
- Build cargs function.
32
- """
33
- return {
34
- "fspython": fspython_cargs,
35
- }.get(t)
36
-
37
-
38
- def dyn_outputs(
39
- t: str,
40
- ) -> typing.Any:
41
- """
42
- Get build outputs function by command type.
43
-
44
- Args:
45
- t: Command type.
46
- Returns:
47
- Build outputs function.
48
- """
49
- return {
50
- }.get(t)
51
-
52
-
53
- class FspythonOutputs(typing.NamedTuple):
54
- """
55
- Output object returned when calling `fspython(...)`.
56
- """
57
- root: OutputPathType
58
- """Output root folder. This is the root folder for all outputs."""
59
-
60
-
61
- def fspython_params(
62
- args: list[str] | None = None,
63
- ) -> FspythonParameters:
64
- """
65
- Build parameters.
66
-
67
- Args:
68
- args: Arguments passed to the program.
69
- Returns:
70
- Parameter dictionary
71
- """
72
- params = {
73
- "__STYXTYPE__": "fspython",
74
- }
75
- if args is not None:
76
- params["args"] = args
77
- return params
78
-
79
-
80
- def fspython_cargs(
81
- params: FspythonParameters,
82
- execution: Execution,
83
- ) -> list[str]:
84
- """
85
- Build command-line arguments from parameters.
86
-
87
- Args:
88
- params: The parameters.
89
- execution: The execution object for resolving input paths.
90
- Returns:
91
- Command-line arguments.
92
- """
93
- cargs = []
94
- cargs.append("python3")
95
- cargs.append("[OPTION]")
96
- if params.get("args") is not None:
97
- cargs.extend(params.get("args"))
98
- return cargs
99
-
100
-
101
- def fspython_outputs(
102
- params: FspythonParameters,
103
- execution: Execution,
104
- ) -> FspythonOutputs:
105
- """
106
- Build outputs object containing output file paths and possibly stdout/stderr.
107
-
108
- Args:
109
- params: The parameters.
110
- execution: The execution object for resolving input paths.
111
- Returns:
112
- Outputs object.
113
- """
114
- ret = FspythonOutputs(
115
- root=execution.output_file("."),
116
- )
117
- return ret
118
-
119
-
120
- def fspython_execute(
121
- params: FspythonParameters,
122
- execution: Execution,
123
- ) -> FspythonOutputs:
124
- """
125
- Freesurfer's embedded Python interpreter.
126
-
127
- Author: FreeSurfer Developers
128
-
129
- URL: https://github.com/freesurfer/freesurfer
130
-
131
- Args:
132
- params: The parameters.
133
- execution: The execution object.
134
- Returns:
135
- NamedTuple of outputs (described in `FspythonOutputs`).
136
- """
137
- params = execution.params(params)
138
- cargs = fspython_cargs(params, execution)
139
- ret = fspython_outputs(params, execution)
140
- execution.run(cargs)
141
- return ret
142
-
143
-
144
- def fspython(
145
- args: list[str] | None = None,
146
- runner: Runner | None = None,
147
- ) -> FspythonOutputs:
148
- """
149
- Freesurfer's embedded Python interpreter.
150
-
151
- Author: FreeSurfer Developers
152
-
153
- URL: https://github.com/freesurfer/freesurfer
154
-
155
- Args:
156
- args: Arguments passed to the program.
157
- runner: Command runner.
158
- Returns:
159
- NamedTuple of outputs (described in `FspythonOutputs`).
160
- """
161
- runner = runner or get_global_runner()
162
- execution = runner.start_execution(FSPYTHON_METADATA)
163
- params = fspython_params(
164
- args=args,
165
- )
166
- return fspython_execute(params, execution)
167
-
168
-
169
- __all__ = [
170
- "FSPYTHON_METADATA",
171
- "FspythonOutputs",
172
- "FspythonParameters",
173
- "fspython",
174
- "fspython_params",
175
- ]