Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Viewer

Notices

Reply
 
Thread Tools Search this Thread
Old 04-25-2025, 06:54 PM   #1
Geremia
Addict
Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!
 
Posts: 256
Karma: 100000
Join Date: Oct 2012
Device: Calibre
Piper with --cuda acceleration?

Is there a way to enable CUDA GPU acceleration with Calibre's packaged version of Piper?

Appending the "--cuda" flag had no effect; it still used only my CPU:
Code:
cat test.txt | /opt/calibre/bin/piper/piper --model /home/geremia/.cache/calibre/piper-voices/en_US-ryan-high.onnx --sentence-silence 0.0 --length_scale 0.1 --cuda
Geremia is offline   Reply With Quote
Old 04-25-2025, 09:08 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,265
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Build your own piper and replace the binary in the calibre package with it or with a script what adds --cuda to the argument list and then calls your own binary
kovidgoyal is offline   Reply With Quote
Advert
Old 04-26-2025, 03:27 PM   #3
Geremia
Addict
Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!
 
Posts: 256
Karma: 100000
Join Date: Oct 2012
Device: Calibre
Quote:
Originally Posted by kovidgoyal View Post
Build your own piper and replace the binary in the calibre package with it or with a script what adds --cuda to the argument list and then calls your own binary
Ah, so your binary doesn't have CUDA support.
Geremia is offline   Reply With Quote
Old 04-26-2025, 04:59 PM   #4
Geremia
Addict
Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!Geremia rocks like Gibraltar!
 
Posts: 256
Karma: 100000
Join Date: Oct 2012
Device: Calibre
Using a script
Code:
#!/bin/sh

# convert the bash alias="piper --cuda" into a bash function and run it:

/home/geremia/.local/bin/piper --cuda "$@"
in place of /opt/calibre/bin/piper that uses my GPU-enabled, PIP-installed piper, which works when I run
Code:
echo 'hello, this is a test.' | ./piper --model /home/geremia/.cache/calibre/piper-voices/en_US-ryan-high.onnx | aplay
, I get this in ebook-viewer:

Code:
calibre, version 8.3.0
ERROR: Read aloud failed: piper process failed with exit code: 2 and error messages:
Geremia is offline   Reply With Quote
Old 04-26-2025, 10:39 PM   #5
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,265
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No clue, calibre just calls the piper binary in json mode with each sentence, presumably it doesnt work with cuda in that mode. You'd have to ask the piper developers.
kovidgoyal is offline   Reply With Quote
Advert
Reply

Tags
calibre, cuda, gpu, piper, tts


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Piper GPU Acceleration apophis Calibre 2 03-26-2025 03:17 PM
Piper and MacOS problem MDMullins Viewer 6 11-14-2024 01:34 AM
T68 - Hardware graphics acceleration emmen Onyx Boox 6 12-29-2014 04:39 AM
Amazon's Silk Browser Acceleration Tested: Less Bandwidth Consumed, But Slower Perfor afv011 Kindle Fire 5 11-24-2011 04:08 PM
Android Honeycomb Port For Nook Color Gets Graphics Acceleration Nathan Campos News 0 01-30-2011 01:11 PM


All times are GMT -4. The time now is 12:11 AM.


MobileRead.com is a privately owned, operated and funded community.