AI audio preparation tools, including audio trimming, duration calculation, and subtitle correction.
Project description
AI 音频预处理工具
功能描述
- 包含常见的AI音频预处理功能,如音频重采样、音频去空白、音频时长获取等。
pip安装
pip install audioprep
获取音频时长
from audioprep import duration
rs = duration.get_audio_duration('test.wav')
print(f"音频时长: {rs}秒")
移除开头和结尾静音
from audioprep import silence
res = silence.trim_silence("530.mp3", "530_after.mp3")
print(res)
移除所有静音
from audioprep import silence
res = silence.remove_long_silence("530.mp3", "530_after.mp3",silence_thresh='-40dB', min_silence_len=3)
print(res)
音频重采样
from audioprep import resample
res = resample.resample_audio("530.mp3", 16000)
print(res)
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
audioprep-1.1.2.tar.gz
(4.1 kB
view details)
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 audioprep-1.1.2.tar.gz.
File metadata
- Download URL: audioprep-1.1.2.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
abd4e6593c68b8df2eaff51fd9ee482e3b25518265016210e9a1962fe39e65a9
|
|
| MD5 |
5bafdb2aa59448fc0a0d11ce93cbe78b
|
|
| BLAKE2b-256 |
70db11b1b6ac84d23afee6010c4228998a2d1f68dfe25d0de6d0dcc0fc77d832
|
File details
Details for the file audioprep-1.1.2-py3-none-any.whl.
File metadata
- Download URL: audioprep-1.1.2-py3-none-any.whl
- Upload date:
- Size: 5.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
067e8a47c4f7a7e73e4dc74781840b91957a9c61ae184e3f96b29c852058eeaf
|
|
| MD5 |
f3fdfdfe39aaad7364fea91c7fd7b013
|
|
| BLAKE2b-256 |
761fc71fd758fdf228d8e47c21443e22569b808b910536b9285b775b251e5c29
|