Skip to content

How-ToGPU

How to Label Who Said What in a Local Transcript with WhisperX

A standard Whisper transcript doesn't say who is speaking. WhisperX adds speaker diarisation using pyannote's free model, all on your own PC. We show how to install it, get Hugging Face access to the model, label speakers and cut memory use on smaller GPUs.

By , Systems & Technical Editor

5 min read

How to Label Who Said What in a Local Transcript with WhisperX

This guide is based on the WhisperX README on GitHub, the pyannote speaker-diarization-community-1 model card on Hugging Face and the Python venv documentation, all read on 27 November 2026.

A plain Whisper transcript of a meeting, interview or podcast gives you one long block of text with no idea who said what. Speaker diarisation fixes that: it works out where one voice stops and another starts and labels each part of the transcript with a speaker. WhisperX, a free open-source project, combines Whisper transcription with the pyannote diarisation model so you can do it on your own PC, without uploading recordings to a cloud service.

If you only need a straightforward transcript, start with our guide to transcribing audio locally with Whisper instead. If you're choosing between Whisper engines, see whisper.cpp vs faster-whisper.

What you need

  • A Windows or Linux PC. WhisperX can run on the CPU, but the README is written around NVIDIA GPU acceleration, and that's the faster route for long recordings.

  • An NVIDIA graphics card (recommended). The README says WhisperX's faster-whisper backend needs less than 8GB of GPU memory for the large-v2 model with beam_size=5. Our best GPUs for Whisper picks cover suitable cards.

  • Python, plus free disk space for the models WhisperX downloads.

  • A free Hugging Face account, because the diarisation model is downloaded from Hugging Face and you have to accept its conditions first.

Step 1: Install the CUDA toolkit (NVIDIA GPUs only)

The WhisperX README says to install the CUDA toolkit 12.8 before WhisperX if you want GPU acceleration. On Windows, download it from NVIDIA's CUDA Downloads page; on Linux, follow NVIDIA's CUDA installation guide. Skip this step if you'll only use the CPU.

Step 2: Create a virtual environment and install WhisperX

Keeping WhisperX in its own Python virtual environment stops it clashing with other AI tools. Open PowerShell in the folder where you want to work and run:

python -m venv whisperx-env
whisperx-env\Scripts\Activate.ps1
pip install whisperx

On Linux, activate the environment with source whisperx-env/bin/activate instead. The README also offers uvx whisperx if you use the uv tool. If PyTorch later reports that it can't see your GPU, our guide to fixing "CUDA not available" in PyTorch covers the usual causes.

Step 3: Get access to the diarisation model

WhisperX uses pyannote's speaker-diarization-community-1 model to tell voices apart. The model card says the repository is publicly accessible but you have to accept its conditions to access the files, and that the pipeline is released under the CC-BY-4.0 licence.

  1. Sign in to Hugging Face and open the pyannote/speaker-diarization-community-1 model page.

  2. Accept the user conditions. The form asks you to share your Hugging Face details with pyannote.

  3. Go to hf.co/settings/tokens and create an access token with read permission.

  4. Copy the token and keep it private. Treat it like a password.

Our guide to downloading models from Hugging Face explains accounts and tokens in more detail.

Step 4: Transcribe with speaker labels

With the virtual environment active, run WhisperX on your recording and add the diarisation options:

whisperx meeting.wav --model large-v2 --diarize --hf_token YOUR_TOKEN

Replace meeting.wav with your file and YOUR_TOKEN with the token from step 3. If you know how many people are speaking, tell WhisperX; the README gives --min_speakers 2 --max_speakers 2 as an example. Fixing the number usually makes sense for a two-person interview or a podcast with a known guest list.

The README also suggests adding --highlight_words True to see word timings in the .srt subtitle file it produces. If your recording isn't in English, add a language code such as --language de for German. The README says default alignment models are provided for English, French, German, Spanish and Italian, with many other languages handled through models on Hugging Face.

Step 5: If you run short of memory, or have no NVIDIA GPU

The README lists three ways to cut GPU memory use:

  • Reduce the batch size, for example --batch_size 4.

  • Use a smaller transcription model, for example --model base.

  • Use a lighter compute type with --compute_type int8.

To run entirely on the CPU, the README gives --compute_type int8 --device cpu. It's likely to be much slower than a graphics card on long recordings. To see how much memory WhisperX is actually using, follow our guide to checking VRAM usage in Windows.

Using WhisperX from Python

If you want to build diarisation into your own script, the README's Python example loads a model with whisperx.load_model, aligns the transcript, then runs DiarizationPipeline(token=YOUR_HF_TOKEN, device=device) from whisperx.diarize and attaches the labels with whisperx.assign_word_speakers. It notes that you can pass min_speakers and max_speakers to the diarisation step and change the compute type from float16 to int8 if you're low on GPU memory, which may reduce accuracy.

What to expect

WhisperX is quick and convenient, but its README is honest about its limits. It warns that overlapping speech isn't handled particularly well by Whisper or WhisperX, and that diarisation is "far from perfect". Words containing characters the alignment model doesn't know, such as numbers like "2014." or prices, can't be aligned and won't get a timing. Diarisation can tell voices apart, but it doesn't know who anyone is, so you'll still need to read through the transcript and put names to each speaker.

For the best results, use a clean recording with one microphone per person where possible, keep background noise down and set the number of speakers when you know it. If you'd rather not use the command line at all, our best local transcription apps include point-and-click options, and our guide to generating subtitles locally with Subtitle Edit covers subtitle work.

Our verdict

WhisperX is one of the simplest ways to get a local transcript that shows who said what: install the CUDA toolkit 12.8 if you have an NVIDIA GPU, run pip install whisperx in a virtual environment, accept the conditions for pyannote's speaker-diarization-community-1 model on Hugging Face, then run WhisperX with --diarize and your access token. Setting the number of speakers helps, and the int8, smaller-model and batch-size options get it running on cards with less memory. Just check the result, because the project itself says diarisation is far from perfect, especially when people talk over each other.

The bottom line

WhisperX is one of the simplest ways to get a local transcript that shows who said what: install the CUDA toolkit 12.8 if you have an NVIDIA GPU, run pip install whisperx in a virtual environment, accept the conditions for pyannote's speaker-diarization-community-1 model on Hugging Face, then run WhisperX with --diarize and your access token. Setting the number of speakers helps, and the int8, smaller-model and batch-size options get it running on cards with less memory. Just check the result, because the project itself says diarisation is far from perfect, especially when people talk over each other.

Sources

  1. 01GitHub, m-bain/whisperX README
  2. 02Hugging Face, pyannote/speaker-diarization-community-1 model card
  3. 03Python, venv: Creation of virtual environments

About the author

Marcus Thorne

Systems & Technical Editor

Marcus writes Forge PC's step-by-step build, troubleshooting and system optimisation guides. His background spans Windows kernel and power-state diagnostics, UEFI/BIOS configuration, NVMe storage arrays, ATX 3.1 power delivery and running local AI and LLM workloads on consumer graphics cards.

More from Marcus Thorne

Read next

How to Check a Pre-built Gaming PC's Specs Before You Buy

How-To

How to Check a Pre-built Gaming PC's Specs Before You Buy

Pre-built gaming PC listings often hide the details that matter. This checklist shows what to confirm before you buy in the UK: the exact graphics card and its VRAM, the full CPU model, RAM configuration, SSD type, the power supply, upgrade room and warranty, plus your 14-day right to cancel when buying online.

Marcus Thorne5 min

How to Optimise Game Settings with the NVIDIA App

How-To

How to Optimise Game Settings with the NVIDIA App

How to use the NVIDIA App's Optimize button and Performance-Quality slider to set a game's graphics automatically, plus how to change driver settings per game or globally, add or hide games and restore defaults.

Marcus Thorne5 min

RTX 4080 Super vs RTX 5080 for Local AI: Same 16GB, What Changes?

Versus

RTX 4080 Super vs RTX 5080 for Local AI: Same 16GB, What Changes?

The RTX 4080 Super and RTX 5080 both have 16GB of video memory, so they run the same AI models. We look at what the newer card changes for local AI: GDDR7 memory, FP4 support, NVIDIA's AI TOPS figures, power and size, and whether upgrading is worth it.

Callum Reid5 min