McCloudS / subgen

Autogenerate subtitles using OpenAI Whisper Model via Jellyfin, Plex, Emby, Tautulli, or Bazarr
MIT License
581 stars 49 forks source link

AA.srt not showing in Subtitle list in Plex. #5

Closed Wh1t3Rose closed 1 year ago

Wh1t3Rose commented 1 year ago

Hello. I have this installed in Unraid. I can see in the live log it generating the subtitles, and I can see what the people are saying.

I can also see the file it generates next to the episode file (EX NameOfEpisdoe.mkv.output.wav

However in Plex on my Shield TV and Plex app on PopOS, I do not see the AA.srt subtitle listed for me to select.

McCloudS commented 1 year ago

What's the full name of your media and subtitle? For example, "Community - S03E18 - Course Listing Unavailable.subgen.large.aa.srt" with a filename of "Community - S03E18 - Course Listing Unavailable.mkv" shows up just fine on my Plex apps and the web browser.

image

Also, once the subtitle is generated, that output.wav file should be deleted. If it's still there, that likely means it was interrupted during a subtitle generation and didn't finish what it needed.

Wh1t3Rose commented 1 year ago

Here is the live rolling log

I have 2 streams going. One is a remote user (RuPaul's Drag Race - S05E06 - Can I Get an Amen.mp4)

My stream is local and it is American Horror Story - S01E01 - Pilot.mkv

image

McCloudS commented 1 year ago

Have you actually had it generate/output a subtitle yet? That log implies it just started processing the wav through the model. On my setup, the medium model is about 45 seconds of processing per 60 seconds of media.

Wh1t3Rose commented 1 year ago

Ahh I didn't realize it took that long. It must still be generating then!

This poses a problem for content that is already on the server (not recently added).

What is the best way to test? Remove an episode, Initiate a scan in Plex so it gets removed, add it back and then let plex scan the file again? That way it shows up as "recently added"?

Then wait for the generation to complete and output an srt?

Edit: I forgot I have a trigger for it to initiate on Playback start. So I just need to start an episode. Then stop and check it in about 30-40 minutes...

McCloudS commented 1 year ago

If you go to a media file on Tautulli, you can trigger a "Recently Added" from there. That's how I did most of the testing. It loosely on the bottom right of the page.

image

Wh1t3Rose commented 1 year ago

Ok. I tested what you show. I did not see any activity in the live log for the new episode and I did not see it generate a .output.wav file for that episode.

Is this because it is already creating a file for another episode? Can it do multiple transcodes at once?

image

McCloudS commented 1 year ago

I've done 3-4 simultaneously. But if you're pegging your CPU, if might take longer than usual to actually extract and create the wav file. I think most of the debug stuff is still in the script, so you should at least see that it "saw" a valid webhook.

Wh1t3Rose commented 1 year ago

Holy smokes! I have a 3950x and it is pegging all 16 cores at 100%!! hmmmm

Wh1t3Rose commented 1 year ago

I adjusted the thread count in the compose file. All fixed!

Ok I can see it generated an srt now. I see it in the list and it works!

Thank you for explaining everything and being so repsonsive! I appreciate it! You have an asesome project here.

I gotta do some subtitle cleanup....

image