odlgroup / odl

Operator Discretization Library https://odlgroup.github.io/odl/
Mozilla Public License 2.0
375 stars 105 forks source link

TypeError: tam_danielson_window() got an unexpected keyword argument 'n_pi' #1593

Closed wangwei-cmd closed 3 years ago

wangwei-cmd commented 3 years ago

When I run the example code mayo_reconstruct.py in 'odl/odl/contrib/datasets/ct/examples', I get the error: TypeError: tam_danielson_window() got an unexpected keyword argument 'n_pi'. The version of my installed odl is 0.7.0. Pycharm hints me that the last parameter of tam_danielson_window() is 'n_half_rot'. Are the parameters 'n_half_rot' and 'n_pi' equivalent in different versions?

adler-j commented 3 years ago

It looks to me like you're using an old version of ODL, could you try installing from github

pip install https://github.com/odlgroup/odl/archive/master.zip
wangwei-cmd commented 3 years ago

Thank you very much. After I reinstall odl form github, the code raise another error: AttributeError: 'DiscretizedSpace' object has no attribute 'coord_vectors' when it runs the command "geometry, proj_data = mayo.load_projections(data_folder,indices=slice(20000, 28000))". When I install odl from conda, this command can be implemented correctly.

adler-j commented 3 years ago

So do you get that error when running the example as is? That does sound like a proper bug, perhaps @kohr-h knows more?

wangwei-cmd commented 3 years ago

Thank you very much, I can run the code correctly after I rereinstall the package from github.