How to train the spanish model to get text from audio files

649 views
Skip to first unread message

Thor

unread,
Sep 8, 2018, 3:25:54 PM9/8/18
to kaldi-help
Hi,

I want to use Kaldi to get the text of phone calls recorded in audio files (.flac) in spanish language.

I have compiled Kaldi successfully. The yesno example works fine but I can't run successfully the spanish example:

/kaldi/egs/fisher_callhome_spanish/s5$ ./run.sh 

The speech and the data directories need to be named LDC2010S01 and LDC2010T04 respecti
vely

Those directories are links to unexisting paths:

/kaldi/egs/fisher_callhome_spanish/s5/data/local/data/links$ ls -l
total 1
lrwxrwxrwx 1 user user 33 sep  8 21:14 LDC2010S01 -> /veu4/jadrian/data/LDC/LDC2010S01
lrwxrwxrwx 1 user user 33 sep  8 21:14 LDC2010T04 -> /veu4/jadrian/data/LDC/LDC2010T04

These paths don't exist in my system.

I need help to make the example work and once Kaldi it's trained to understand spanish language, I need to know how to input audio files in Kaldi to get the corresponding text.

Thank you!

Daniel Povey

unread,
Sep 8, 2018, 4:03:48 PM9/8/18
to kaldi-help
That data is proprietary; you have to buy it from the LDC (Linguistic Data consortium).


--
Go to http://kaldi-asr.org/forums.html find out how to join
---
You received this message because you are subscribed to the Google Groups "kaldi-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kaldi-help+...@googlegroups.com.
To post to this group, send email to kaldi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kaldi-help/92a8a6d8-d833-4778-baa4-ce565b1b6ad5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Livio Calvo

unread,
Sep 8, 2018, 4:19:10 PM9/8/18
to kaldi...@googlegroups.com
Hi,

It's possible to use Voxforge audio data? 

In any case (Voxforge or LDC), what is the full procedure to import the audio data, train Kaldi and finally input audio files to get the corresponding texts? 

Thank you!



You received this message because you are subscribed to a topic in the Google Groups "kaldi-help" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/kaldi-help/1rQQSAKrWr4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to kaldi-help+...@googlegroups.com.

To post to this group, send email to kaldi...@googlegroups.com.

Daniel Povey

unread,
Sep 8, 2018, 4:34:52 PM9/8/18
to kaldi-help
I don't believe there is a voxforge recipe for spanish.

RE how to decode one file, I believe there was a recent conversation about this (maybe yesterday); I hope someone can share a link to it.


o...@keenresearch.com

unread,
Sep 9, 2018, 1:25:50 AM9/9/18
to kaldi-help
Kaldi is a toolkit that allows you to train acoustic models for ASR; it mostly relies on external tools for language modeling (with some recent additions to the toolkit related to RNN language models). These are all low-level tools (scripts and C++ binaries) that you need to get familiar with if you want to use the toolkit. Kaldi also provides different decoders that you can use for evaluation or, as a starting point for some sort of production ASR system.

You will have to get your hands dirty, so to speak, read and learn a lot; don't expect a quick solution where you can grab a few things and have a final solution in couple of days. If you don't have a solid background in machine learning, Unix, shell scripting/python, C++, and signal processing (listed in the order of important), it will be an uphill battle.

Here is what you could do
1) Review Kaldi documentation
2) Read the HTK Book from Cambridge University to get the general idea on how HMM based ASR systems work
3) Read "Weighted Finite-State Transducers in Speech Recognition"
4) Read about language modeling (ngrams, RNNs, etc.); Google "A bit of progress in Language Modeling"
5) Kaldi comes with a number of recipes (in egs directory), i.e. scripts that take care of acoustic model training. Run a few sample recipes (kaldi for dummies, mini librispeech), and follow the scripts, their outputs, log files, etc. to gain a better understanding of what different tools do. There is quite a bit of overlap between egs (and scripts are structured so that there is not duplication of code); parts that deal with external data, ie. converting data to the format Kaldi expects it to be in will be data source specific... those scripts are typically in subdirectory called local of the specific recipe. You will want to focus on nnet3 type models.
6) When you get stuck go back to documentation, search the forum for answers, and then if you are still stuck ask specific questions on the forum. When asking questions provide sufficient information so that whoever is trying to help you has a full context (what you did, what was the expected outcome, what was the error, log files, any details about mods you made, etc.). It's unlikely somebody on the forum will handhold you through all the steps to train/test your models, especially if your questions make it clear that you did not get familiar with the toolkit from already available resources.

I think it's okay to go through step 5 without covering some of the previous steps (e.g. skipping 3 and 4). But, if you are planning to do anything serious with the toolkit, you should review those papers as well.

I don't know if there are acoustic and language models for Spanish available for download; even if there are, you will most likely need to understand quite a few details about Kaldi before these assets would become useful.

This may be blunt, but I hope it's helpful.

Good luck!

Ogi

Livio Calvo

unread,
Sep 9, 2018, 5:52:43 AM9/9/18
to kaldi...@googlegroups.com
Then probably I will move to another toolkit as I'm working in a project with limited time and we need something working in a few days.

Thank you very much for the answers! :)



Daniel Povey

unread,
Sep 9, 2018, 12:09:12 PM9/9/18
to kaldi-help
If you have only a few days you shouldn't be looking at toolkits at all, you should look into whether Google or IBM or Microsoft have some kind of API that you can use.
Dan


Livio Calvo

unread,
Sep 9, 2018, 3:49:40 PM9/9/18
to kaldi...@googlegroups.com
Yes, Google Cloud works great but it must be 100% offline for legal reasons.

Thank you! :)

Shin XXX

unread,
Sep 9, 2018, 9:01:08 PM9/9/18
to kaldi...@googlegroups.com
Maybe some opensource models? like the aspire chain model  http://kaldi-asr.org/models.html, and this discussion on how to decode one single audio might help

Shin


John Morgan

unread,
Sep 14, 2018, 12:08:29 PM9/14/18
to kaldi...@googlegroups.com
The heroico recipe uses a small corpus of Spanish speech (mostly
read). It can be built from freely available resources.


On 9/9/18, Shin XXX <xiaoy...@gmail.com> wrote:
> Maybe some opensource models? like the aspire chain model
> http://kaldi-asr.org/models.html, and this discussion
> <https://groups.google.com/forum/#!topic/kaldi-help/uQrqIcppZLk> on how to
>>>>>>>>> */kaldi/egs/fisher_callhome_spanish/s5$ ./run.sh *
>>>>>>>>>
>>>>>>>>> *The speech and the data directories need to be named LDC2010S01
>>>>>>>>> and LDC2010T04 respecti*
>>>>>>>>> *vely*
>>>>>>>>>
>>>>>>>>> Those directories are links to unexisting paths:
>>>>>>>>>
>>>>>>>>> */kaldi/egs/fisher_callhome_spanish/s5/data/local/data/links$ ls
>>>>>>>>> -l*
>>>>>>>>> *total 1*
>>>>>>>>> *lrwxrwxrwx 1 user user 33 sep 8 21:14 LDC2010S01 ->
>>>>>>>>> /veu4/jadrian/data/LDC/LDC2010S01*
>>>>>>>>> *lrwxrwxrwx 1 user user 33 sep 8 21:14 LDC2010T04 ->
>>>>>>>>> /veu4/jadrian/data/LDC/LDC2010T04*
>>>>>>>>>
>>>>>>>>> These paths don't exist in my system.
>>>>>>>>>
>>>>>>>>> I need help to make the example work and once Kaldi it's trained
>>>>>>>>> to
>>>>>>>>> understand spanish language, I need to know how to input audio
>>>>>>>>> files in
>>>>>>>>> Kaldi to get the corresponding text.
>>>>>>>>>
>>>>>>>>> Thank you!
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Go to http://kaldi-asr.org/forums.html find out how to join
>>>>>>>>> ---
>>>>>>>>> You received this message because you are subscribed to the Google
>>>>>>>>> Groups "kaldi-help" group.
>>>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>>>> send an email to kaldi-help+...@googlegroups.com.
>>>>>>>>> To post to this group, send email to kaldi...@googlegroups.com.
>>>>>>>>> To view this discussion on the web visit
>>>>>>>>> https://groups.google.com/d/msgid/kaldi-help/92a8a6d8-d833-4778-baa4-ce565b1b6ad5%40googlegroups.com
>>>>>>>>> <https://groups.google.com/d/msgid/kaldi-help/92a8a6d8-d833-4778-baa4-ce565b1b6ad5%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>>>>>> .
>>>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>>>
>>>>>>>> --
>>>>>>>> Go to http://kaldi-asr.org/forums.html find out how to join
>>>>>>>> ---
>>>>>>>> You received this message because you are subscribed to a topic in
>>>>>>>> the Google Groups "kaldi-help" group.
>>>>>>>> To unsubscribe from this topic, visit
>>>>>>>> https://groups.google.com/d/topic/kaldi-help/1rQQSAKrWr4/unsubscribe
>>>>>>>> .
>>>>>>>> To unsubscribe from this group and all its topics, send an email to
>>>>>>>> kaldi-help+...@googlegroups.com.
>>>>>>>> To post to this group, send email to kaldi...@googlegroups.com.
>>>>>>>> To view this discussion on the web visit
>>>>>>>> https://groups.google.com/d/msgid/kaldi-help/CAEWAuyTfTs53wO5v2xJcSgrMVZ45jQWG5qtbiaMSbJ9VO_%3D-3w%40mail.gmail.com
>>>>>>>> <https://groups.google.com/d/msgid/kaldi-help/CAEWAuyTfTs53wO5v2xJcSgrMVZ45jQWG5qtbiaMSbJ9VO_%3D-3w%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>>>>>> .
>>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>>
>>>>>>> --
>>>>>>> Go to http://kaldi-asr.org/forums.html find out how to join
>>>>>>> ---
>>>>>>> You received this message because you are subscribed to the Google
>>>>>>> Groups "kaldi-help" group.
>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>> send an email to kaldi-help+...@googlegroups.com.
>>>>>>> To post to this group, send email to kaldi...@googlegroups.com.
>>>>>>> To view this discussion on the web visit
>>>>>>> https://groups.google.com/d/msgid/kaldi-help/CAMVjAiwwj%3D%2BGkFG9UNs6WKW50PDptb4FjK%2BOsrDchB2GGNrkEQ%40mail.gmail.com
>>>>>>> <https://groups.google.com/d/msgid/kaldi-help/CAMVjAiwwj%3D%2BGkFG9UNs6WKW50PDptb4FjK%2BOsrDchB2GGNrkEQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>>>>> .
>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>
>>>>>> --
>>>>> Go to http://kaldi-asr.org/forums.html find out how to join
>>>>> ---
>>>>> You received this message because you are subscribed to a topic in the
>>>>> Google Groups "kaldi-help" group.
>>>>> To unsubscribe from this topic, visit
>>>>> https://groups.google.com/d/topic/kaldi-help/1rQQSAKrWr4/unsubscribe.
>>>>> To unsubscribe from this group and all its topics, send an email to
>>>>> kaldi-help+...@googlegroups.com.
>>>>> To post to this group, send email to kaldi...@googlegroups.com.
>>>>> To view this discussion on the web visit
>>>>> https://groups.google.com/d/msgid/kaldi-help/3dec6a97-1b94-40de-9508-ece4a18b4b59%40googlegroups.com
>>>>> <https://groups.google.com/d/msgid/kaldi-help/3dec6a97-1b94-40de-9508-ece4a18b4b59%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>> .
>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>
>>>> --
>>>> Go to http://kaldi-asr.org/forums.html find out how to join
>>>> ---
>>>> You received this message because you are subscribed to the Google
>>>> Groups "kaldi-help" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to kaldi-help+...@googlegroups.com.
>>>> To post to this group, send email to kaldi...@googlegroups.com.
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/kaldi-help/CAMVjAizWVx%3D3jjiw%2BiYzsZYuGTy0HthMQTTO%2Bsp-kQNxTYegQA%40mail.gmail.com
>>>> <https://groups.google.com/d/msgid/kaldi-help/CAMVjAizWVx%3D3jjiw%2BiYzsZYuGTy0HthMQTTO%2Bsp-kQNxTYegQA%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>> .
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>> --
>>> Go to http://kaldi-asr.org/forums.html find out how to join
>>> ---
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "kaldi-help" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/kaldi-help/1rQQSAKrWr4/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to
>>> kaldi-help+...@googlegroups.com.
>>> To post to this group, send email to kaldi...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/kaldi-help/CAEWAuyQO3Ddg232JgkR8MO%3DpShT%3Dh50e0y4um2XFxNZCWX%3DZJg%40mail.gmail.com
>>> <https://groups.google.com/d/msgid/kaldi-help/CAEWAuyQO3Ddg232JgkR8MO%3DpShT%3Dh50e0y4um2XFxNZCWX%3DZJg%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
>> Go to http://kaldi-asr.org/forums.html find out how to join
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "kaldi-help" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to kaldi-help+...@googlegroups.com.
>> To post to this group, send email to kaldi...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/kaldi-help/CAMVjAix-4AadBR_r-LUNRfP6hQPiHXRCp2dCXP2j1p7jAnDNvQ%40mail.gmail.com
>> <https://groups.google.com/d/msgid/kaldi-help/CAMVjAix-4AadBR_r-LUNRfP6hQPiHXRCp2dCXP2j1p7jAnDNvQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> Go to http://kaldi-asr.org/forums.html find out how to join
> ---
> You received this message because you are subscribed to the Google Groups
> "kaldi-help" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to kaldi-help+...@googlegroups.com.
> To post to this group, send email to kaldi...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/kaldi-help/CADtO4NX3-m5_344AsPuk26-MO7M6p%3D10YrYgH%3DmAETK%3DfR6pdw%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages