Vision: [layers branch] ATen/cuda/CUDAContext.h doesn't seem to exist

Created on 11 Oct 2018  路  2Comments  路  Source: pytorch/vision

Hi there,

I'm looking to get Roi Pooling set up, using this commit: https://github.com/pytorch/vision/commit/ede93b290f844a4fdfd4a11fb870eec0c07b9497

When I try to install it, e.g. by running pip install git+git://github.com/pytorch/vision.git@ede93b290f844a4fdfd4a11fb870eec0c07b9497 I get the following error:

/tmp/pip-req-build-g0m24tlv/torchvision/csrc/cuda/ROIPool_cuda.cu:2:35: fatal error: ATen/cuda/CUDAContext.h: No such file or directory

It seems the problem is that my pytorch installation doesn't have this file, e.g. the results of looking in my include directory are:

> ls /home/rowan/anaconda3/envs/detectron/lib/python3.6/site-packages/torch/lib/include/ATen/cuda/
detail             CUDAApplyUtils.cuh  CUDAHalf.cuh           PinnedMemoryAllocator.h
ATenCUDAGeneral.h  CUDAConfig.h        CUDATensorMethods.cuh

If it helps, I installed torch from anaconda conda install pytorch -c pytorch and my version is 0.4.1.post2. Totally understand that this isn't the most pressing thing as it's in a separate branch but I thought I'd file it anyways in case the layers branch is going to get rolled into master 馃槃

Most helpful comment

Hi @rowanz. That particular file was added recently and should be available in the v1-rc version of PyTorch.

I have written all the layers to be compatible with v1 since there is significant change in ATen (the C++ backend for PyTorch) from v0.4 to v1 and it made sense to have forward compatibility.

If you wish to play with the ROI Pooling layers in the layers branch, my recommendation is to install PyTorch from source. v1 is right around the corner so you should be only slightly inconvenienced.

All 2 comments

Hi @rowanz. That particular file was added recently and should be available in the v1-rc version of PyTorch.

I have written all the layers to be compatible with v1 since there is significant change in ATen (the C++ backend for PyTorch) from v0.4 to v1 and it made sense to have forward compatibility.

If you wish to play with the ROI Pooling layers in the layers branch, my recommendation is to install PyTorch from source. v1 is right around the corner so you should be only slightly inconvenienced.

Closing via @varunagrawal comment

Was this page helpful?
0 / 5 - 0 ratings