Skip to main content

Whisper command line client that uses CTranslate2

Project description

PyPI version PyPI downloads

Introduction

Whisper command line client compatible with original OpenAI client based on CTranslate2.

It uses CTranslate2 and Faster-whisper Whisper implementation that is up to 4 times faster than openai/whisper for the same accuracy while using less memory.

Goals of the project:

  • Provide an easy way to use the CTranslate2 Whisper implementation
  • Easy the migration for people using OpenAI Whisper CLI

Installation

Just type:

pip install -U whisper-ctranslate2

Alternatively, the following command will pull and install the latest commit from this repository, along with its Python dependencies:

pip install https://github.com/jordimas/whisper-ctranslate2

Usage

Same command line that OpenAI whisper.

To transcribe:

whisper-ctranslate2 inaguracio2011.mp3 --model medium
image

To translate:

whisper-ctranslate2 inaguracio2011.mp3 --model medium --task translate
image

Additionally using:

whisper-ctranslate2 --help

All the supported options with their help are shown.

CTranslate2 specific options

On top of the OpenAI Whisper command line options, there are some specific CTranslate2 options.

--compute_type {default,auto,int8,int8_float16,int16,float16,float32}

Type of quantization to use. On CPU int8 will give the best performance.

--model_directory MODEL_DIRECTORY

Directory where to find a CTranslate Whisper model, for example a fine-tunned Whisper model. The model should be in CTranslate2 format.

Contact

Jordi Mas jmas@softcatala.org

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

whisper-ctranslate2-0.0.6.tar.gz (11.7 kB view details)

Uploaded Source

Built Distribution

whisper_ctranslate2-0.0.6-py3-none-any.whl (12.2 kB view details)

Uploaded Python 3

File details

Details for the file whisper-ctranslate2-0.0.6.tar.gz.

File metadata

  • Download URL: whisper-ctranslate2-0.0.6.tar.gz
  • Upload date:
  • Size: 11.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.7

File hashes

Hashes for whisper-ctranslate2-0.0.6.tar.gz
Algorithm Hash digest
SHA256 fb19775ab3f832840071e6164929903f0d5e050cd35347b21a5bdd45f71b8af1
MD5 6a108aa8f75e4c844c7fcb8f559563a8
BLAKE2b-256 95926cbfd302b9fe1f578b5c91e28f4cebb79226d9be0dabe1f06625b35738a0

See more details on using hashes here.

File details

Details for the file whisper_ctranslate2-0.0.6-py3-none-any.whl.

File metadata

File hashes

Hashes for whisper_ctranslate2-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 0fac012b989d3493835f866fa82c4a2c8a409878688e94c71f47ded448253a5a
MD5 13659925250a1cce1f7d2f64e4d7da4d
BLAKE2b-256 2aa84eac1ebb06877cd14c4a6723da88ca06c6bcc368840a117daf43244beca3

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page