Skip to content
This repository has been archived by the owner on Oct 31, 2023. It is now read-only.

Issue running python setup.py build develop #568

Closed
zaidhassanch opened this issue Mar 14, 2019 · 2 comments
Closed

Issue running python setup.py build develop #568

zaidhassanch opened this issue Mar 14, 2019 · 2 comments
Labels
duplicate This issue or pull request already exists

Comments

@zaidhassanch
Copy link

🐛 Bug

To Reproduce

Steps to reproduce the behavior:

  1. Follow instructions in INSTALL.MD to install maskrcnn-benchmark
  2. Install dependencies
  3. python setup.py build develop (in the maskrcnn-benchmark directory)

error: invalid initialization of reference of type ‘const at::Type&’ from expression of type ‘c10::ScalarType’ AT_DISPATCH_FLOATING_TYPES(input.scalar_type(), "ROIAlign_forward", [&] { ^ /home/ahmad/anaconda3/envs/mrcnn2/lib/python3.7/site-packages/torch/lib/include/ATen/Dispatch.h:15:32: note: in definition of macro ‘AT_DISPATCH_FLOATING_TYPES’ const at::Type& the_type = TYPE; \ ^ error: command 'gcc' failed with exit status 1

Expected behavior

Successful run of the setup.py script

Environment

Collecting environment information...
PyTorch version: 1.0.1.post2
Is debug build: No
CUDA used to build PyTorch: None

OS: Ubuntu 16.04.5 LTS
GCC version: (Ubuntu 5.4.0-6ubuntu1~16.04.10) 5.4.0 20160609
CMake version: Could not collect

Python version: 3.7
Is CUDA available: No
CUDA runtime version: No CUDA
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA

Versions of relevant libraries:
[pip] numpy==1.16.2
[pip] torch==1.0.1.post2
[pip] torchvision==0.2.2
[conda] blas 1.0 mkl
[conda] mkl 2019.1 144
[conda] mkl_fft 1.0.10 py37ha843d7b_0
[conda] mkl_random 1.0.2 py37hd81dba3_0
[conda] pytorch-cpu 1.0.1 py3.7_cpu_2 pytorch
[conda] torchvision-cpu 0.2.2 py_3 pytorch

Additional context

Changing AT_DISPATCH_FLOATING_TYPES(input.scalar_type(), "ROIAlign_forward"..
to AT_DISPATCH_FLOATING_TYPES(input.type(), "ROIAlign_forward"..
seems to solve the problem

@zaidhassanch
Copy link
Author

zaidhassanch commented Mar 14, 2019

#557 gives the recommended solution, thus I am closing the issue.
#567, submitted around the same time as this issue, references the same problem.

@zaidhassanch
Copy link
Author

Duplicate of #567

@fmassa fmassa added the duplicate This issue or pull request already exists label Mar 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants