acids-ircam / rave_vst

Other
184 stars 28 forks source link

Making it work on Pop!_OS 22.04 (Ubuntu 22.04 derivative) #15

Closed macramole closed 2 years ago

macramole commented 2 years ago

Just wanted to share how I made the provided binary work under Linux

Running the Standalone version will cause this error: ./RAVE: error while loading shared libraries: libtorch_cpu.so: cannot open shared object file: No such file or directory

My solution is:

wget "https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-1.11.0%2Bcpu.zip"
unzip libtorch-cxx11-abi-shared-with-deps-1.11.0+cpu.zip
LD_LIBRARY_PATH=libtorch/lib/ ./RAVE

The last command should open the software without problems.

Making the VST work will be a little more tricky since libtorch/lib should be made available system-wide.

Hope it helps someone.

Also, is there any pretrained model I can download to test it further ?

Thanks in advance, awesome work !

ZodiacFRA commented 2 years ago

Thanks @macramole ! Glad it worked :)

However our Cmakefile was supposed to handle all this :sweat_smile:

if (NOT torch_lib)
  message(STATUS "Downloading torch C API pre-built")

  # Download
  if (UNIX AND NOT APPLE)  # Linux
    set(torch_url
        "https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-${torch_version}%2Bcpu.zip")
  elseif (UNIX AND APPLE)  # OSX
    set(torch_url
        "https://download.pytorch.org/libtorch/cpu/libtorch-macos-${torch_version}.zip")
  else()                   # Windows
    set(torch_url
        "https://download.pytorch.org/libtorch/cpu/libtorch-win-shared-with-deps-${torch_version}%2Bcpu.zip")
  endif()

  file(DOWNLOAD
    ${torch_url}
    ${torch_dir}/torch_cc.zip
    SHOW_PROGRESS
  )
  execute_process(COMMAND ${CMAKE_COMMAND} -E tar -xf torch_cc.zip
                  WORKING_DIRECTORY ${torch_dir})

  file(REMOVE ${torch_dir}/torch_cc.zip)

endif()

# Find the libraries again
find_library(torch_lib
  NAMES ${torch_lib_name}
  PATHS ${torch_dir}/libtorch/lib
)
if (NOT torch_lib)
  message(FATAL_ERROR "torch could not be included")

(From /cmake/add_torch.cmake) Did you get errors during the build's setup? Did you use the exact same commands as in the readme?

About the pretrained models, at least one will be made available in the next few days, in the "model explorer" section of the VST :)

macramole commented 2 years ago

Sorry maybe I wasn't clear. I didn't build it, I just downloaded the binary you provided and didn't work out of the box. This is for people in the same situation.

A pretrained model would be great to get started fast ! I can't train right now, computer is busy training other models for my thesis, but will get there.

El vie., 20 may. 2022 06:44, Jb Dpy @.***> escribió:

Closed #15 https://github.com/acids-ircam/rave_vst/issues/15 as completed.

— Reply to this email directly, view it on GitHub https://github.com/acids-ircam/rave_vst/issues/15#event-6649225512, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAWH6OJ7K2K53PXNE2JC7MTVK5NJLANCNFSM5WK4RTEA . You are receiving this because you were mentioned.Message ID: @.***>