Skip to content

Instantly share code, notes, and snippets.

View iamaziz's full-sized avatar
🎲

Aziz Alto iamaziz

🎲
View GitHub Profile
@iamaziz
iamaziz / fast_speech_text_speech_steramlit_app.py
Last active February 16, 2024 17:54 — forked from thomwolf/fast_speech_text_speech.py
speech to text to speech (Srteamlit App) - example in the comments
""" To use: install Ollama (or LLM studio), clone OpenVoice, run this script in the OpenVoice directory
git clone https://github.com/myshell-ai/OpenVoice
cd OpenVoice
git clone https://huggingface.co/myshell-ai/OpenVoice
cp -r OpenVoice/* .
pip install whisper pynput pyaudio streamlit ollama
script source: https://x.com/Thom_Wolf/status/1758140066285658351?s=20
"""
import tensorflow as tf
import numpy as np
corpus_raw = 'He is the king . The king is royal . She is the royal queen '
# convert to lower case
corpus_raw = corpus_raw.lower()
words = []
for word in corpus_raw.split():