How (and why) i use FFAStrans on MacOS (and linux etc..) and whisper
Posted: Tue May 02, 2023 10:01 pm
We found out that a M1 Ultra Mac would deliver the same throughput while running speech-to-text (whisper) subtitling as a PC with A5000 Nvidia.
The reason is mainly because the main developer of whispercpp (github) is a Mac guy and focussed a lot on that. He built in special hardware support for the AI cores in the M1 (NEON framework i think). However, overall we are able to generate the same amount of subtitles using only ~25% of effective power which means that after 2-3 years operation the Mac saved it's own costs just by consuming less power and generating less heat.
Another very good point is that we can finally use the better whisper version because whispercpp is under heavy active development while the Const-me (GPU) version that we need for running on the nvidias does not really look like it's evolving at all.
Anyway, so even if i hate Macs from the bottom of my heart (not the linux part about them, just the mac part), i needed to find a way to integrate the Mac into an existing FFAStrans installation and distribute load between the nvidia on PC (which runs the ffastrans base installation) and the Mac.
If you read older topics in the forum, you also know that FFAStrans is pretty far away from being able to run natively on Linux due to the Scripting Language it consists of. So there is no way to actually "install ffastrans" on Linux (i was not able to get it running in wine too).
Anyway, so my way to do it was to develop a Plugin Processor that executes cmd commands via HTTP on a remote server. As i did not want the need to actually let Linux (macos) access the /db directory of ffastrans, of course there are some limitations but they might be less than you think.
The new "Remote cmd Executor" Processor is able to:
*) queue jobs totally independent of the ffastrans queue, based on a freely defined queue name and concurrency (this part is hard to explain actually)
*) submit jobs on any receiver that runs the job receiver application (comes pre-built for mac linux and windows with the plugin processor)
*) of course wait for jobs to finish
*) cancel jobs just as it was a normal ffastrans job, it will also send a cancel command to the remotely running commandline on linux device
*) report errrors and results to the workflow just as usual
Anyone interested, you find the processor where all plugin procs are:
https://www.ffastrans.com/wiki/doku.php ... processors
Also, i made a youtube video about it:
https://www.youtube.com/watch?v=vNtzGhRzWxc
The reason is mainly because the main developer of whispercpp (github) is a Mac guy and focussed a lot on that. He built in special hardware support for the AI cores in the M1 (NEON framework i think). However, overall we are able to generate the same amount of subtitles using only ~25% of effective power which means that after 2-3 years operation the Mac saved it's own costs just by consuming less power and generating less heat.
Another very good point is that we can finally use the better whisper version because whispercpp is under heavy active development while the Const-me (GPU) version that we need for running on the nvidias does not really look like it's evolving at all.
Anyway, so even if i hate Macs from the bottom of my heart (not the linux part about them, just the mac part), i needed to find a way to integrate the Mac into an existing FFAStrans installation and distribute load between the nvidia on PC (which runs the ffastrans base installation) and the Mac.
If you read older topics in the forum, you also know that FFAStrans is pretty far away from being able to run natively on Linux due to the Scripting Language it consists of. So there is no way to actually "install ffastrans" on Linux (i was not able to get it running in wine too).
Anyway, so my way to do it was to develop a Plugin Processor that executes cmd commands via HTTP on a remote server. As i did not want the need to actually let Linux (macos) access the /db directory of ffastrans, of course there are some limitations but they might be less than you think.
The new "Remote cmd Executor" Processor is able to:
*) queue jobs totally independent of the ffastrans queue, based on a freely defined queue name and concurrency (this part is hard to explain actually)
*) submit jobs on any receiver that runs the job receiver application (comes pre-built for mac linux and windows with the plugin processor)
*) of course wait for jobs to finish
*) cancel jobs just as it was a normal ffastrans job, it will also send a cancel command to the remotely running commandline on linux device
*) report errrors and results to the workflow just as usual
Anyone interested, you find the processor where all plugin procs are:
https://www.ffastrans.com/wiki/doku.php ... processors
Also, i made a youtube video about it:
https://www.youtube.com/watch?v=vNtzGhRzWxc