__construct()
__construct(string $user)
Creates a SpeakerRecognitionPackage for a user ID given
Parameters
string | $user | User id. If it's a number, it will be converted to a string. |
Speaker recognition independant package interface. BVW API will call this methods to provice third parties with a simple way to enroll and test user's identity.
isEnrolled() : bool
Test if a user is enrolled in a speaker recognition system.
A user being enrolled means there is information about him (data structures, files, database entries, ...) that can be used to compare him to another user.
true if $user is enrolled, false if not.
enroll(string $audio_file_path) : bool
Create necessary initial information (data structures, files, database entries, .
..) to allow testing the identity of a user against another based on the audio features of his voice.
string | $audio_file_path | Path to audio file with a sample voice of the subject $user. |
true if enrollment was succesful, false if not.
testSpeakerIdentity(string $audio_file_path) : float
Checks if the audio file located in $audio_file_path belongs to $user's voice.
$user should be already erolled in the speaker recognition system in order to test his identity
string | $audio_file_path | Path to audio file with a sample voice to test
|
The value resulting for the speaker verification process.