adler-j / learned_primal_dual

Learned Primal-Dual Reconstruction
https://arxiv.org/abs/1707.06474
98 stars 37 forks source link

odl issue #6

Open iamimage opened 5 years ago

iamimage commented 5 years ago

Hi Adler, it looks strange when I tried to run "learned_primal_dual/human/mayo_learned_primal_dual.py". Here is the error massage:

=================================================================== 20 size = 512 21 space = odl.uniform_discr([-128, -128], [128, 128], [size, size], ---> 22 dtype='float32', weighting='const') ..................... odl/space/weighting.py in init(self, const, impl, exponent) 591 """ 592 super(ConstWeighting, self).init(impl=impl, exponent=exponent) --> 593 self.__const = float(const) 594 595 if self.const <= 0:

ValueError: could not convert string to float: 'const'

I supposed I do not install the correct version of odl? when I "pip list | grep odl" odl 1.0.0.dev0 Did you update the code of this odl version? or how do I get the correct version of odl for runing?

adler-j commented 5 years ago

Thanks for reporting this. I've updated the repo with a new version where this should be fixed. Please report of you have any issues moving forward.

iamimage commented 5 years ago

Thanks for reporting this. I've updated the repo with a new version where this should be fixed. Please report of you have any issues moving forward.

Many thanks for the update. I try to run the code (mayo_learned_primal_dual.py) again but this time it fails to find the object 'odl.tomo.FanFlatGeometry'. I can not find the definition of 'FanFlatGeometry' in the 'odl 1.0.0.dev0' document either. Is it removed at some release somehow?

Another question that I am really interested: is the layer made from as_tensorflow_layer expected to perform on GPU during training? I run also the code ellipses/learned_primal_dual.py. It was successful, but the GPU-Util is zero most of the time, while 2%~5% for the rest. So I am wondering whether one or more parts of the job is not on GPU.

Mojzaar commented 3 years ago

Thanks for reporting this. I've updated the repo with a new version where this should be fixed. Please report of you have any issues moving forward.

Many thanks for the update. I try to run the code (mayo_learned_primal_dual.py) again but this time it fails to find the object 'odl.tomo.FanFlatGeometry'. I can not find the definition of 'FanFlatGeometry' in the 'odl 1.0.0.dev0' document either. Is it removed at some release somehow?

Another question that I am really interested: is the layer made from as_tensorflow_layer expected to perform on GPU during training? I run also the code ellipses/learned_primal_dual.py. It was successful, but the GPU-Util is zero most of the time, while 2%~5% for the rest. So I am wondering whether one or more parts of the job is not on GPU.

I have the same issue here for "odl.tomo.FanFlatGeometry". Did you find the solution?

99991 commented 1 year ago

It seems like this pull request renamed FanFlatGeometry to FanGeometry. As a solution, I installed an older version of odl where the pull request had not been merged yet.

pip install https://github.com/odlgroup/odl/archive/0a2dac2a68be3a06e72b4559f9026c206ccad46e.zip

Not sure if this is the correct version, but at least I get different errors now :slightly_smiling_face: