Using resampling cli in python script

I’m new with 3d slicer cli,

using this code , I get a volume with Image dimensions (0,0,0)
please tell me what’s wrong with this code

thank you!

Here is a complete working example of a resampling:

First check if it works as is, and then modify it step-by-step to make it do what you need.

thank u for your help

but if to set parameter regarding manual output para meter (spacing, size…) and transform_matrix manually, how should i set the parameter name?

this command don’t work

What is the error? What do you expect to happen and what happens instead?

Maybe the problem is that you do not to set the output image geometry (origin, spacing, axis directions).