whisper
whisperX
Our great sponsors
whisper | whisperX | |
---|---|---|
343 | 24 | |
60,303 | 8,965 | |
5.9% | - | |
6.4 | 8.4 | |
16 days ago | 3 days ago | |
Python | Python | |
MIT License | BSD 4-Clause "Original" or "Old" License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
whisper
-
Why I Care Deeply About Web Accessibility And You Should Too
Let’s not talk about local models as the hardware requirements are way beyond most of these people’s reach. I have a MacBook Air with an M2 chip and 8GB of RAM and can hardly run Whisper locally, so I use this HuggingFace space.
-
How I built NotesGPT – a full-stack AI voice note app
Last week, I launched notesGPT, a free and open source voice note app that has 35,000 visitors, 7,000 users, and over 1,000 GitHub stars so far in the last week. It allows you to record a voice note, transcribes it uses Whisper, and uses Mixtral via Together to extract action items and display them in an action items view. It’s also fully open source and comes equipped with authentication, storage, vector search, action items, and is fully responsive on mobile for ease of use.
-
Ask HN: Can AI break a speech audio into individual words?
I found a pretty good discussion in the topic here:
https://github.com/openai/whisper/discussions/1243
-
WhisperSpeech – An Open Source text-to-speech system built by inverting Whisper
There is a plot of language performance on their repo: https://github.com/openai/whisper
I am not aware of a multi-lingual leaderboard for speech recognition models.
- Ask HN: AI that allows you to make phone calls in a language you don't speak?
-
Ask HN: Favorite Podcast Episodes of 2023?
I don't know how OP does it, but here's how I'd do it:
* Generate a transcript by runing Whisper against the podcast audio file: https://github.com/openai/whisper
* Upload transcript to ChatGPT and ask it to summarize.
* Automate all the above.
-
Need advice
Ahh, that makes sense. I've been building something like that, but only from other languages into English using Whisper
-
Subtitle is now open-source
Whisper already generates subtitles[0], supporting VTT and SRT so this is just a thin wrapper around that.
[0]: https://github.com/openai/whisper/blob/e58f28804528831904c3b...
-
StyleTTS2 – open-source Eleven Labs quality Text To Speech
> although it does require you to wear headphones so the bot doesn't hear itself and get interrupted.
Maybe you can rely on some sort of speaker identification to sort this out?
https://github.com/openai/whisper/discussions/264
-
Federated Finetuning of OpenAI's Whisper on Raspberry Pi 5
v3 only comes in one flavor: large.
I don’t think you’re going to have a good time running the large model on a Pi of any kind.
The large models are 32x slower than the tiny models, roughly.[0]
I’m seeing people report that the Pi 4 can transcribe 30 seconds of audio in somewhere between 30 seconds and 60 seconds with the tiny model.
You can do the math… 32x = 16 minutes to 32 minutes to transcribe 30 seconds of audio with the large model. Not a good time for most people.
The Pi 5 could be 2x to 3x faster.
I should benchmark my Pi 4 sometime (or Pi 5, if it ever shows up).
[0]: https://github.com/openai/whisper/blob/main/README.md#availa...
whisperX
-
Easy video transcription and subtitling with Whisper, FFmpeg, and Python
It uses this, which does support diarization: https://github.com/m-bain/whisperX
-
SOTA ASR Tooling: Long-Form Transcription
Author compared various whisper implementation
"We found that WhisperX is the best framework for transcribing long audio files efficiently and accurately. It’s much better than using the standard openai-whisper library."
https://github.com/m-bain/whisperX
-
Deploying whisperX on AWS SageMaker as Asynchronous Endpoint
import os # Directory and file paths dir_path = './models-v1' inference_file_path = os.path.join(dir_path, 'code/inference.py') requirements_file_path = os.path.join(dir_path, 'code/requirements.txt') # Create the directory structure os.makedirs(os.path.dirname(inference_file_path), exist_ok=True) # Inference.py content inference_content = '''# inference.py # inference.py import io import json import logging import os import tempfile import time import boto3 import torch import whisperx DEVICE = 'cuda' if torch.cuda.is_available() else 'cpu' s3 = boto3.client('s3') def model_fn(model_dir, context=None): """ Load and return the WhisperX model necessary for audio transcription. """ print("Entering model_fn") logging.info("Loading WhisperX model") model = whisperx.load_model(whisper_arch=f"{model_dir}/guillaumekln/faster-whisper-large-v2", device=DEVICE, language="en", compute_type="float16", vad_options={'model_fp': f"{model_dir}/whisperx/vad/pytorch_model.bin"}) print("Loaded WhisperX model") print("Exiting model_fn with model loaded") return { 'model': model } def input_fn(request_body, request_content_type): """ Process and load audio from S3, given the request body containing S3 bucket and key. """ print("Entering input_fn") if request_content_type != 'application/json': raise ValueError("Invalid content type. Must be application/json") request = json.loads(request_body) s3_bucket = request['s3bucket'] s3_key = request['s3key'] # Download the file from S3 temp_file = tempfile.NamedTemporaryFile(delete=False) s3.download_file(Bucket=s3_bucket, Key=s3_key, Filename=temp_file.name) print(f"Downloaded audio from S3: {s3_bucket}/{s3_key}") print("Exiting input_fn") return temp_file.name def predict_fn(input_data, model, context=None): """ Perform transcription on the provided audio file and delete the file afterwards. """ print("Entering predict_fn") start_time = time.time() whisperx_model = model['model'] logging.info("Loading audio") audio = whisperx.load_audio(input_data) logging.info("Transcribing audio") transcription_result = whisperx_model.transcribe(audio, batch_size=16) try: os.remove(input_data) # input_data contains the path to the temp file print(f"Temporary file {input_data} deleted.") except OSError as e: print(f"Error: {input_data} : {e.strerror}") end_time = time.time() elapsed_time = end_time - start_time logging.info(f"Transcription took {int(elapsed_time)} seconds") print(f"Exiting predict_fn, processing took {int(elapsed_time)} seconds") return transcription_result def output_fn(prediction, accept, context=None): """ Prepare the prediction result for the response. """ print("Entering output_fn") if accept != "application/json": raise ValueError("Accept header must be application/json") response_body = json.dumps(prediction) print("Exiting output_fn with response prepared") return response_body, accept ''' # Write the inference.py file with open(inference_file_path, 'w') as file: file.write(inference_content) # Requirements.txt content requirements_content = '''speechbrain==0.5.16 faster-whisper==0.7.1 git+https://github.com/m-bain/whisperx.git@1b092de19a1878a8f138f665b1467ca21b076e7e ffmpeg-python ''' # Write the requirements.txt file with open(requirements_file_path, 'w') as file: file.write(requirements_content)
-
OpenVoice: Versatile Instant Voice Cloning
Whisper doesn't, but WhisperX <https://github.com/m-bain/whisperX/> does. I am using it right now and it's perfectly serviceable.
For reference, I'm transcribing research-related podcasts, meaning speech doesn't overlap a lot, which would be a problem for WhisperX from what I understand. There's also a lot of accents, which are straining on Whisper (though it's also doing well), but surely help WhisperX. It did have issues with figuring number of speakers on it's own, but that wasn't a problem for my use case.
- FLaNK 15 Jan 2024
-
Subtitle is now open-source
I've had good results with whisperx when I needed to generate captions. https://github.com/m-bain/whisperX
There is currently a problem with diarization, but otherwise, it is SOTA.
-
Insanely Fast Whisper: Transcribe 300 minutes of audio in less than 98 seconds
https://github.com/m-bain/whisperX/issues/569
WhisperX with the new model. It's not fast.
-
Distil-Whisper: distilled version of Whisper that is 6 times faster, 49% smaller
How much faster in real wall-clock time is this in batched data than https://github.com/m-bain/whisperX ?
-
whisper self hosted what's the most cost-efficient way
Checkout whisperx
-
Whisper Turbo: transcribe 20x faster than realtime using Rust and WebGPU
Neat to see a new implementation, although I'll note that for those looking for a drop-in replacement for the whisper library, I believe that both faster-whisper https://github.com/guillaumekln/faster-whisper and https://github.com/m-bain/whisperX are easier (PyTorch-based, doesn't require a web browser), and a lot faster (WhisperX is up to 70X realtime).
What are some alternatives?
vosk-api - Offline speech recognition API for Android, iOS, Raspberry Pi and servers with Python, Java, C# and Node
whisper.cpp - Port of OpenAI's Whisper model in C/C++
silero-vad - Silero VAD: pre-trained enterprise-grade Voice Activity Detector
faster-whisper - Faster Whisper transcription with CTranslate2
buzz - Buzz transcribes and translates audio offline on your personal computer. Powered by OpenAI's Whisper.
insanely-fast-whisper - Incredibly fast Whisper-large-v3
NeMo - A scalable generative AI framework built for researchers and developers working on Large Language Models, Multimodal, and Speech AI (Automatic Speech Recognition and Text-to-Speech)
openai-whisper-cpu - Improving transcription performance of OpenAI Whisper for CPU based deployment
ControlNet - Let us control diffusion models!
text-generation-webui - A Gradio web UI for Large Language Models. Supports transformers, GPTQ, AWQ, EXL2, llama.cpp (GGUF), Llama models.
subgen - Autogenerate subtitles using OpenAI Whisper Model via Jellyfin, Plex, Emby, Tautulli, or Bazarr