yuta-hi / pycuda_drr

Digitally recconstructed radiograph
MIT License
22 stars 3 forks source link

No module named 'chainer_bcnn' #1

Closed gokceay closed 4 years ago

gokceay commented 4 years ago

Hi, I tried rendering.py for a ct image (converted to mhd) and got an error like: T_Nx4x4.shape: (1, 4, 4) Result image shape: (1280, 1280, 3) Traceback (most recent call last): File "rendering.py", line 118, in main() File "rendering.py", line 60, in main from chainer_bcnn.data import save_image ModuleNotFoundError: No module named 'chainer_bcnn'

Could you help me regarding this issue? Thanks

yuta-hi commented 4 years ago

Hi gokceay, I created an alternative function. Thank you.

gokceay commented 4 years ago

Hi Yuta, I am the one who is thankful, I was struggling with proper drr-xray production for one week and come across your code. Your drr results are awesome. I have one more question about drr production, the bone structures are perfect but I would like to see the skin as well, which parameter should I adjust to make the skin more visible in the results? arigato gozaimasu

gokceay commented 4 years ago

and one more question, How can I use CUDA property? Thanks in advance

yuta-hi commented 4 years ago

If you want to include soft tissue in your projection, try changing line 38 of the example as follows. Before: volume = pydrr.utils.HU2Myu(volume - 1000, 0. 2683) After: volume = pydrr.utils.HU2Myu(volume - 50, 0.2683)

yuta-hi commented 4 years ago

Does CUDA property mean device property? If so, you can find the information below.

import pydrr
import pydrr.autoinit
from pydrr.autoinit import pycuda
from pycuda import driver

device = pycuda.autoinit.device

for key, val in driver.device_attribute.names.items():
    print(key, device.get_attribute(val))

# NOTE: Also available
# device.get_attributes()
gokceay commented 4 years ago

Thanks a lot Yuta, I will try what you mentioned above ^_^ I really appreciate it