Selur's Little Message Board
[INFO] Portable Vapoursynth (Windows) with pytorch&co - Printable Version

+- Selur's Little Message Board (
+-- Forum: Talk, Talk, Talk (
+--- Forum: A/V Talk (
+--- Thread: [INFO] Portable Vapoursynth (Windows) with pytorch&co (/thread-2918.html)

Portable Vapoursynth (Windows) with pytorch&co - Selur - 13.11.2022

For those that might be interessted, wanting to update to vs-rife 3.0.0 I ended up setting up a new portable Vapoursynth for the torchAddon with dependencies again and I thought the steps I used might be interessting to some of you:
  • I created a new empy Vapoursynth-folder
  • downloaded 'Windows embeddable package (64-bit)' from (3.11 isn't supported atm. by Vapoursynth)
  • extracted the Python download into the download into the 'Vapoursynth'-folder
  • downloaded 'VapourSynth64-Portable-R60.7z' from
  • extracted the Vapoursynth portable download into the 'Vapoursynth'-folder
  • downloaded from and save it into the 'Vapoursynth'-folder
  • opened a 'Windows Command Prompt'-window and navigate into the 'Vaporusynth'-folder
  • installed pip by calling :
  • opened the python310._pth in a text addition and added the following to lines above anything else in that file and saved the file
  • installed VSGAN
    • python -m pip install vsgan
    • python -m pip install torch===1.13.0+cu117 torchvision==0.14.0 -f
    • installed BASICVSR++
      python -m pip install mmcv-full -f
      python -m pip install tqdm
      python -m pip install opencv-python
      python -m pip install --upgrade vsbasicvsrpp
      python -m vsbasicvsrpp
  • installted RIFE
    • downloaded
    • extracted tensorrt- into my Vapoursynth folder
    • python -m pip install tensorrt-
    • deleted tensorrt-
    • python -m pip install --upgrade vsrife
    • created a folder 'vsrife_dependencies' inside the Vapoursynth folder and copied the other files form the CUDA-11.7_cuDNN-8.6.0_TensorRT- into it. This folder need to be added to when using vs-rife using:
      import site
      # add vs-rife dependencies to the path
      path = site.getsitepackages()[0]+'/vsrife_dependencies/'
      path = path.replace('\\', '/')
      import os
      os.environ["PATH"] = path + os.pathsep + os.environ["PATH"]
    • downloaded the models using:
      python -m vsrife
    • installed SWINIR
      python -m pip install --upgrade vsswinir
      python -m vsswinir
  • installed DPIR and onnxruntime-gpu
    python -m pip install --upgrade vsdpir
    python -m pip install --upgrade onnxruntime-gpu
    python -m vsdpir
  • created a onnxruntime_dlls folder inside the Vapoursynth folder.
    I copied from and NVIDIA CUDA SDK 11.4.1 runtimes the following files into the folder:
    • cublas64_11.dll
    • cublasLt64_11.dll
    • cudart64_110.dll
    • cudnn_cnn_infer64_8.dll
    • cudnn_ops_infer64_8.dll
    • cudnn64_8.dll
    • cufft64_10.dll
    • cufftw64_10.dll
    • msvcp140.dll
    • nvinfer.dll
    • nvinfer_builder_resource.dll
    • nvinfer_plugin.dll
    • nvonnxparser.dll
    • nvparsers.dll
    • vcruntime140.dll
    • vcruntime140_1.dll
  • When using vsdir or realesrgan in a Vapoursynth script:
    # Import libraries for onnxruntime
    import site
    import ctypes
    path = site.getsitepackages()[0]+'/onnxruntime_dlls/'
    needs to be added to the script to load the dlls.
  • installed REALESRGAN (which also uses onnxruntime)
    python -m pip install --upgrade vsrealesrgan
    python -m vsrealesrgan
  • Installed HINet
    python -m pip install --upgrade vshinet
    python -m vshinet

Cu Selur