|
a |
|
b/README.md |
|
|
1 |
# speaker_recognition_GMM_UBM |
|
|
2 |
A speaker recognition system which uses GMM-UBM for use in an Android application which helps in monitoring patients suffering from Schizophrenia. |
|
|
3 |
|
|
|
4 |
### Installing dependencies |
|
|
5 |
|
|
|
6 |
To install all the dependencies for this project, run the following command, |
|
|
7 |
|
|
|
8 |
``` |
|
|
9 |
pip3 install -r requirements.txt |
|
|
10 |
``` |
|
|
11 |
|
|
|
12 |
### Extracing MFCC from audio |
|
|
13 |
- - - |
|
|
14 |
To extract MFCC coefficients from audio samples, put all the audio files in a seperate folder and run the following command, |
|
|
15 |
``` |
|
|
16 |
python3 src/speaker_recognition/extract_mfcc_coefficients.py |
|
|
17 |
--audio_folder <path to the folder which contains audio> |
|
|
18 |
--csv_file_name <name of the csv file that will be created> |
|
|
19 |
--opt combined |
|
|
20 |
``` |
|
|
21 |
### Creating Universal Background Model |
|
|
22 |
- - - |
|
|
23 |
To run UBM training run the following code, |
|
|
24 |
``` |
|
|
25 |
python3 src/speaker_recognition/speaker_recognition.py |
|
|
26 |
--csv_file <path to MFCC coefficients file> |
|
|
27 |
--operation ubm |
|
|
28 |
``` |
|
|
29 |
### Map adaptation using the created GMM-UBM model |
|
|
30 |
- - - |
|
|
31 |
To run MAP adaptation, |
|
|
32 |
``` |
|
|
33 |
python3 src/speaker_recognition/speaker_recognition.py |
|
|
34 |
--csv_file <path to MFCC coefficients file> |
|
|
35 |
--operation map |
|
|
36 |
--ubm_file <path to the ubm file created after GMM-UBM model creation> |
|
|
37 |
``` |
|
|
38 |
For testing the map adapted model, |
|
|
39 |
``` |
|
|
40 |
python3 src/speaker_recognition/testing_model.py |
|
|
41 |
--map_file_name <path to map adapted .npy file> |
|
|
42 |
--ubm_file_name <path to ubm .npy file> |
|
|
43 |
--test_csv_file <path to the csv file of test speaker> |
|
|
44 |
--N 1500 |
|
|
45 |
``` |