Xlights with other Papagayo language (Dutch)?

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
Hi there, I have been using Xlights for 3 years now.

Youtube Channel:
Christmas Lights Zwolle
@erikjanwind

At the moment I only do English songs because of the language restriction. Does anybody know how to make papagayo within Xlights compatible with Dutch or other languages? I have tried some googling the past years but only could come up with https://github.com/smeighan/xLights/issues/2469 And I dont understand it. Many thanks in advance!
 

keithsw1111

Senior elf
Joined
Oct 11, 2012
Messages
936
Location
Kellyville, NSW
Essentially you need a dictionary of words to phonemes. Xlights uses the Carnegie Mellon University model. If you can find something equivalent then it could be added.
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
Ok, thank you for your reply. Unfortunately at the moment I cannot find any. Any pointers what type of file that I am looking for? And how to add them to xlights in order to switch dictionaries? Many thanks
 

merryoncherry

Senior elf
Joined
Apr 2, 2022
Messages
639
Location
Cherry St., Hudson MA USA
You're looking for a file with word followed by phonetics, one word per line, like:
CHRISTMAS K R IH1 S M AH0 S

If you look in your xLights program folder, you can find the standard_dictionary, extended_dictionary, german_dictionary, etc.

So, as far as leads for a dictionary, I don't have any, but some people believe a simple spelling-based pronunciation is good enough to be useful and attempted it:
And more recently:

Maybe you could run an extensive word list through that kind of code, and thereby obtain a dictionary for xLights.
Or, there could be an attempt to replicate the python logic into the xLights implemementation also... the logic is just a few hundred lines of GPL'd code.
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
You're looking for a file with word followed by phonetics, one word per line, like:
CHRISTMAS K R IH1 S M AH0 S

If you look in your xLights program folder, you can find the standard_dictionary, extended_dictionary, german_dictionary, etc.

So, as far as leads for a dictionary, I don't have any, but some people believe a simple spelling-based pronunciation is good enough to be useful and attempted it:
And more recently:

Maybe you could run an extensive word list through that kind of code, and thereby obtain a dictionary for xLights.
Or, there could be an attempt to replicate the python logic into the xLights implemementation also... the logic is just a few hundred lines of GPL'd code.
Thanks for your reply, I will look into it, and say if I have the file, I simply place it in the right folder and somehow select it in Xlights?
 

merryoncherry

Senior elf
Joined
Apr 2, 2022
Messages
639
Location
Cherry St., Hudson MA USA
It doesn't seem that xLights allows you to select it; you could overwrite the standard, extended, and/or user dictionary files; it loads them in that order so that user dictionary overrides everything else.

If the phonemes in the dictionary don't match what xLights expects, that also can be adjusted by looking in the phoneme_mapping file and adding missing phonemes.

If you want to improve xLights in this regard I can probably give guidance, but the only language well enough to add programatically is Spanish, which isn't the one you want.
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
It doesn't seem that xLights allows you to select it; you could overwrite the standard, extended, and/or user dictionary files; it loads them in that order so that user dictionary overrides everything else.

If the phonemes in the dictionary don't match what xLights expects, that also can be adjusted by looking in the phoneme_mapping file and adding missing phonemes.

If you want to improve xLights in this regard I can probably give guidance, but the only language well enough to add programatically is Spanish, which isn't the one you want.
Ok, thanks for the info. I got a dict file with the following structure:

aanbakken /'a?m.b?.k?/
aanbaksel /'a?m.b?k.s?l/
aanbeeld /'a?m.be?lt/

I will try to check if I can replace the phoneme writings to the one I found in the standard dictionairy. And I will try and continue to look for more info/dictionaries.

Another that I found has the following structure:

a-benadering a b @ n a d @ r ii nn
a-beta a b @ t a
a-beurzen a b eu r z @ n
a-bewoner a b @ w o n @ r
a-bijbels a b ei b @ l s
a-bijwerkingen a b ei w ee r k ii nn @ n

I will just continue to look, or try to alter the ones I have found in order to check what I hacve to change in order to make it work. (together with your info)

Thanks
 

merryoncherry

Senior elf
Joined
Apr 2, 2022
Messages
639
Location
Cherry St., Hudson MA USA
I think that second dictionary will work well.

I took off the a- prefixes and uppercased it, appended the result to the user_dictionary and added a few phones to phoneme_mapping and was able to get it to work on the test words. A slightly better way would be to postprocess that dictionary to replace the phones with CMU phones, just search and replace really...
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
I think that second dictionary will work well.

I took off the a- prefixes and uppercased it, appended the result to the user_dictionary and added a few phones to phoneme_mapping and was able to get it to work on the test words. A slightly better way would be to postprocess that dictionary to replace the phones with CMU phones, just search and replace really...
Thanks I will try to do that!
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
It doesn't seem that xLights allows you to select it; you could overwrite the standard, extended, and/or user dictionary files; it loads them in that order so that user dictionary overrides everything else.

If the phonemes in the dictionary don't match what xLights expects, that also can be adjusted by looking in the phoneme_mapping file and adding missing phonemes.

If you want to improve xLights in this regard I can probably give guidance, but the only language well enough to add programatically is Spanish, which isn't the one you want.
Goodday, thanks for your reply, I was just checking it, but I do not fully understand it. At the moment I have a library in my user_dictionary that look that this:
ONTFATSOENLIJK OO N T F AA T S U N L @ K
ONTFATSOENLIJKS OO N T F AA T S U N L @ K S
ONTFEMD OO N T F E M T

(Dutch word followed by the given breakdown)

If I check the phoneme_mapping file, I added below some new mapping (I believe, i do not understand the logic) as follows:
OO O
E E
@ E
B MBP
M MBP
P MBP
V FV
R U
D etc

I was hoping that Xlights uses the (Dutch) user_dictionary for the words/breakdowns, and maps it to the proper mouthshap via the phoneme_mapping addition. But I cannot get it to work. Could you please explain the proces/logic that Xlights/Papagayo uses? Thanks in advance!
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
Goodday, Do you mean this:
1704355492172.png

1704355694384.png

When the Lyrics are in Dutch, most of the words are not recognized.

Thanks,

Erik-Jan
 

merryoncherry

Senior elf
Joined
Apr 2, 2022
Messages
639
Location
Cherry St., Hudson MA USA
Ok, so I don't think it is our understanding that is wrong. Maybe start with a simple setup that works and expand it a little at a time. I did add one word (ONTFEMD), added 2 phones ("OO" and "E"), and it worked for me:
1704369926765.png

So, try that and make sure it's working... then we can go on to find out where it stops working. Gotta say use of "@" as a phone has my suspicions raised, but it could be anything.
 

ejwind

New elf
Joined
Nov 4, 2021
Messages
11
Goodday,

Thank you for your reply, I saw what I did wrong with the files. They are in the folder: C:\Program Files\xLights. If I open it with wordpad or another program, I cannot save it without the extension .txt. So I copied them on the desktop, changed in the files Phoneme_mapping and User_dictionary en pasted them to the above path. Now the Dutch words are recognized by Xlights.

1704378878341.png

Not all phonemes are correct, but at least I am on the right path. I will check and update the mapping. If I'm (more or less) done, I will provide an update. Thanks for the provided support!
 
Top