Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated CUDA and PyTorch versions #6

Open
ahariri13 opened this issue Jun 26, 2020 · 8 comments
Open

Updated CUDA and PyTorch versions #6

ahariri13 opened this issue Jun 26, 2020 · 8 comments

Comments

@ahariri13
Copy link

Hello, I am interested in this code but I have CUDA 10.1 version and PyTorch 1.5. Is there a way to modify the setup accordingly ?

Thank you in advance

@cihanongun
Copy link

I've made a pull request but in the meantime, just change the deprecated AT_CHECK with TORCH_CHECK in the following lines and follow the installation steps.

#define CHECK_CUDA(x) AT_CHECK(x.type().is_cuda(), #x " must be a CUDA tensor")
#define CHECK_CONTIGUOUS(x) AT_CHECK(x.is_contiguous(), #x " must be contiguous")

@asurada404
Copy link

Thanks a lot! This work for me.

@QhelDIV
Copy link

QhelDIV commented Jan 4, 2021

This works for me!(Pytorch 1.7 CUDA 10.2) Thanks a lot.

@XinYu-Andy
Copy link

Hi, does anyone know how to compile with CUDA 11.3 PyTorch 1.11?

@bluestyle97
Copy link

@XinYu-Andy I build PyTorchEMD successfully with PyTorch 1.11 and CUDA 11.0. I modified cuda/emd_kernel.cu as follows:

  1. Comment #include <THC/THC.h>
  2. Replace all THCudaCheck with C10_CUDA_CHECK

I hope this can be helpful!

@XinYu-Andy
Copy link

2. C10_CUDA_CHECK

Thank you very much! It works for me!

@Alhambra-H
Copy link

i successfully build PyTorchEMD,but when i run test_emd_loss.py, there comes another problem:Segmentation fault (core dumped)。does anyone know how to solve this?

@XinYu-Andy I build PyTorchEMD successfully with PyTorch 1.11 and CUDA 11.0. I modified cuda/emd_kernel.cu as follows:

  1. Comment #include <THC/THC.h>
  2. Replace all THCudaCheck with C10_CUDA_CHECK

I hope this can be helpful!

i successfully build PyTorchEMD,but when i run test_emd_loss.py, there comes another problem:Segmentation fault (core dumped)。does anyone know how to solve this?

@zhouzheyuan
Copy link

Thanks to @cihanongun and @bluestyle97, I build successfully with torch 2.0.0 and CUDA 11.7 by modified cuda/emd_kernel.cu as:

  1. Comment #include <THC/THC.h>
  2. Repalce all AT_CHECK with TORCH_CHECK
  3. Replace all THCudaCheck with C10_CUDA_CHECK
  4. Replace all CHECK_EQ with TORCH_CHECK_EQ

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

No branches or pull requests

8 participants