You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Just want to test if CUDA part is working properly using below code but got errors. I linked both cpu and cuda libraries. The cpu part is working fine. Any idea on this?
Just want to test if CUDA part is working properly using below code but got errors. I linked both cpu and cuda libraries. The cpu part is working fine. Any idea on this?
cout << ones(CUDA(kFloat), {3,4}) << "\n";
TARGET_LINK_LIBRARIES(test_aten ${CUDA_LIBRARIES} ${ATen_BINARY_DIR}/src/ATen/libATen_cuda.so ${ATen_BINARY_DIR}/src/ATen/libATen_cpu.so)
terminate called after throwing an instance of 'at::Error'
what(): cannot initialize CUDA without ATen_cuda library (initCUDA at /home/pharrell/downloads/ATen/aten/src/ATen/detail/CUDAHooksInterface.h:42)
frame #0: at::Context::lazyInitCUDA()::{lambda()#1}::operator()() const + 0x32 (0x409a56 in ./test_aten)
frame #1: void std::_Bind_simple<at::Context::lazyInitCUDA()::{lambda()#1} ()>::_M_invoke<>(std::_Index_tuple<>) + 0x28 (0x40afb0 in ./test_aten)
frame #2: std::_Bind_simple<at::Context::lazyInitCUDA()::{lambda()#1} ()>::operator()() + 0x2c (0x40ace0 in ./test_aten)
frame #3: void std::__once_call_impl<std::_Bind_simple<at::Context::lazyInitCUDA()::{lambda()#1} ()> >() + 0x17 (0x40a7a4 in ./test_aten)
frame #4: + 0xea99 (0x7fe48d128a99 in /lib/x86_64-linux-gnu/libpthread.so.0)
frame #5: ./test_aten() [0x408ccd]
frame #6: void std::call_onceat::Context::lazyInitCUDA()::{lambda()#1}(std::once_flag&, at::Context::lazyInitCUDA()::{lambda()#1}&&) + 0x77 (0x40a0f7 in ./test_aten)
frame #7: at::Context::lazyInitCUDA() + 0x3d (0x409b37 in ./test_aten)
frame #8: at::Context::initCUDAIfNeeded(at::Backend) + 0x21 (0x409b81 in ./test_aten)
frame #9: at::Context::getTypeOpt(at::Backend, at::ScalarType) + 0x23 (0x40984b in ./test_aten)
frame #10: at::Context::getType(at::Backend, at::ScalarType) + 0x4a (0x40992a in ./test_aten)
frame #11: ./test_aten() [0x408da9]
frame #12: ./test_aten() [0x408de1]
frame #13: main + 0x65a (0x409467 in ./test_aten)
frame #14: __libc_start_main + 0xf0 (0x7fe48c3cc830 in /lib/x86_64-linux-gnu/libc.so.6)
frame #15: _start + 0x29 (0x408bb9 in ./test_aten)
Aborted (core dumped)
The text was updated successfully, but these errors were encountered: