Documentation Index
Fetch the complete documentation index at: https://mintlify.com/facebookresearch/audioseal/llms.txt
Use this file to discover all available pages before exploring further.
Installation
AudioSeal can be installed via pip from PyPI or built from source. Follow the instructions below based on your needs.Requirements
Before installing AudioSeal, ensure your environment meets these requirements:- Python ≥ 3.8 (≥ 3.10 for streaming support)
- PyTorch ≥ 1.13.0
- Omegaconf - Configuration management
- NumPy - Numerical operations
- einops - Tensor operations (required for streaming support with Python ≥ 3.10)
For streaming support, you must use Python 3.10 or higher. Streaming features are not available in Python 3.8 or 3.9.
Install from PyPI
The simplest way to install AudioSeal is using pip:Install from Source
For development or to use the latest features, you can install AudioSeal from source:Optional Dependencies
For development or advanced features, you may want to install additional dependencies:- torchaudio - Audio I/O and processing
- soundfile - Alternative audio backend
- pytest - Testing framework
- black - Code formatting
- isort - Import sorting
- flake8 - Linting
- pre-commit - Git hooks
Verify Installation
After installation, verify that AudioSeal is working correctly:Platform-Specific Notes
Windows
On Windows, if you encounter the error:macOS / Linux
AudioSeal works out of the box on macOS and Linux. For GPU acceleration, ensure you have CUDA installed and a compatible PyTorch build:Model Checkpoints
AudioSeal automatically downloads model checkpoints from Hugging Face on first use. Checkpoints are cached in:- Linux/macOS:
~/.cache/audioseal/ - Windows:
C:\Users\<USERNAME>\.cache\audioseal\
AUDIOSEAL_CACHE_DIR environment variable:
Hugging Face Hub
AudioSeal integrates with Hugging Face Hub for model downloads. For gated or private models, you may need to authenticate:audioseal_wm_16bits- Generator with 16-bit message supportaudioseal_detector_16bits- Detector with 16-bit message decodingaudioseal_wm_streaming- Generator with streaming supportaudioseal_detector_streaming- Detector for streaming mode
Troubleshooting
Common Issues
ValueError: not enough values to unpack (expected 3, got 2)
ValueError: not enough values to unpack (expected 3, got 2)
This occurs when the input audio tensor is missing the batch dimension. Add a batch dimension:
ImportError: cannot import name 'AudioSeal'
ImportError: cannot import name 'AudioSeal'
Ensure you’ve installed the correct version and there are no conflicting packages:
CUDA out of memory
CUDA out of memory
Process audio in smaller batches or use CPU:
