PDA

View Full Version : [REL] SH3VoiceCommand v1.0 Official Release


shadow_wxh
09-08-24, 01:58 PM
====================== SH3VoiceCommand v1.0 Official Release ======================

https://www.subsim.com/radioroom/attachment.php?attachmentid=6065&stc=1&d=1725829644
After nearly six months development and much time preparation in advance. I am proudly announcing that SH3VoiceCommand v1.0 is officially released.

SH3VoiceCommand is a speech to command interface dedicated to support Silent Hunter game series. It uses state of the art AI speech recognition engine and offers a much greater complexity and functionality which surpass its' predecessor and peers.

It offers these following features:

🎈 Lightweight : Only adds about 20MB RAM in the 32bit section.
📣Responsive : The command delay can be as low as 500MS with proper setup & optimization.
👶Independent: No dependency on any third-party software or MOD (except the OS and graphic card packages).
🎮Integrated : Completely merged with sh3.exe running on parallel thread which has no interference with users' keyboard & mouse inputs
🔠Multilingual : Supports 99 languages (current only configured for English and German, finetuned for German).
💡 Awareness : Aware of players' current coordinates heading speed and depth etc., and act accordingly.
🔢Numeracy : It can interpret any number from 0 to 1,999,999.99 in English and German
🎓Intelligence : Able to comprehend basic arithmetic symbols and operators like + - * / sin() cos() tan() pi and e in the configuration.
🤨Tolerable : Allows small deviation from standard command phrase to achieve higher catch rate
📎 Flexible : User can add, remove, change any voice command as they like in the config file
🤗Trainable : The language models can be finetuned to improve accuracy and adjust to personal accent



Disclaimer:

This MOD is under CC BY-NC-SA license which it under the following terms:
👨‍💻Attribution — You must give appropriate credit , provide a link to the license, and indicate if changes were made . You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use. You may publish a modified version of this MOD however it must bear a different name e.g. you shall not publish "SH#VoiceCommand v2.0". (note)
⛔NonCommercial — You may not use the material for commercial purposes . You may not list this material on any paid to download website.
👨🏻‍🤝‍👨🏻ShareAlike — If you remix, transform, or build upon the material, you must distribute your contributions under the same license as the original. Any application derived from or incorporating this material must also be free.
(note) # stands for any number between 0~9 currently targeting to support 3, 4 and 5


Minimum System Requirements:
Operation System: Windows10 64bit
RAM: 12GB
Graphic Card: Nvidia Graphic Card with CUDA 6.1
VRAM: 4GB
Sound Card: Any sound card with microphone input


To install the MOD to your SH3 simply download the RARs in the download links in the bottom section of this post, read through user manual section one to seven and follow the instructions.

Some of the In-Game Screenshots
https://www.subsim.com/radioroom/attachment.php?attachmentid=6061&stc=1&d=1725829081
https://www.subsim.com/radioroom/attachment.php?attachmentid=6062&stc=1&d=1725829194

Backend Service and Logs
https://www.subsim.com/radioroom/attachment.php?attachmentid=6063&stc=1&d=1725829297
https://www.subsim.com/radioroom/attachment.php?attachmentid=6064&stc=1&d=1725829297

System Architecture
https://www.subsim.com/radioroom/attachment.php?attachmentid=6066&stc=1&d=1725834513

Known Issues:
Everyone has unique voice characteristics. It is likely each individual player needs to construct their own version config and language models. This may require a lot of time and dedication.
Due to decimal rounding and ocean current flow the confirmed command from the crew and actual command from user may have ±1 difference.
Depending on the user's graphic card performance and 3D workload the respond from transcriber can be slow. If this happens, switching on a live streaming application or a screen recording application can greatly improves the processing speed.
Upon exiting the game you might encounter invalid memory access error, e.g. exception on 0x5D9104F9 (C0000005, EXCEPTION_ACCESS_VIOLATION), this is caused by SDL2.dll not being unloaded in the correct sequence. Simply ignore this warning because the game process has been terminated anyway.
(Personally, I am not very satisfied with the workaround fix above but in current conditions it is the easiest way without changing sh3.exe itself. If you have any recommendations, please contact me through subsim messages, any help is appreciated)
If game crashed while using SH3VoiceCommand the share memory might be leaked and can't be retrieved again. The transcriber will indicate "Share Memory NOT Ready" and exit after several attempts. You might need to restart windows in order to load SH3VoiceCommand again.
Some of the command phrases may not be very accurate, have grammar mistakes or even missing. If you have any recommendations, please feel free to leave a comment under the publication page of SH3VoiceCommand on subsim. Also state your reference regarding where is your source of information.

References & Credits
https://openai.com/index/whisper/
Main web page of OpenAI Whisper
https://github.com/ggerganov/whisper.cpp/
Open-source C++ version of Whisper
https://cdn.openai.com/papers/whisper.pdf
Research paper of Whisper
https://huggingface.co/blog/fine-tune-whisper
Detailed guide on how to fine tune Whisper by Sanchit Gandhi
https://huggingface.co/datasets/mozilla-foundation/common_voice_11_0
Mozilla Common Voice 11.0 dataset
https://huggingface.co/bofenghuang/whisper-medium-cv11-german
Bofenghuang's model after training with Mozilla Common Voice 11.0
https://huggingface.co/datasets/shadow-wxh/VoiceCommandAudio
shadow_wxh's dataset on fine tuning SH#VoiceCommand
https://huggingface.co/shadow-wxh/voicecommand-german-medium
shadow_wxh's model after fine tuning with VoiceCommandAudio
https://maritime.org/doc/subphrase/
Some of the English command phrases are referenced from this document
https://translate.google.com/?sl=en&tl=de&op=translate
Some of the German command phrases are translated using google translate
https://www.subsim.com/radioroom/showthread.php?t=215433
The menu config file is derived from Ahnenerbe WideGui
https://www.subsim.com/radioroom/showthread.php?t=132228&highlight=sh3speech
Some of the command phrases are inherited from SH3Speech
Das Boot -Filmed by Wolfgang Petersen 1981
Some of German command phrases and taken from this film
https://lostsouthpacificadventures.blogspot.com/2014/09/15000-miles-from-past-3.html
Photo of U-Boat speaking tubes
https://www.flickr.com/photos/lensjoy/21528336803/
Speaking tubes onboard ORP Błyskawica taken by Marcin Bieszczanin. The voice pipe icon is edited from this.
Photos of speaking tubes on board U-995 taken by Toyotagt86.
This is used as publication front page photo
https://store.ubisoft.com/us/silent-hunter-3/5704fac788a7e32b078b4692.html?lang=en_US
Last but not least the original Silent Hunter III developed/published by Ubisoft January 2005

🙏Special thanks to Marcin Bieszczanin and Toyotagt86 for permission to use their excellent photographs on board ORP Błyskawica and U955🙏

OneDrive Download Links:
SH3VoiceCommand.part1.rar https://1drv.ms/u/s!AsHzobklG8RTjVomZiq-FdYJL8jI?e=qiswuQ
SH3VoiceCommand.part2.rar https://1drv.ms/u/s!AsHzobklG8RTjVwa6wOPPZax8LC3?e=nFJgrZ
SH3VoiceCommand.part3.rar https://1drv.ms/u/s!AsHzobklG8RTjVvfPSNcULM3FAiW?e=bBJYWc
SH3VoiceCommand.part4.rar https://1drv.ms/u/s!AsHzobklG8RTjVkKbBVpDopIJYzu?e=Xdumcm
SH3VoiceCommandHotFix.rar https://1drv.ms/u/s!AsHzobklG8RTjV_b0L0xulA3v-5r?e=USCX3M

FTP Download Links: (Limited Time & Connection Only, IP Address Subjected to Change)
SH3VoiceCommand.part1.rar ftp://Anonymous@123.191.118.202/SH3VoiceCommand.part1.rar
SH3VoiceCommand.part2.rar ftp://Anonymous@123.191.118.202/SH3VoiceCommand.part2.rar
SH3VoiceCommand.part3.rar ftp://Anonymous@123.191.118.202/SH3VoiceCommand.part3.rar
SH3VoiceCommand.part4.rar ftp://Anonymous@123.191.118.202/SH3VoiceCommand.part4.rar
SH3VoiceCommand.part5.rar ftp://Anonymous@123.191.118.202/SH3VoiceCommand.part5.rar

Aktungbby
09-08-24, 02:37 PM
shadow_wxh!:Kaleun_Salute:

Anvar1061
09-09-24, 12:49 AM
https://www.subsim.com/radioroom/images/smilies/Kaleun_Thumbs_Up-1.gifhttps://www.subsim.com/radioroom/images/smilies/Kaleun_Applaud-1.gifhttps://www.subsim.com/radioroom/images/smilies/Kaleun_Cheers-1.gif

rik007
09-09-24, 01:18 PM
I'm a big fan of voice command so I will give it a try. :) The ftp links give a blanc screen but the OneDrive downloads worked perfectly!

Nice documentation! Beautiful that numbers are supported.

Thank you very much for your huge effort

:Kaleun_Applaud:

Do we really need the full CUDA Toolkit? It weighs a whopping 3 GB.... I see it look for:

Cudart64_12.dll
Cublas64_12.dll

Not sure it needs more of course....

shadow_wxh
09-10-24, 08:11 AM
Apologize guys missing files are now added, the downloads has became 5 parts. The CUDA DLLs are now included. The alternative is to install NVIDIA GPU Computing Toolkit but that is to large and only needed by developers.

rik007
09-10-24, 01:09 PM
Thank you very much! Great you included the VoicePipe tga's as well. Now I see the VoicePipes and once I activated them (gold color) I voiced a German command - default I see - it sometimes turns red and sometimes nothing happens. What could that be? The log file does not show any error.

shadow_wxh
09-10-24, 01:32 PM
Thank you very much! Great you included the VoicePipe tga's as well. Now I see the VoicePipes and once I activated them (gold color) I voiced a German command - default I see - it sometimes turns red and sometimes nothing happens. What could that be? The log file does not show any error.

Did the transcriber start properly. What is the specs of your graphic card?

rik007
09-10-24, 02:46 PM
It's a NVIDIA Geforce RTX 3060. I'm running W10 64bit.

It's a good point you mention because I notice that when sh3.exe has started the transcriber is started in the background. Once I start a mission it vanishes. I cannot see it in the process manager of W10 anymore.

If I then start it manually it give "Unknown exception share memory"

If I start it manually as administrator it starts and waits for input. If I switch back to sh3 and voice a command I see an error in the transcriber. Unfortunately it closes so quickly that I cannot read it :doh:

John Pancoast
09-10-24, 04:42 PM
Impressive work. Fwiw voice commands can also be done via Voice Attack. Much easier to use, setup, and install.
I have no connection but use it for various games.

shadow_wxh
09-10-24, 05:35 PM
It's a NVIDIA Geforce RTX 3060. I'm running W10 64bit.

It's a good point you mention because I notice that when sh3.exe has started the transcriber is started in the background. Once I start a mission it vanishes. I cannot see it in the process manager of W10 anymore.

If I then start it manually it give "Unknown exception share memory"

If I start it manually as administrator it starts and waits for input. If I switch back to sh3 and voice a command I see an error in the transcriber. Unfortunately it closes so quickly that I cannot read it :doh:

Check the known issue section in the user manual see if that helps.

rik007
09-10-24, 11:15 PM
I did... So what...? Can you be more specific?

shadow_wxh
09-11-24, 12:42 AM
I did... So what...? Can you be more specific?

1. You need at least 4GB graphic memory.
2. Set VoiceTranscriber.exe to high priority in the windows graphic settings.
3. Set SavAudio = TURE see if your voice can be captured with good quality.
4. See if VoiceTranscriber.exe has been started successfully if showing "Share Memory NOT Ready" reboot your computer. (real power off hard reboot to prevent memory not being cleared totally)
5. Turn on GeForce Experience screen recorder while in-game default is Alt+F9.
6. Try some of the command phrases while in game, if not catching check the log and console see what message displays.

rik007
09-11-24, 10:33 AM
Thank you for providing the extra info :Kaleun_Thumbs_Up:

Mister_M
09-11-24, 01:38 PM
Hello.

This work looks interesting. Voice command is probably a great addition to the game.

It would be amazing to be able to make the TDC calibration only by voice, as it was done in reality, so you can keep your eye on the periscope. But I guess it's not possible unfortunately?

shadow_wxh
09-11-24, 03:09 PM
Hello.

This work looks interesting. Voice command is probably a great addition to the game.

It would be amazing to be able to make the TDC calibration only by voice, as it was done in reality, so you can keep your eye on the periscope. But I guess it's not possible unfortunately?

It is possible now.........:up:

Mister_M
09-12-24, 06:30 AM
It is possible now.........:up:

Incredible! :Kaleun_Thumbs_Up:
Too bad I'm not under Win 10.

Tabris
09-12-24, 05:16 PM
looking forward to trying this. Voice Attack has been a great program for me, I've used it for over a year. You can use it to make speed/rudder/depth commands using mouse coordinates, but I've always lamented that I can't give heading commands with it. and you're saying this can be used for TDC settings as well? yes please. thanks for your hard work.

rik007
09-14-24, 01:19 AM
Great catch by the way theat you found the addresses of the key commands and values. We might exploit that for other improvements :up:

shadow_wxh
09-14-24, 04:15 AM
This is guaranteed one of the must have MOD for Silent Hunter game series. You will be surprised on how much it is capable of doing.😉

sh.kaleu
09-15-24, 01:59 AM
Seems to be a fantastic mod?

Gonna get an old Win10 workstation soon to replace my desktop, SH3 will be a MUST installation now after I didn't play it for years...

One question though!
How has used it so far?
Is there a YT Video showing, that it is working.
Did someone run through some anti-virus, malware software?

IS IT SAFE?!?!?!

Nothing against you @shadow_wxh, but first upload being such a banger...
"Only" 149 posts...

The Windows Defender in my brain changes do orange XD
I really, really hope & wish that I am too cautious here...
So pls forgive me @shadow_wxh

But better safe than sorry.

Aktungbby
09-15-24, 03:41 PM
sh.kaleu!:Kaleun_Salute:...after 11-years' 'silent running'!:up:

sh.kaleu
09-16-24, 12:22 PM
Can't believe it myself, now that I see it aswell... XD

Well here I am XD
Running on Diesel and AIP...:yeah:

John Pancoast
09-22-24, 08:56 PM
looking forward to trying this. Voice Attack has been a great program for me, I've used it for over a year. You can use it to make speed/rudder/depth commands using mouse coordinates, but I've always lamented that I can't give heading commands with it. and you're saying this can be used for TDC settings as well? yes please. thanks for your hard work.


You can give heading commands with VA, also with the mouse function

shadow_wxh
09-22-24, 09:55 PM
You can give heading commands with VA, also with the mouse function

There wont be the need to create a new MOD if Voice Attack can do what this MOD can do, you have to try to tell the differences.

Tabris
09-23-24, 12:02 PM
You can give heading commands with VA, also with the mouse function

How? If the clickable compass moves as the boat turns, how can we use pre-programmed mouse coordinates to give those orders? I figure this mod must be doing something very different, but I haven't been able to test it yet and perhaps I'm just not enough of a VA power-user.

- Tabris

John Pancoast
09-23-24, 05:50 PM
There wont be the need to create a new MOD if Voice Attack can do what this MOD can do, you have to try to tell the differences.

<shrug>

John Pancoast
09-23-24, 05:51 PM
How? If the clickable compass moves as the boat turns, how can we use pre-programmed mouse coordinates to give those orders? I figure this mod must be doing something very different, but I haven't been able to test it yet and perhaps I'm just not enough of a VA power-user.

- Tabris

I have the $10 paid version of VA, fwiw. Made a SH3 profile awhile back with it. Haven't played SH3 in ages, I'll take a look when I can.

Tabris
09-23-24, 07:33 PM
I have the $10 paid version of VA, fwiw. Made a SH3 profile awhile back with it. Haven't played SH3 in ages, I'll take a look when I can.

cheers, no rush. I also regularly use VA's payware and I think it's a must-have resource for this sort of simulation, but I need to test Shadow's mod in any case.

John Pancoast
09-23-24, 08:08 PM
cheers, no rush. I also regularly use VA's payware and I think it's a must-have resource for this sort of simulation, but I need to test Shadow's mod in any case.

:up: Yes, Shadow's is great work.

shadow_wxh
09-28-24, 01:53 PM
In case anyone still have any doubt here are some of the basic things VoiceCommand capable to do:

1. Input course command as in true bearing.
2. Update TDC data while your field of view and mouse focusing elsewhere on the screen.
3. Sync/Unsync TDC automatically
4. Input command parameter in decimal point precision.
5. Access all the standard and non standard commands for silent hunter.
6. Plus a lot more. I'll leave the player to discover the true potential of the MOD.....😉

shadow_wxh
01-16-25, 12:28 PM
Here is the link to the demonstration video

https://www.bilibili.com/video/BV1Fct7e5EJU/?share_source=copy_web&vd_source=51638445b4e56fa70d2456775c10a9ce

DieSauergurke
02-22-25, 10:57 AM
This mod is kind of a dream of mine. Unfortunately, I own an AMD 7900XT GPU and can't try it. You mentioned that compatibility could be added later—are you still considering it?

Still, kudos to you for the great mod and the demo video! :Kaleun_Cheers:

Aktungbby
02-22-25, 04:41 PM
DieSauergurke!:Kaleun_Salute:...after a 6-year 'silent run'!:up:

rik007
02-23-25, 02:36 AM
Unfortunately this mod never worked for me though I'm very impressed by the amount of work shadow_wxh put into it.

But you can use Voice Attack instead. You can pick a basic profile (German or English) from this mod: https://www.subsim.com/radioroom/showpost.php?p=2890806&postcount=1

:Kaleun_Salute:

shadow_wxh
02-28-25, 04:54 PM
This mod is kind of a dream of mine. Unfortunately, I own an AMD 7900XT GPU and can't try it. You mentioned that compatibility could be added later—are you still considering it?

Still, kudos to you for the great mod and the demo video! :Kaleun_Cheers:

You can pass command like "D:\SilentHunterIII\VoiceCommand\VoiceTranscriber.e xe -ng -l de -m D:\SilentHunterIII\VoiceCommand\vccmd-german-medium.bin" in the window CMD console to switch to CPU however the processing speed is slow.
In theory what is working for NVidia should working for AMD as well. But I don't have a AMD card at hand and It might require some code change and additional build step I wouldn't know. Also I am still waiting for some user feedback to decide which step to take for the next upgrade. So It is going to take a while.

shadow_wxh
02-28-25, 04:59 PM
Unfortunately this mod never worked for me though I'm very impressed by the amount of work shadow_wxh put into it.

But you can use Voice Attack instead. You can pick a basic profile (German or English) from this mod: https://www.subsim.com/radioroom/showpost.php?p=2890806&postcount=1

:Kaleun_Salute:

feel sorry it didn't work for you, please let me know if there is anything I can help.

Tabris
04-05-25, 10:06 PM
this mod does work for me but sadly I'm not using it because every command I give makes the game "hang" for about 0.8 seconds. it becomes quite noticeable when trying to give TDC commands, and that was the part I was most excited to be able to use this mod for. Most likely it's a limitation of my GPU, which surprises me because I can run many modern or at least semi-modern games with ease, but who knows. Has anyone else found the hardware demand to be unexpectedly high?

shadow_wxh
04-10-25, 11:15 AM
this mod does work for me but sadly I'm not using it because every command I give makes the game "hang" for about 0.8 seconds. it becomes quite noticeable when trying to give TDC commands, and that was the part I was most excited to be able to use this mod for. Most likely it's a limitation of my GPU, which surprises me because I can run many modern or at least semi-modern games with ease, but who knows. Has anyone else found the hardware demand to be unexpectedly high?

What is your graphic card model? I think the minimum support is GeForce GTX 1060.

Tabris
04-10-25, 02:54 PM
I think the minimum support is GeForce GTX 1060.


well, that tracks, then! I have a GTX 960. A shame! To be clear to anyone reading, despite this issue, this mod has my full endorsement for those who can run it.