Skip to content
This repository has been archived by the owner on May 15, 2023. It is now read-only.

How to fix this error please #6

Open
YangZiz opened this issue Oct 19, 2022 · 7 comments
Open

How to fix this error please #6

YangZiz opened this issue Oct 19, 2022 · 7 comments

Comments

@YangZiz
Copy link

YangZiz commented Oct 19, 2022

I get the following error when I run the organize_folder_structure.py:
Traceback (most recent call last):
File "C:/Users/Desktop/code/3D-CycleGan-Pytorch-MedImaging-main/organize_folder_structure.py", line 157, in
reference_image = resample_sitk_image(reference_image, spacing=args.resolution, interpolator='linear')
File "C:\Users\Desktop\code\3D-CycleGan-Pytorch-MedImaging-main\utils\NiftiDataset.py", line 189, in resample_sitk_image
orig_pixelid)
TypeError: Execute() takes 2 positional arguments but 10 were given
and how should I fix it?
Thank you!

@zzx721838322
Copy link

和我一样

@Yueup
Copy link

Yueup commented Mar 28, 2023

我去simpleITK官方文档查了**Execute()**这个函数只有两个参数,但是NiftiDataset.py代码中给了九个参数。不知道如何解决

@zzx721838322
Copy link

我也不知道

@Yueup
Copy link

Yueup commented Apr 4, 2023

我也不知道

找到解决方法了,参见这个链接里面的resample_sitk_image函数

@zzx721838322
Copy link

谢谢,你的代码成功运行起来了吗

@Yueup
Copy link

Yueup commented Apr 4, 2023

嗯 仅就organize_folder_structure.py这个程序来说成功了,其他的还在调试

@zzx721838322
Copy link

好的 谢谢

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants