Skip to main content

Audio Analysis Library

This library provides a set of tools for audio analysis, similar to librosa. It includes functionalities for audio file I/O, spectral representations, audio feature extraction, and basic audio effects.

Installation

To install the library, run the following command:

pip install audio_analysis_lib

Usage

Here are some basic examples of how to use the library:

Reading and Writing Audio

from audio_analysis.io import read_audio, write_audio

# Read an audio file
audio_data, sample_rate = read_audio('path/to/your/audio.wav')

# Write audio data to a file
write_audio(audio_data, sample_rate, 'path/to/output/audio.wav')

Spectral Representations

from audio_analysis.spectral import calculate_stft, calculate_istft

# Compute the Short-Time Fourier Transform
frequencies, times, stft_matrix = calculate_stft(audio_data, sample_rate)

# Inverse Short-Time Fourier Transform to reconstruct the audio signal
audio_data_reconstructed = calculate_istft(stft_matrix, sample_rate)

Feature Extraction

from audio_analysis.features import mfcc

# Compute Mel-frequency cepstral coefficients
mfcc_features = mfcc(audio_data, sample_rate)

Audio Effects

from audio_analysis.effects import change_pitch, time_stretch

# Change the pitch of the audio signal
pitch_shifted_audio = change_pitch(audio_data, sample_rate, semitone_shift=2)

# Stretch the time of the audio signal
stretched_audio = time_stretch(audio_data, stretch_factor=1.5)

For more detailed documentation and advanced usage, please refer to the individual module docstrings within the library.

Release files for audio-analysis-lib 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for audio-analysis-lib 0.1.1
File Interpreter ABI Platform
audio_analysis_lib-0.1.1-py3-none-any.whl Python 3 none any Details

Release files / audio_analysis_lib-0.1.1-py3-none-any.whl

Download URL audio_analysis_lib-0.1.1-py3-none-any.whl
Size 2.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f53c143eaa75b2cf3cea002e07413776fd7fc672df25c6a65818a7a6c0a28872
BLAKE2b-256 checksum
How to use checksums
290b0f0419bfdc9981cd7dc3b5130498e08adec3b66b4b518c56dfa6d08b727b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.31.0 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12

Release history Release notifications | RSS feed

This release

0.1.1 This release

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page