Closed smeisler closed 1 year ago
Looking good so far
import pydra
from nipreps.synthstrip.wrappers.pydra import _SynthStripInputSpec
SynthStrip = pydra.ShellCommandTask(
name='SynthStrip',
executable="nipreps-synthstrip",
input_spec = _SynthStripInputSpec
)
SynthStrip.inputs.in_file='/Users/smeisler/Downloads/test_image.nii.gz'
Then SynthStrip.cmdline
returns:
'nipreps-synthstrip -i /Users/smeisler/Downloads//test_image.nii.gz -o /private/var/folders/zt/y4402h6d1j7bz5ycz4q1q30m0000gn/T/tmpx7pnx5m3/ShellCommandTask_edfdd5a0937e072856c67606fc8db5ca467f15fd3cf6d78831409a2bc4599d32/test_image_desc-brain.nii.gz -m /private/var/folders/zt/y4402h6d1j7bz5ycz4q1q30m0000gn/T/tmpx7pnx5m3/ShellCommandTask_edfdd5a0937e072856c67606fc8db5ca467f15fd3cf6d78831409a2bc4599d32/test_image_desc-brain_mask.nii.gz -b 1 --model /Applications/freesurfer/models/synthstrip.1.pt
Ok, will do, also making one quick change to simplify importing the task!
Okay, now should be ready!
Addresses https://github.com/orgs/nipreps/projects/8/views/1?pane=issue&itemId=26317826
Adds Pydra implementation of SynthStrip