xingyizhou / CenterNet

Object detection, 3D detection, and pose estimation using center point detection:
MIT License
7.27k stars 1.92k forks source link

fatal error: torch/extension.h: No such file or directory #include <torch/extension.h> compilation terminated. error: command 'gcc' failed with exit status 1 #645

Closed Devoe-97 closed 4 years ago

Devoe-97 commented 4 years ago

when I compile deformable convolutional (from DCNv2), I get thie error. ` In file included from /home/ljh/workspace/CenterNet-master/src/lib/models/networks/DCNv2/src/dcn_v2.h:3:0, from /home/ljh/workspace/CenterNet-master/src/lib/models/networks/DCNv2/src/vision.cpp:2: /home/ljh/workspace/CenterNet-master/src/lib/models/networks/DCNv2/src/cpu/vision.h:2:10: fatal error: torch/extension.h: No such file or directory

include <torch/extension.h>

      ^~~~~~~~~~~~~~~~~~~

compilation terminated. error: command 'gcc' failed with exit status 1 `

xingyizhou commented 4 years ago

This is due to the DCNv2 version does not match your pytorch version. Please check.

Devoe-97 commented 4 years ago

I reset the CUDA_HOME and finish this problem.