haofeixu / aanet

[CVPR'20] AANet: Adaptive Aggregation Network for Efficient Stereo Matching
Apache License 2.0
534 stars 102 forks source link

Failed to import deform_conv_cuda #32

Closed MJITG closed 2 years ago

MJITG commented 4 years ago

Hi, @U @haofeixu , I meet the following trouble when I run your model.

Traceback (most recent call last):
  File "inf_time.py", line 8, in <module>
    import nets
  File "/home/lthpc/PRO/aanet-master/nets/__init__.py", line 1, in <module>
    from .aanet import AANet
  File "/home/lthpc/PRO/aanet-master/nets/aanet.py", line 4, in <module>
    from nets.feature import (StereoNetFeature, PSMNetFeature, GANetFeature, GCNetFeature,
  File "/home/lthpc/PRO/aanet-master/nets/feature.py", line 5, in <module>
    from nets.deform import DeformConv2d
  File "/home/lthpc/PRO/aanet-master/nets/deform.py", line 3, in <module>
    from nets.deform_conv import DeformConv, ModulatedDeformConv
  File "/home/lthpc/PRO/aanet-master/nets/deform_conv/__init__.py", line 1, in <module>
    from .deform_conv import (DeformConv, DeformConvPack, ModulatedDeformConv,
  File "/home/lthpc/PRO/aanet-master/nets/deform_conv/deform_conv.py", line 9, in <module>
    from . import deform_conv_cuda
ImportError: /home/lthpc/PRO/aanet-master/nets/deform_conv/deform_conv_cuda.cpython-37m-x86_64-linux-gnu.so: undefined symbol: _ZN3c105ErrorC1ENS_14SourceLocationERKSs

The building of your deform conv is finished, during which I have the following output:

running build_ext
building 'deform_conv_cuda' extension
creating build
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/src
gcc -pthread -B /opt/anaconda3/envs/AutoML-new_master2/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/TH -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/THC -I/usr/local/cuda-10.0/include -I/opt/anaconda3/envs/AutoML-new_master2/include/python3.7m -c src/deform_conv_cuda.cpp -o build/temp.linux-x86_64-3.7/src/deform_conv_cuda.o -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=deform_conv_cuda -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [enabled by default]
In file included from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/core/Device.h:5:0,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/core/Allocator.h:6,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/ATen/ATen.h:3,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader_options.h:4,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader/base.h:3,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader/stateful.h:3,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader.h:3,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/data.h:3,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include/torch/all.h:4,
                 from /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/extension.h:4,
                 from src/deform_conv_cuda.cpp:4:
src/deform_conv_cuda.cpp: In function ‘void shape_check(at::Tensor, at::Tensor, at::Tensor*, at::Tensor, int, int, int, int, int, int, int, int, int, int)’:
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:66:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.ndimension() == 4,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:66:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.ndimension() == 4,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:71:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.is_contiguous(), "weight tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:71:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.is_contiguous(), "weight tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:73:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(kW > 0 && kH > 0,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:73:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(kW > 0 && kH > 0,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:77:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((weight.size(2) == kH && weight.size(3) == kW),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:77:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((weight.size(2) == kH && weight.size(3) == kW),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:82:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(dW > 0 && dH > 0,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:82:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(dW > 0 && dH > 0,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:85:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:85:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:101:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(ndim == 3 || ndim == 4, "3D or 4D input tensor expected but got: %s",
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:101:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(ndim == 3 || ndim == 4, "3D or 4D input tensor expected but got: %s",
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:113:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(nInputPlane % deformable_group == 0,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:113:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(nInputPlane % deformable_group == 0,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:123:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(input.size(1) == nInputPlane,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:123:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(input.size(1) == nInputPlane,
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:127:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((inputHeight >= kH && inputWidth >= kW),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:127:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((inputHeight >= kH && inputWidth >= kW),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:130:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(2) == outputHeight && offset.size(3) == outputWidth),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:130:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(2) == outputHeight && offset.size(3) == outputWidth),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:135:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(1) == deformable_group * 2 * kH * kW),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:135:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(1) == deformable_group * 2 * kH * kW),
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:139:5: note: in expansion of macro ‘AT_CHECK’
     AT_CHECK(gradOutput->size(dimf) == nOutputPlane,
     ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:139:5: note: in expansion of macro ‘AT_CHECK’
     AT_CHECK(gradOutput->size(dimf) == nOutputPlane,
     ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:143:5: note: in expansion of macro ‘AT_CHECK’
     AT_CHECK((gradOutput->size(dimh) == outputHeight &&
     ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:143:5: note: in expansion of macro ‘AT_CHECK’
     AT_CHECK((gradOutput->size(dimh) == outputHeight &&
     ^
src/deform_conv_cuda.cpp: In function ‘int deform_conv_forward_cuda(at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, int, int, int, int, int, int, int, int, int, int, int)’:
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:194:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(0) == batchSize), "invalid batch size of offset");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:194:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(0) == batchSize), "invalid batch size of offset");
   ^
src/deform_conv_cuda.cpp: In function ‘int deform_conv_backward_input_cuda(at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, int, int, int, int, int, int, int, int, int, int, int)’:
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:301:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(0) == batchSize), 3, "invalid batch size of offset");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:301:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(0) == batchSize), 3, "invalid batch size of offset");
   ^
src/deform_conv_cuda.cpp: In function ‘int deform_conv_backward_parameters_cuda(at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, int, int, int, int, int, int, int, int, int, int, float, int)’:
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:417:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(0) == batchSize), "invalid batch size of offset");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:417:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK((offset.size(0) == batchSize), "invalid batch size of offset");
   ^
src/deform_conv_cuda.cpp: In function ‘void modulated_deform_conv_cuda_forward(at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, int, int, int, int, int, int, int, int, int, int, bool)’:
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:497:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(input.is_contiguous(), "input tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:497:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(input.is_contiguous(), "input tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:498:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.is_contiguous(), "weight tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:498:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.is_contiguous(), "weight tensor has to be contiguous");
   ^
src/deform_conv_cuda.cpp: In function ‘void modulated_deform_conv_cuda_backward(at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, at::Tensor, int, int, int, int, int, int, int, int, int, int, bool)’:
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:579:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(input.is_contiguous(), "input tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:579:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(input.is_contiguous(), "input tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:20: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                    ^
src/deform_conv_cuda.cpp:580:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.is_contiguous(), "weight tensor has to be contiguous");
   ^
/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:339:40: warning: ‘void c10::detail::deprecated_AT_CHECK()’ is deprecated (declared at /opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/c10/util/Exception.h:314) [-Wdeprecated-declarations]
     ::c10::detail::deprecated_AT_CHECK();                 \
                                        ^
src/deform_conv_cuda.cpp:580:3: note: in expansion of macro ‘AT_CHECK’
   AT_CHECK(weight.is_contiguous(), "weight tensor has to be contiguous");
   ^
/usr/local/cuda-10.0/bin/nvcc -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/torch/csrc/api/include -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/TH -I/opt/anaconda3/envs/AutoML-new_master2/lib/python3.7/site-packages/torch/include/THC -I/usr/local/cuda-10.0/include -I/opt/anaconda3/envs/AutoML-new_master2/include/python3.7m -c src/deform_conv_cuda_kernel.cu -o build/temp.linux-x86_64-3.7/src/deform_conv_cuda_kernel.o -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options '-fPIC' -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=deform_conv_cuda -D_GLIBCXX_USE_CXX11_ABI=1 -std=c++11
creating build/lib.linux-x86_64-3.7
g++ -pthread -shared -B /opt/anaconda3/envs/AutoML-new_master2/compiler_compat -L/opt/anaconda3/envs/AutoML-new_master2/lib -Wl,-rpath=/opt/anaconda3/envs/AutoML-new_master2/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/deform_conv_cuda.o build/temp.linux-x86_64-3.7/src/deform_conv_cuda_kernel.o -L/usr/local/cuda-10.0/lib64 -lcudart -o build/lib.linux-x86_64-3.7/deform_conv_cuda.cpython-37m-x86_64-linux-gnu.so
copying build/lib.linux-x86_64-3.7/deform_conv_cuda.cpython-37m-x86_64-linux-gnu.so -> 
MJITG commented 4 years ago

My environment is set as listed in README.md

Hahaemmm commented 4 years ago

How did you solve this problem

shicuiweia commented 3 years ago

@MJITG 同学,跑这个代码遇到点问题,能不能加个联系方式请教下,谢谢了。我微信c937688576

MJITG commented 3 years ago

How did you solve this problem

@Hahaemmm Sorry for late response. I just switched to another machine and all worked fine.

MJITG commented 3 years ago

@MJITG 同学,跑这个代码遇到点问题,能不能加个联系方式请教下,谢谢了。我微信c937688576

关于上面这个问题,我也只是换了一台机器就解决了。。。很玄学

shicuiweia commented 3 years ago

好的,我已解决,谢谢!

---Original--- From: "MJITG"<notifications@github.com> Date: Fri, Dec 18, 2020 19:51 PM To: "haofeixu/aanet"<aanet@noreply.github.com>; Cc: "Comment"<comment@noreply.github.com>;"shicuiweia"<937688576@qq.com>; Subject: Re: [haofeixu/aanet] Failed to import deform_conv_cuda (#32)

@MJITG 同学,跑这个代码遇到点问题,能不能加个联系方式请教下,谢谢了。我微信c937688576

关于上面这个问题,我也只是换了一台机器就解决了。。。很玄学

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

zhoumengtao-art commented 3 years ago

好的,我已解决,谢谢! ---Original--- From: "MJITG"<notifications@github.com> Date: Fri, Dec 18, 2020 19:51 PM To: "haofeixu/aanet"<aanet@noreply.github.com>; Cc: "Comment"<comment@noreply.github.com>;"shicuiweia"<937688576@qq.com>; Subject: Re: [haofeixu/aanet] Failed to import deform_conv_cuda (#32) @MJITG 同学,跑这个代码遇到点问题,能不能加个联系方式请教下,谢谢了。我微信c937688576 关于上面这个问题,我也只是换了一台机器就解决了。。。很玄学 — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

你好,你是怎么解决的呢

foruhari commented 3 years ago

hi. I still have this error while running or and I've tried on different machines but didn't run without this error. Can you please help me?

Traceback (most recent call last): File "inference.py", line 11, in <module> import nets File "D:\aanet\nets\__init__.py", line 1, in <module> from .aanet import AANet File "D:\aanet\nets\aanet.py", line 4, in <module> from nets.feature import (StereoNetFeature, PSMNetFeature, GANetFeature, GCNetFeature, File "D:\aanet\nets\feature.py", line 5, in <module> from nets.deform import DeformConv2d File "D:\aanet\nets\deform.py", line 3, in <module> from nets.deform_conv import DeformConv, ModulatedDeformConv File "D:\aanet\nets\deform_conv\__init__.py", line 1, in <module> from .deform_conv import (DeformConv, DeformConvPack, ModulatedDeformConv, File "D:\aanet\nets\deform_conv\deform_conv.py", line 9, in <module> from . import deform_conv_cuda ImportError: cannot import name 'deform_conv_cuda' from 'nets.deform_conv' (D:\aanet\nets\deform_conv\_ _init__.py)

ZDLLLL commented 3 years ago

@foruhari 你遇到的这个错误解决了吗

foruhari commented 3 years ago

@foruhari 你遇到的这个错误解决了吗

hello, unfortunately not yet, could you please help me?

zhoumengtao-art commented 3 years ago

不好意思,我也没有解决

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2021年8月15日(星期天) 中午11:49 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [haofeixu/aanet] Failed to import deform_conv_cuda (#32)

@foruhari 你遇到的这个错误解决了吗

hello, unfortunately not yet, could you please help me?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

Leviosaaaa commented 3 years ago

Perhaps you forgot to run: cd nets/deform_conv && bash build.sh

zhoumengtao-art commented 3 years ago

Thank you! I'll go back and check it. I haven't done AANet for a long time. I'm doing GANs recently.

------------------ 原始邮件 ------------------ 发件人: "haofeixu/aanet" @.>; 发送时间: 2021年9月8日(星期三) 晚上8:21 @.>; @.**@.>; 主题: Re: [haofeixu/aanet] Failed to import deform_conv_cuda (#32)

Perhaps you forgot to run: cd nets/deform_conv && bash build.sh

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

Jack47746 commented 3 years ago

请问有人遇到过这个问题么?我用colab跑的.... error in modulated_deformable_im2col_cuda: no kernel image is available for execution on the device

haofeixu commented 2 years ago

Hi all, sorry for the late response.

If this issue is still relavant to you, I would suggest to try our new GMStereo model: https://haofeixu.github.io/unimatch/ & https://github.com/autonomousvision/unimatch. No CUDA op is required. A Colab demo is also provided to try our model in your browser. Hope it helps, thanks.

zhoumengtao-art commented 2 years ago

Thank you for your attention to this issue, I will try your team's new model, may your team get better and better

---Original--- From: "Haofei @.> Date: Sun, Nov 13, 2022 12:08 PM To: @.>; Cc: @.**@.>; Subject: Re: [haofeixu/aanet] Failed to import deform_conv_cuda (#32)

Hi all, sorry for the late response.

If this issue is still relavant to you, I would suggest to try our new GMStereo model: https://haofeixu.github.io/unimatch/ & https://github.com/autonomousvision/unimatch. No CUDA op is required. A Colab demo is also provided to try our model in your browser. Hope it helps, thanks.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>