Resample DWI Volume

I am using Resample Scalar/Vector/DWI Volume module to simply upsample the image. The Apply button runs the process of resampling with the status “Completed” after about 25 sec. However, the output resampled volume is not being written/displayed.

I am using nrrd input and Manual Output Parameters.

What am I missing?

Thank you!

What do you see in the application log?

Does it make a difference if you enable “Prefer executable CLI” in application settings / modules?

“Prefer executable CLI” is ON.

The message is “Unsupported number of components (only 1 allowed): 168”

In Slicer is the input volume loaded as a diffusion volume? (check in the Volumes module if you can scroll through the gradient images). Otherwise maybe you can share a dataset with steps for reproducing.

Yes, I can see all components. How do I share?

You can put it on google drive, dropbox, or similar and share the link here.

Here is the link.

Thanks for reporting this and providing the data to replicate it @Nadya_Shusharina.

It appears the problem is that the CLI read-back mechanism is not detecting the resampled data as DWI and so it fails to load. As I recall this used to work but I haven’t seen it used in a while.

Found CommandLine Module, target is  /Applications/
ModuleType: CommandLineModule
Resample Scalar/Vector/DWI Volume command line: 

/Applications/ --transformationFile /private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLLinearTransformNodeE.h5 --hfieldtype h-Field --interpolation linear --transform_order output-to-input --image_center input --spacing 0,0,0 --size 0,0,0 --direction_matrix 0,0,0,0,0,0,0,0,0 --number_of_thread 0 --default_pixel_value 0 --window_function c --spline_order 3 --transform_matrix 1,0,0,0,1,0,0,0,1,0,0,0 --transform a /private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLDiffusionWeightedVolumeNodeB.nrrd /private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLScalarVolumeNodeB.nrrd 

Resample Scalar/Vector/DWI Volume completed without errors

UpdateFromFile: Unsupported number of components (only 1 allowed): 168

ReadDataInternal: Cannot read file as a volume of type Volume[fullName = /private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLScalarVolumeNodeB.nrrd]
	Number of files listed in the node = 0.
	File reader says it was able to read 1 files.
	File reader used the archetype file name of /private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLScalarVolumeNodeB.nrrd [reader 0th file name = /private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLScalarVolumeNodeB.nrrd]

vtkMRMLStorageNode::ReadData: Failed to read node Output Volume (vtkMRMLScalarVolumeNode1) from filename='/private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLScalarVolumeNodeB.nrrd'

Input port 0 of algorithm vtkImageMapToWindowLevelColors(0x7ff9223662f0) has 0 connections but is not optional.

This is a bug so I reported an issue to track it.

As a workaround you can enable the “Preserve CLII module data files” flag in the Application Settings → Developer panel and then open the result of the CLI using the regular Add Data dialog. The output is the last filename on the CLI command line (/private/var/folders/0y/yzydqvk90f9_kx1sqd3k110h0000gn/T/Slicer-pieper/GJHED_vtkMRMLScalarVolumeNodeB.nrrd
in this case),

Thank you, Steve. I recall some other cases in DMRI where the output volume does not load if I specify “Create new Volume as …”.

Ah, yes, thanks for the reminder. I really haven’t used this in a long time.

You do need to select the correct node type for the output in order for it to load correctly. This is different from the Add Data path which tries many different types to figure out what type of file is being read back.

So in this case if I create a DiffusionWeightedVolume the result loads back correctly.

This is an odd usability issue, but maybe not technically a bug given the design of the CLI intertace. Probably a small scripted module on top of the CLI could automated some of these data dependencies.