speaker-verification-toolkit
This module contains some tools to make a simple speaker verification.
You can download it with PyPI:
$ pip install speaker-verification-toolkit
To import and use in your own projects:
import speaker_verification_toolkit.tools as svt
# svt.some_function(...)
Usage
find_nearest_voice_data(voice_data_list, voice_sample)
Find the nearest voice data based on this voice sample. Could be used to make the naive Accept/Reject decision.
voice_data_list: a list containing all voices data from the dataset.
voice_sample: the voice sample reference.
returns: the index of the element from voice_data_list that represents the nearest voice data.
compute_distance(sample1, sample3)
Compute the distance between sample1 and sample2 using O(n) DTW algorithm
sample1: the mfcc data extracted from the audio signal 1.
sample2: the mfcc data extracted from the audio signal 2.
returns: Float number representing the minimum distance between sample1 and sample2.
extract_mfcc(signal_data, samplerate=16000, winlen=0.025, winstep=0.01)
Compute MFCC features from an audio signal
signal: the audio signal from which to compute features. Should be an N*1 array.
samplerate: the sample rate of the signal we are working with, in Hz.
winlen: the length of the analysis window in seconds. Default is 0.025s (25 milliseconds).
winstep: the step between successive windows in seconds. Default is 0.01s (10 milliseconds).
returns: A numpy array of size (NUMFRAMES by numcep) containing features. Each row holds 1 feature vector.
extract_mfcc_from_wav_file(path, samplerate=16000, winlen=0.025, winstep=0.01)
Compute MFCC features from a wav file
path: the wav file path to be open.
samplerate: the wanted sample rate, in Hz. Default is 16000. If you want no resampling fill this argument with None.
winlen: the length of the analysis window in seconds. Default is 0.025s (25 milliseconds).
winstep: the step between successive windows in seconds. Default is 0.01s (10 milliseconds).
returns: A numpy array of size (NUMFRAMES by numcep) containing features. Each row holds 1 feature vector.
rms_silence_filter(data, samplerate=16000, segment_length=None, threshold=0.001135)
Cut off silence parts from the signal audio data. Doesn't work with signals data affected by environment noise. You would consider apply a noise filter before using this silence filter or make sure that environment noise is small enough to be considered as silence.
data: the audio signal data
samplerate: if no segment_length is given, segment_length will be equals samplerate/100 (around 0.01 secs per segment).
segment_length: the number of frames per segment. I.e. for a sample rate SR, a segment length equals SR/100 will represent a chunk containing 0.01 seconds of audio.
threshold: the threshold value. Values less than or equal values will be cut off. The default value was defined at [1] (see the references).
returns: the param "data" without silence parts.
References
[1] - Muhammad Asadullah & Shibli Nisar, "A SILENCE REMOVAL AND ENDPOINT DETECTION APPROACH FOR SPEECH PROCESSING", National University of Computer and Emerging Sciences, Peshawar
Metadata
Release files for speaker-verification-toolkit 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| speaker_verification_toolkit-0.0.2.tar.gz | 3.4 kB | Without provenance | Details for speaker_verification_toolkit-0.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| speaker_verification_toolkit-0.0.2-py3-none-any.whl | Python 3 | none | any | Details for speaker_verification_toolkit-0.0.2-py3-none-any.whl |
Total release size: 8.9 kB
Release files / speaker_verification_toolkit-0.0.2.tar.gz
| Download URL | speaker_verification_toolkit-0.0.2.tar.gz |
|---|---|
| Size | 3.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
32a65774fc6e8e742b0e9ed8e1e377b02eb2954e43f03992f22f7d3360119739
|
|
BLAKE2b-256 checksum How to use checksums |
55996f93a1e70b8952051baecbf21b4802fda8f2ea8895a4156cc2a21fd1f77c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.6.8
|
Release files / speaker_verification_toolkit-0.0.2-py3-none-any.whl
| Download URL | speaker_verification_toolkit-0.0.2-py3-none-any.whl |
|---|---|
| Size | 5.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1ef43e92fdd300944f5731f31f26c064951c11c231b01e35ad6511e5c069e991
|
|
BLAKE2b-256 checksum How to use checksums |
e8f899e760be56483ea141ad70eb0ad8e61fe6764b54ab44f49ae683e3ef2450
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.6.8
|
Security for speaker-verification-toolkit 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.