Crates.io | fry |
lib.rs | fry |
version | 0.0.2 |
source | src |
created_at | 2023-10-25 01:40:13.286581 |
updated_at | 2023-10-28 22:20:08.773066 |
description | A dead-simple, no-alloc, no-std TTS. |
homepage | |
repository | https://github.com/TTWNO/fry |
max_upload_size | |
id | 1012997 |
size | 1,537,380 |
fry
A very simple, dumb, no-alloc, no-std TTS. This comes with a handful of extreme limitation:
espeak
to generate the sound files, and sox
to modify the output to be of a fixed length.The name is from the term "vocal fry".
If you'd like to produce new files for the library to use (this is required to change the speed of the speech, for example), then you can use the scripts in data
to create new files.
Please note that you will have to manually update variables in both the scripts and the library to accomodate any changes made to the data files.
generate_base.sh
This script creates new files using espeak
and the list of english alphabetic characters to create [a-z].wav
You may modify the arguments to espeak to produce faster sounds via the -s
flag for settings "words per minute".
Check out man espeak
or man espeak-ng
for more details.
calc.py
This Python file uses the sox
command, along with some basic math to calculate the output for adding 0
padding to the WAV file so all files have exactly the same length (in bytes and time).
Then, strip the headers so that the WAV data is simply raw PCM data.
It is up the user what they will do with this data.
If mediainfo
displays different information than this for [a-z].wav
, then you may need to change the settings in the constants of calc.py
to produce the right sized padded/raw files.
.wav
files..wav
files.
sox
(calc.py
)python
(calc.py
)espeak
(generate-base.sh
)bash
(generate-base.sh
)std
and alloc
features for when they are available to the consumer.lib.rs
file:
PCM
type, because otherwise test output is WAY too big, generic over: