MCG-NKU/E2FGVI

Solving environment: failed

Tobe2d opened this issue · 15 comments

I try installing on both windows and linux however I get Solving environment: failed

conda env create -f environment.yml
Collecting package metadata (repodata.json): done
Solving environment: failed

ResolvePackageNotFound:

  • libffi==3.3=he6710b0_2
  • lcms2==2.12=h3be6417_0
  • matplotlib-base==3.4.2=py37hab158f2_0
  • tornado==6.1=py37h27cfd23_0
  • brotli==1.0.9=he6710b0_2
  • scipy==1.6.2=py37had2a1c9_1
  • bzip2==1.0.8=h7b6447c_0
  • locket==0.2.1=py37h06a4308_1
  • libpng==1.6.37=hbc83047_0
  • ffmpeg==4.2.2=h20bf706_0
  • freetype==2.10.4=h5ab3b9f_0
  • expat==2.4.1=h2531618_2
  • xz==5.2.5=h7b6447c_0
  • ncurses==6.2=he6710b0_1
  • openh264==2.1.0=hd408876_0
  • qt==5.9.7=h5867ecd_1pt150_0
  • pywavelets==1.1.1=py37h7b6447c_2
  • libgfortran-ng==7.5.0=ha8ba4b0_17
  • libwebp-base==1.2.0=h27cfd23_0
  • pcre==8.45=h295c915_0
  • jpeg==9d=h7f8727e_0
  • ca-certificates==2022.2.1=h06a4308_0
  • certifi==2021.10.8=py37h06a4308_2
  • gstreamer==1.14.0=h28cd5cc_2
  • lame==3.100=h7b6447c_0
  • libtiff==4.2.0=h85742a9_0
  • tk==8.6.11=h1ccaba5_0
  • glib==2.69.1=h5202010_0
  • pillow==8.3.1=py37h2c7a002_0
  • libgcc-ng==9.3.0=h5101ec6_17
  • openssl==1.1.1m=h7f8727e_0
  • libstdcxx-ng==9.3.0=hd4cf53a_17
  • fontconfig==2.13.1=h6c09931_0
  • zstd==1.4.9=haebb681_0
  • zlib==1.2.11=h7b6447c_3
  • _openmp_mutex==4.5=1_gnu
  • pyqt==5.9.2=py37h05f1152_2
  • libvpx==1.7.0=h439df22_0
  • libgomp==9.3.0=h5101ec6_17
  • python==3.7.11=h12debd9_0
  • dbus==1.13.18=hb2f20db_0
  • x264==1!157.20191217=h7b6447c_0
  • openjpeg==2.4.0=h3ad879b_0
  • libtasn1==4.16.0=h27cfd23_0
  • lz4-c==1.9.3=h295c915_1
  • cytoolz==0.11.0=py37h7b6447c_0
  • mkl_fft==1.3.0=py37h42c9631_2
  • sqlite==3.36.0=hc218d9a_0
  • gnutls==3.6.15=he1e5248_0
  • icu==58.2=he6710b0_3
  • pytorch==1.5.1=py3.7_cuda9.2.148_cudnn7.6.3_0
  • libgfortran4==7.5.0=ha8ba4b0_17
  • yaml==0.2.5=h7b6447c_0
  • ninja==1.10.2=hff7bd54_1
  • nettle==3.7.3=hbbd107a_1
  • kiwisolver==1.3.1=py37h2531618_0
  • setuptools==58.0.4=py37h06a4308_0
  • libopus==1.3.1=h7b6447c_0
  • libunistring==0.9.10=h27cfd23_0
  • matplotlib==3.4.2=py37h06a4308_0
  • sip==4.19.8=py37hf484d3e_0
  • gmp==6.2.1=h2531618_2
  • pip==21.2.2=py37h06a4308_0
  • numpy-base==1.20.3=py37h74d4b33_0
  • libidn2==2.3.2=h7f8727e_0
  • pyyaml==5.4.1=py37h27cfd23_1
  • libxcb==1.14=h7b6447c_0
  • gst-plugins-base==1.14.0=h8213a91_2
  • ld_impl_linux-64==2.35.1=h7274673_9
  • mkl-service==2.4.0=py37h7f8727e_0
  • libuuid==1.0.3=h7f8727e_2
  • mkl_random==1.2.2=py37h51133e4_0
  • mkl==2021.3.0=h06a4308_520
  • libxml2==2.9.12=h03d6c58_0
  • intel-openmp==2021.3.0=h06a4308_3350
  • numpy==1.20.3=py37hf144106_0

Hello, I'm not an author, but I went through this problem. I think this environment is far from optimal, I guess authors just dumped their current environment which worked for them at this moment and setup.
I suggest you to look at presented google colab demo - its easy to use it as reference. I think you can even copy their setup or try with newer version of cuda-toolkit or pytorch, only dependency here is your host GPU driver version and mmcv, which you can easily install even for the newest pytorch release. If you still have problems please let me know your CUDA version and GPU, maybe I could prepare conda env for you

@niemiaszek Thanks for the reply. I am really stuck at this point. if it is not to much to ask, If you could help on prepare conda env it will be great help.

Sorry for the inconvenience during installing dependencies. And thanks for @niemiaszek's reply.

We just updated the environment.yml file.

If this file still does not work for you, please consider following commands:

conda create -n e2fgvi python=3.7
conda activate e2fgvi

conda install pytorch==1.5.1 torchvision==0.6.1 cudatoolkit=10.1 -c pytorch
pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cu101/torch1.5/index.html
conda install tensorboard matplotlib scikit-image==0.16.2
pip install tqdm 

Please feel free to contact me if you have any question. 😄

Thank you so much @Paper99 I have been playing with it for a few days and getting multiple results.

Is there any way I can put my hands on the High-resolution version? as of now all results are really low resolution.

@ammartist you can see that high resolution model is in Work in progress. I guess training is much longer on higher resolutions. All we can do now is wait I guess :) Would be nice to have some approximate date though

Thank you for your attention.
We expect to release the model, which can handle videos with arbitrary resolution, at the begining of May, 2022.

is #12 related?

You may need to upgrade your pytorch version (>=1.5).

Hi Bro,

I got some error

(e2fgvi) E:\AI\E2FGVI>python test.py --model e2fgvi --video examples/tennis --mask examples/tennis_mask --ckpt release_model/E2FGVI-CVPR22.pth
load pretrained SPyNet...
load checkpoint from http path: https://download.openmmlab.com/mmediting/restorers/basicvsr/spynet_20210409-c6c1bd09.pth
Loading model from: release_model/E2FGVI-CVPR22.pth
Loading videos and masks from: examples/tennis | INPUT MP4 format: False
test.py:63: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead.
m = m.resize(size, Image.NEAREST)
Start test...
0%| | 0/14 [10:12<?, ?it/s]
Traceback (most recent call last):
File "test.py", line 224, in
main_worker()
File "test.py", line 166, in main_worker
pred_imgs, _ = model(masked_imgs, len(neighbor_ids))
File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call
result = self.forward(*input, **kwargs)
File "E:\AI\E2FGVI\model\e2fgvi.py", line 250, in forward
pred_flows[1])
File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call
result = self.forward(*input, **kwargs)
File "E:\AI\E2FGVI\model\modules\feat_prop.py", line 129, in forward
flow_n2)
File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call
result = self.forward(*input, **kwargs)
File "E:\AI\E2FGVI\model\modules\feat_prop.py", line 58, in forward
self.deform_groups)
File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\mmcv\ops\modulated_deform_conv.py", line 93, in forward
with_bias=ctx.with_bias)
RuntimeError: CUDA error: no kernel image is available for execution on the device

###############
conda create -n e2fgvi python=3.7
conda activate e2fgvi

conda install pytorch==1.5.1 torchvision==0.6.1 cudatoolkit=10.1 -c pytorch
pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cu101/torch1.5/index.html
conda install tensorboard matplotlib scikit-image==0.16.2
pip install tqdm

"RTX 3090ti"
#####################

@dong-lufei You can manually install opencv by conda install opencv -c conda-forge

@dong-lufei You can manually install opencv by conda install opencv -c conda-forge
CUDA out of memory. Tried to allocate 68.00 MiB (GPU 0; 2.00 GiB total capacity; 1.11 GiB already allocated; 13.22 MiB free; 1.21 GiB reserved in total by PyTorch)

CUDA out of memory. Tried to allocate 68.00 MiB (GPU 0; 2.00 GiB total capacity; 1.11 GiB already allocated; 13.22 MiB free; 1.21 GiB reserved in total by PyTorch)
@dong-lufei have you resolved this issue? I have very similar error:
RuntimeError: CUDA out of memory. Tried to allocate 684.00 MiB (GPU 0; 4.00 GiB total capacity; 2.94 GiB already allocated; 0 bytes free; 2.99 GiB reserved in total by PyTorch)

laatu2 commented

Hi Bro,

I got some error

(e2fgvi) E:\AI\E2FGVI>python test.py --model e2fgvi --video examples/tennis --mask examples/tennis_mask --ckpt release_model/E2FGVI-CVPR22.pth load pretrained SPyNet... load checkpoint from http path: https://download.openmmlab.com/mmediting/restorers/basicvsr/spynet_20210409-c6c1bd09.pth Loading model from: release_model/E2FGVI-CVPR22.pth Loading videos and masks from: examples/tennis | INPUT MP4 format: False test.py:63: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead. m = m.resize(size, Image.NEAREST) Start test... 0%| | 0/14 [10:12<?, ?it/s] Traceback (most recent call last): File "test.py", line 224, in main_worker() File "test.py", line 166, in main_worker pred_imgs, _ = model(masked_imgs, len(neighbor_ids)) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call result = self.forward(*input, **kwargs) File "E:\AI\E2FGVI\model\e2fgvi.py", line 250, in forward pred_flows[1]) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call result = self.forward(*input, **kwargs) File "E:\AI\E2FGVI\model\modules\feat_prop.py", line 129, in forward flow_n2) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call result = self.forward(*input, **kwargs) File "E:\AI\E2FGVI\model\modules\feat_prop.py", line 58, in forward self.deform_groups) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\mmcv\ops\modulated_deform_conv.py", line 93, in forward with_bias=ctx.with_bias) RuntimeError: CUDA error: no kernel image is available for execution on the device

############### conda create -n e2fgvi python=3.7 conda activate e2fgvi

conda install pytorch==1.5.1 torchvision==0.6.1 cudatoolkit=10.1 -c pytorch pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cu101/torch1.5/index.html conda install tensorboard matplotlib scikit-image==0.16.2 pip install tqdm

"RTX 3090ti" #####################

Hi Bro,

I got some error

(e2fgvi) E:\AI\E2FGVI>python test.py --model e2fgvi --video examples/tennis --mask examples/tennis_mask --ckpt release_model/E2FGVI-CVPR22.pth load pretrained SPyNet... load checkpoint from http path: https://download.openmmlab.com/mmediting/restorers/basicvsr/spynet_20210409-c6c1bd09.pth Loading model from: release_model/E2FGVI-CVPR22.pth Loading videos and masks from: examples/tennis | INPUT MP4 format: False test.py:63: DeprecationWarning: NEAREST is deprecated and will be removed in Pillow 10 (2023-07-01). Use Resampling.NEAREST or Dither.NONE instead. m = m.resize(size, Image.NEAREST) Start test... 0%| | 0/14 [10:12<?, ?it/s] Traceback (most recent call last): File "test.py", line 224, in main_worker() File "test.py", line 166, in main_worker pred_imgs, _ = model(masked_imgs, len(neighbor_ids)) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call result = self.forward(*input, **kwargs) File "E:\AI\E2FGVI\model\e2fgvi.py", line 250, in forward pred_flows[1]) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call result = self.forward(*input, **kwargs) File "E:\AI\E2FGVI\model\modules\feat_prop.py", line 129, in forward flow_n2) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\torch\nn\modules\module.py", line 550, in call result = self.forward(*input, **kwargs) File "E:\AI\E2FGVI\model\modules\feat_prop.py", line 58, in forward self.deform_groups) File "C:\ProgramData\Anaconda3\envs\e2fgvi\lib\site-packages\mmcv\ops\modulated_deform_conv.py", line 93, in forward with_bias=ctx.with_bias) RuntimeError: CUDA error: no kernel image is available for execution on the device

############### conda create -n e2fgvi python=3.7 conda activate e2fgvi

conda install pytorch==1.5.1 torchvision==0.6.1 cudatoolkit=10.1 -c pytorch pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cu101/torch1.5/index.html conda install tensorboard matplotlib scikit-image==0.16.2 pip install tqdm

"RTX 3090ti" #####################

3090ti may not support cuda 10.1, you may reinstall pytorch, try cuda 11.3

also reinstall mmcv-full

pip uninstall mmcv-full
pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cu113/torch1.10.0/index.html

laatu2 commented