Giter VIP home page Giter VIP logo

Comments (3)

wAIfu-DEV avatar wAIfu-DEV commented on July 25, 2024

This indeed seems to be the cause of the crash. I took the liberty to add a print statement in the source code, right before the call to open()
image
And got the path: C:\Users\jeje9\Desktop\rvc_test\rvc\lib\uvr5_pack\lib_v5\modelparams\4band_v2.json when the correct path should have been: C:\Users\jeje9\Desktop\rvc_test\lib\site-packages\rvc\lib\uvr5_pack\lib_v5\modelparams\4band_v2.json

from retrieval-based-voice-conversion.

wAIfu-DEV avatar wAIfu-DEV commented on July 25, 2024

Manually setting the CWD of the python script using os.chdir() fixes the issue on my end.

import os
import pydub

cwd = os.getcwd()
ffmpeg_exec = cwd + "\\ffmpeg.exe" # or any other path to ffmpeg, as long as it is absolute and not relative.

pydub.AudioSegment.converter = ffmpeg_exec

from dotenv import load_dotenv
from rvc.modules.uvr5.modules import UVR

# downloaded model from:
# https://github.com/TRvlvr/model_repo/releases/

load_dotenv(".env")

print(cwd)

print("Loading UVR")
uvr = UVR()

print("Extracting vocals...")

os.chdir(cwd + "\\Lib\\site-packages")

result = uvr.uvr_wrapper(
    model_name="2_HP-UVR.pth",
    audio_path=cwd + "\\audio.wav",
    save_vocal_path=cwd + "\\vocal",
    save_ins_path=cwd + "\\inst",
    agg=5,
    export_format="wav",
    temp_path=cwd + "\\tmp")

for i in result:
    print(i)

from retrieval-based-voice-conversion.

Tps-F avatar Tps-F commented on July 25, 2024

Sorry it took me so long to notice.
I haven't tested it on windows yet, I'll fix it again.

from retrieval-based-voice-conversion.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.