Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to run the code sample with GPU on M2? #95

Open
angjelkom opened this issue Feb 19, 2024 · 1 comment
Open

How to run the code sample with GPU on M2? #95

angjelkom opened this issue Feb 19, 2024 · 1 comment

Comments

@angjelkom
Copy link

I have this code sample running, but it says that No GPU being used., how can I fix that?

from bark import SAMPLE_RATE, generate_audio, preload_models
from IPython.display import Audio
from scipy.io.wavfile import write as write_wav

# download and load all models
preload_models()

# generate audio from text
text_prompt = """
     Hallo, mein Name ist Jack. Wie geht's dier?
"""
audio_array = generate_audio(text_prompt, history_prompt="de_speaker_3")

write_wav("./audio2.wav", SAMPLE_RATE, audio_array)

# play text in notebook
Audio(audio_array, rate=SAMPLE_RATE)
Copy link

dagshub bot commented Feb 19, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant