Open pogos-ed opened 11 months ago
I'm running into issues with the code/input data:
>>> in_file = "junction_im_thr.npz.zip"
>>> npzfile = np.load(in_file)
>>> junction_im_thr = npzfile['junction_im_thr']
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/ntustison/miniforge3/envs/antsx/lib/python3.8/site-packages/numpy/lib/npyio.py", line 251, in __getitem__
raise KeyError("%s is not a file in the archive" % key)
KeyError: 'junction_im_thr is not a file in the archive'
Sorry, I did mistake when I save the file. Unzip the new one, then:
in_file = "junction_im_thr.npy"
junction_im_thr = np.load(in_file)
Okay, it would appear that the underlying interface to ITK's convolution image filter is completely absent. So this doesn't work for any image of any dimensionality. This problematic code has been here for awhile so it's obvious that it's not used at all or it would've been discovered previously. You're welcome to work on a pull request to fix it or I might get around to it at some point.
Ok, thanks for clarification.
Running ants.convolve_image gives error:
_File ".../venv/lib/python3.9/site-packages/ants/utils/invariant_image_similarity.py", line 247, in convolve_image libfn = utils.get_lib_fn('convolveImageF%i' % image.dimension) File ".../venv/lib/python3.9/site-packages/ants/utils/process_args.py", line 29, in get_libfn return lib.dict[string] KeyError: 'convolveImageF3'
To reproduce the error use the code below and npz file I uploaded:
I used antspyx 0.3.8 and python 3.9. junction_im_thr.npz.zip