Simple python application to read pdf's out loud
usage: pdf2speech.py [-h] [--first_page FIRST_PAGE] [--speed SPEED] [--chunk_size CHUNK_SIZE] [--engine {espeak,mimic3}] filename
Listen to PDF files using text-to-speech
positional arguments:
filename PDF filename
optional arguments:
-h, --help show this help message and exit
--first_page FIRST_PAGE
First page number
--speed SPEED Speech speed (words per minute)
--chunk_size CHUNK_SIZE
Text chunks size
--engine {espeak,mimic3}
Engine used for TTS
Example: python pdf2speech.py test_data/pg11.pdf
pdftotext
, install packagepoppler-utils
on linux.krop
if--two_columns
option neededespeak
, install packageespeak
on linux.- mbrola voices for espeak also need to be installed to get a better sounding voice
mimic3
better sounding alternative to espeak, easy to use via docker. See also mimic3-server script to run the server more easily.aplay
, install packagealsa-utils
on linux.
This project was developed in a few hours of my spare time. If someone wants to build on this and maybe submit pull requests to improve it, I'm happy to take a look at it.