build Apex latest version failed with pytorch 1.4.0 due to missing ATen/cuda/DeviceUtils.cuh
While i try to build the apex for my new pytorch env, there is a error says:
csrc/layer_norm_cuda_kernel.cu:4:37: fatal error: ATen/cuda/DeviceUtils.cuh: No such file or directory
Actually, I could not find the file in the dir(Pytorch 1.4.0 just do not include this file), and I also found that the include dependency for DeviceUtils.cuh just added 1 month ago in the commit : cleanup missing THCDeviceUtils.cuh header
#include "ATen/ATen.h"
#include <THC/THCDeviceUtils.cuh> <----
#include "ATen/cuda/DeviceUtils.cuh" <----
#include <cuda.h>
#include <cuda_runtime.h>
So I can only build with an old-version-donwload-before apex to use (no bug in this time)
Is there something wrong with the recent commit?
PyTorch recently removed THCDeviceUtils.cuh recently thus we needed the change you mentioned.
PyTorch recently removed THCDeviceUtils.cuh recently thus we needed the change you mentioned.
Would you pls to provide a method to install apex on previous Pytorch?
picking up a commit before #1191 may work -- https://github.com/NVIDIA/apex/commits/master
picking up a commit before #1191 may work -- https://github.com/NVIDIA/apex/commits/master
maybe before #1171, commit between #1171 and #1191 doesn't work.
Have you solved the problem? I am faced with this problem now. @AndyYuan96
Hi, I just solved my problem by rolling back the version of apex like this:
git checkout f3a960f80244cf9e80558ab30f7f7e8cbf03c0a0
een #1171 and #1191 doesn't work.
yes, code changes commited at #1171, so, a little early version should work.
A usable version zip: Download old version apex
@crcrpar I think maybe apex should add something info into README.md file, which about these changes may affect some old version torch.
git checkout f3a960f80244cf9e80558ab30f7f7e8cbf03c0a0
git checkout -b f3a960f80244cf9e80558ab30f7f7e8cbf03c0a0