yuweihao / KERN

Code for Knowledge-Embedded Routing Network for Scene Graph Generation (CVPR 2019)
MIT License
120 stars 35 forks source link

TypeError: initializer for ctype 'struct THCudaTensor *' must be a pointer to same type, not cdata 'struct THFloatTensor *' #18

Closed kunalpagarey closed 4 years ago

kunalpagarey commented 4 years ago

@yuweihao Do you have any idea why I am getting this error. I tried to run the code for custom data and made some changes to run on CPU only and getting this error in nms.py file in nms_apply() function.

Also please let me know the desired changes to run your code on CPU Only

Thank you.

kunalpagarey commented 4 years ago

@yuweihao I figured out this error it is because the NMS code is CUDA compatible. I am trying to run inference on CPU so could you please tell me which CPU implementation of NMS can be used. I looked into the CUDA implementation of NMS but can't figure out how it can be converted for CPU. Please help. Thank you.

yuweihao commented 4 years ago

Hi @kunalpagarey , I am so sorry that I don't have time to further investigate this repo and I don't have idea to solve this issue. The repo is based on the repo [neural-motifs] (https://github.com/rowanz/neural-motifs). Maybe you can submit an issue in that repo. I am sorry that I have no idea and I forget to reply this issue in time.

kunalpagarey commented 4 years ago

It's okay @yuweihao I have resolved the issue and also able to get inference on custom images on CPU. I'll close the issue. Thanks.