SNDFILE.IO
A simple module providing a unified API to read and write sound-files to and from numpy arrays. If no extra modules are installed, it uses only standard modules and numpy to read and write uncompressed formats (WAV, AIFF).
If other modules are installed (scikits.audiolab, for example), then they are used.
Even without third-party packages, it has certain advantages over the built-in modules wave and aifc
support for PCM16, PCM24, PCM32 and FLOAT32
unified output format, independent of encoding (always float64)
unified API for all backends
API
sndread
it will read ALL the samples and return a Sample (a tuplet data, samplerate)
Data will always be as a numpy.float64, between -1 and 1, independently of bit-rate
sndread_chunked
will read chunks of frames, avoiding the allocation of all the samples in memory
sndinfo
return SndInfo, a namedtuple with all the information of the sound-file
sndwrite
write the samples.
samples need to be a numpy.float64 array with data between -1 and 1
sndwrite_chunked
allows you to write to the file as samples become available
Dependencies
- Mandatory:
numpy
- Optional:
scikits.audiolab
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sndfileio-0.7.1.tar.gz.
File metadata
- Download URL: sndfileio-0.7.1.tar.gz
- Upload date:
- Size: 10.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8ff3d7be243693c8faf537f9e46fe85f7c97dde1bd8812f8ade44e5751825390
|
|
| MD5 |
85376dfb87a2ebfc0d8278f5b641016e
|
|
| BLAKE2b-256 |
10a5b73fbef06657f54b17373972ee4037fae1e1a110ad3d047ebd03c4878da9
|
File details
Details for the file sndfileio-0.7.1.macosx-10.6-intel.exe.
File metadata
- Download URL: sndfileio-0.7.1.macosx-10.6-intel.exe
- Upload date:
- Size: 74.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ff167ee5e8316025e660a0108507839106cb55ec0558aa323e066c1f2b862118
|
|
| MD5 |
1fa3cfde1cc6170de41052a7dc7517c9
|
|
| BLAKE2b-256 |
12f1d7929e4395456a1b9099581b273157dae574d8b344c448a15ba5c803529e
|