Open FekLeyrTarg opened 3 years ago
under "third_party\flownet2\networks\resample2d_package", there will be a setup.py file. Please edit line 8 to reflect the following changes 'cxx_args = ['-std=c++14']'. curreny repo is set to c++11 standard and is having compiling issues. Replace it with C++14 and that should do the trick. After that run 'python setup.py install' and you should be able to find resample2d_cuda.
under "third_party\flownet2\networks\resample2d_package", there will be a setup.py file. Please edit line 8 to reflect the following changes 'cxx_args = ['-std=c++14']'. curreny repo is set to c++11 standard and is having compiling issues. Replace it with C++14 and that should do the trick. After that run 'python setup.py install' and you should be able to find resample2d_cuda.
Still no luck I'm afraid as I'm getting the same error despite the change.
Edit 1: Is it possible that Torch 1.4.0 must be installed and no higher versions?
Edit 2: Ok, I've managed to install Torch 1.4.0 via Conda. On Win10, using Pip doesn't work for some reason.
Now I'm getting a new error when trying to execute python setup.py build:
setup.py build
running build
running build_ext
C:\Users\Rafi\anaconda3\envs\consistent_depth\lib\site-packages\torch\utils\cpp_extension.py:209: UserWarning: Error checking compiler version for cl: [WinError 2] Das System kann die angegebene Datei nicht finden
warnings.warn('Error checking compiler version for {}: {}'.format(compiler, error))
building 'resample2d_cuda' extension
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30133\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -IC:\Users\Rafi\anaconda3\envs\consistent_depth\lib\site-packages\torch\include -IC:\Users\Rafi\anaconda3\envs\consistent_depth\lib\site-packages\torch\include\torch\csrc\api\include -IC:\Users\Rafi\anaconda3\envs\consistent_depth\lib\site-packages\torch\include\TH -IC:\Users\Rafi\anaconda3\envs\consistent_depth\lib\site-packages\torch\include\THC "-IC:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0\include" -IC:\Users\Rafi\anaconda3\envs\consistent_depth\include -IC:\Users\Rafi\anaconda3\envs\consistent_depth\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30133\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um" /EHsc /Tpresample2d_cuda.cc /Fobuild\temp.win-amd64-3.6\Release\resample2d_cuda.obj /MD /wd4819 /EHsc -std=c++14 -DTORCH_API_INCLUDE_EXTENSION_H -DTORCH_EXTENSION_NAME=resample2d_cuda -D_GLIBCXX_USE_CXX11_ABI=0
cl : Befehlszeile warning D9002 : Unbekannte Option "-std=c++14" wird ignoriert.
resample2d_cuda.cc
C:\Users\Rafi\anaconda3\envs\consistent_depth\lib\site-packages\torch\include\c10/core/Allocator.h(3): fatal error C1083: Datei (Include) kann nicht geöffnet werden: "stddef.h": No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.29.30133\\bin\\HostX86\\x64\\cl.exe' failed with exit status 2
By changing c++11 ti c++14 and running
python main.py --video_file data/videos/ayush.mp4 --path results/ayush \
--camera_params "1671.770118, 540, 960" --camera_model "SIMPLE_PINHOLE" \
--make_video
i get the following error:
Traceback (most recent call last): File "/home/Projects/consistent_depth/consistent_depth/third_party/flownet2/models.py", line 12, in
from networks.resample2d_package.resample2d import Resample2d ModuleNotFoundError: No module named 'networks' During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "main.py", line 5, in
from process import DatasetProcessor File "/home/Projects/consistent_depth/consistent_depth/process.py", line 10, in from flow import Flow File "/home/Projects/consistent_depth/consistent_depth/flow.py", line 15, in import optical_flow_flownet2_homography File "/home/Projects/consistent_depth/consistent_depth/optical_flow_flownet2_homography.py", line 11, in from third_party.flownet2.models import FlowNet2 File "/home/Projects/consistent_depth/consistent_depth/third_party/flownet2/models.py", line 23, in from .networks.channelnorm_package.channelnorm import ChannelNorm File "/home/Projects/consistent_depth/consistent_depth/third_party/flownet2/networks/channelnorm_package/channelnorm.py", line 5, in import channelnorm_cuda ModuleNotFoundError: No module named 'channelnorm_cuda'
my CUDA Version: nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2020 NVIDIA Corporation Built on Wed_Jul_22_19:09:09_PDT_2020 Cuda compilation tools, release 11.0, V11.0.221 Build cuda_11.0_bu.TC445_37.28845127_0
First of all thank you for this fantastic program. I'm confident it's going to be a game-changer.
I'm trying to use it on Windows 10 and I've managed to install the needed packages using Anaconda. However, I'm getting this error message: No module named 'resample2d_cuda'.
Reading up different solutions I've found out that I need to go to "third_party\flownet2\networks\resample2d_package" and enter:
python setup.py build python setup.py install
(Source: https://github.com/NVIDIA/vid2vid/issues/30 )
However, executing the first line gives me the following:
Any idea what I'm doing wrong?
I must say I'm not a programmer and I'm barely familiar with the Python/Linux stuff. So any help is very much apprechiated.