Jump to content

MediaInfo For Emby Plugin(HDR, Vision, Atmos, DTS:X)


Cheesegeezer

Recommended Posts

FrostByte

The only way to fix that would be to modify the Language field which Emby adds to the beginning of what's found in the Title field.  In my example below it's set as "en". 

You don't need to remux to fix it though.  A simple header modification takes a second vs remuxing.

 

"@type": "Audio",
"@typeorder": "1",
"StreamOrder": "1",
"ID": "2",
"OriginalSourceMedium_ID": "4352",
"UniqueID": "2",
"Format": "MLP FBA",
"Format_Commercial_IfAny": "Dolby TrueHD with Dolby Atmos",
"Format_AdditionalFeatures": "16-ch",
"CodecID": "A_TRUEHD",
"Duration": "8177.169000000",
"BitRate_Mode": "VBR",
"BitRate": "5191029",
"BitRate_Maximum": "8358000",
"Channels": "8",
"ChannelPositions": "Front: L C R, Side: L R, Back: L R, LFE",
"ChannelLayout": "L R C LFE Ls Rs Lb Rb",
"SamplesPerFrame": "40",
"SamplingRate": "48000",
"SamplingCount": "392504112",
"FrameRate": "1200.000",
"FrameCount": "9812602",
"BitDepth": "24",
"Compression_Mode": "Lossless",
"Delay": "0.000",
"Delay_Source": "Container",
"StreamSize": "5305991074",
"StreamSize_Proportion": "0.10520",
"Title": "Dolby TrueHD Atmos 7.1 (Default)",
"Language": "en",
"Default": "Yes",
"Forced": "No",
"extra": {
"OriginalSourceMedium": "Blu-ray",
"NumberOfDynamicObjects": "11",
"BedChannelCount": "1",
"BedChannelConfiguration": "LFE"
}

 

Link to comment
Share on other sites

1971camaroguy

No worries, I don't have a lot of them like that, I might go ahead and remux them to add english or remove the und altogether.

Link to comment
Share on other sites

Cheesegeezer
10 minutes ago, FrostByte said:

The only way to fix that would be to modify the Language field which Emby adds to the beginning of what's found in the Title field.  In my example below it's set as "en". 

You don't need to remux to fix it though.  A simple header modification takes a second vs remuxing.

i might look into this. But i fear it’s gonna pop a can of worms right open for endless possibilities lol 😂 

Link to comment
Share on other sites

Cheesegeezer
11 minutes ago, 1971camaroguy said:

No worries, I don't have a lot of them like that, I might go ahead and remux them to add english or remove the und altogether.

As ole FrostyNickers says, just a header change no requirement to remux.

  • Haha 1
Link to comment
Share on other sites

sydlexius
3 minutes ago, Cheesegeezer said:

i might look into this. But i fear it’s gonna pop a can of worms right open for endless possibilities lol 😂 

I suspect that it's just not going to be worth the trouble.  The best solutions for identifying language via text or audio samples are often cloud-based ones, which won't come cheaply and will have privacy concerns.

Link to comment
Share on other sites

rbjtech

Und is simply an undefined track language - I'd much rather it say Und (and  in doing so, flag it for the Admin to do something about it..) than incorrectly try and define it and have disappointed users when they select it to playback at a later date and find out it's an incorrect detection.

Unless there is a solid way to determine it - My view is leave it alone.... 🤪

  • Agree 2
Link to comment
Share on other sites

sydlexius
13 minutes ago, rbjtech said:

Und is simply an undefined track language - I'd much rather it say Und (and  in doing so, flag it for the Admin to do something about it..) than incorrectly try and define it and have disappointed users when they select it to playback at a later date and find out it's an incorrect detection.

Unless there is a solid way to determine it - My view is leave it alone.... 🤪

I'd rather rely on solid reporting of which media has UND audio and/or subtitles, some method of playback, and wetware + MKVToolNix header editor to fix the issue. If it's mostly subtitles and I'm feeling lazy, then perhaps letting something like Bazarr rip on my collection.

  • Like 1
Link to comment
Share on other sites

19 hours ago, Dizzy49 said:

I have my files in the right place, and the correct versions.

I'm looking at the log and first off I see "Reset Embedded Titles = False", but I set "Refresh All Items" to true so it would do my entire collection.

I see it working, looks like it's taking 1000-1400ms per file.  If it does all movies and shows that's about 37k files.  Should take 10-12hrs.

Looks like Captain America, The Winter Soldier has some issues with the audio.

2022-09-28 00:32:29.113 Debug Media Info: AUDIO INFO
2022-09-28 00:32:29.113 Debug Media Info: Track Format = DTS
2022-09-28 00:32:29.113 Debug Media Info: No of Channels = 6
2022-09-28 00:32:29.113 Debug Media Info: Track Index = 2
2022-09-28 00:32:29.113 Debug Media Info: Track Additional Features = XLL
2022-09-28 00:32:29.113 Debug Media Info: *********************
2022-09-28 00:32:29.113 Debug Media Info: Adding Audio Tags
2022-09-28 00:32:29.113 Debug Media Info: Adding Audio Tag DTS-HD MA to Captain America: The Winter Soldier
2022-09-28 00:32:29.239 Info Server: http/1.1 POST http://emby_remote_ip:8096/emby/Sessions/Playing/Progress?X-Emby-Client=Emby Web&X-Emby-Device-Name=Chrome Windows&X-Emby-Device-Id=798c13ed-9a73-4b87-836d-850b1a37c27a&X-Emby-Client-Version=4.7.6.0&reqformat=json. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36
2022-09-28 00:32:29.239 Debug SessionManager: OnPlaybackProgress TimeUpdate b3e535f735174e53908bc9d496da0316
2022-09-28 00:32:29.240 Info Server: http/1.1 Response 204 to host3. Time: 1ms. http://emby_remote_ip:8096/emby/Sessions/Playing/Progress?X-Emby-Client=Emby Web&X-Emby-Device-Name=Chrome Windows&X-Emby-Device-Id=798c13ed-9a73-4b87-836d-850b1a37c27a&X-Emby-Client-Version=4.7.6.0&reqformat=json
2022-09-28 00:32:29.440 Debug Media Info: AUDIO EXIT CODE 2: STD ERROR OUTPUT
2022-09-28 00:32:29.440 Debug Media Info: 
2022-09-28 00:32:29.440 Debug Media Info: AUDIO EXIT CODE 2: STD OUTPUT
2022-09-28 00:32:29.440 Debug Media Info: The file is being analyzed.
Error: No track corresponding to the edit specification 'a2' was found. The file has not been modified.

2022-09-28 00:32:29.440 Info Media Info: Audio Track successfully Written & Exited with Code 2
2022-09-28 00:32:29.440 Info Media Info: Audio Stream #2 Updated to: DTS-HD MA 5.1
2022-09-28 00:32:29.442 Debug App: Saving nfo metadata for D:\Video\Movies\Marvel Collection\Captain America, The Winter Soldier (2014) [PG-13]\Captain America, The Winter Soldier (2014) [PG-13] [1080p].mkv to D:\Video\Movies\Marvel Collection\Captain America, The Winter Soldier (2014) [PG-13]\Captain America, The Winter Soldier (2014) [PG-13] [1080p].nfo.
2022-09-28 00:32:29.445 Info Media Info: Item Tags found =  duringcreditsstinger - based on comic book - marvel cinematic universe - marvel comics - marvel - shield - cyborg - comics - fugitives - DTS-HD MA
2022-09-28 00:32:29.445 Info Media Info: PROCESSING OF Captain America: The Winter Soldier HAS COMPLETED

 

The plugin updated TWICE today, and for the first time it's actually showing progress!  So hopefully it's working now.  I will report back.

MediaInfo1.png

 

It ran for about 10hrs. then got stuck at 87.6% and has been sitting there for about 8hrs now.

The log file is over 220mb so I don't think I can share it here.

I'm going to restart the server to kill it and try to run it again starting a new log file, and hope it doesn't try to start from the beginning.

Link to comment
Share on other sites

rbjtech
7 hours ago, Dizzy49 said:

 

It ran for about 10hrs. then got stuck at 87.6% and has been sitting there for about 8hrs now.

The log file is over 220mb so I don't think I can share it here.

I'm going to restart the server to kill it and try to run it again starting a new log file, and hope it doesn't try to start from the beginning.

Can you share just a short extract of the log ?

We basically need to see anything with a 'MediaInfo' log class 

Logging is very verbose - It should say something along the lines below for each file that is updated - so you can clearly see what is going on.

It may be getting stuck on an item - as each item should be taking milliseconds...

 

2022-09-29 10:57:12.764 Info Media Info: Item FilePath = \\media\TV Series\Big Sky (2020) [tvdbID=378023]\Season 3\Big Sky (2020) - s03e02 - The Woods Are Lovely Dark and Deep.mkv 
2022-09-29 10:57:12.890 Info Media Info: Video Track successfully Written & Exited with Code 0
2022-09-29 10:57:12.890 Info Media Info: Video Track Title Set to HD 1080p  [10.1Mb/s]
2022-09-29 10:57:12.957 Info Media Info: Audio Track successfully Written & Exited with Code 0
2022-09-29 10:57:12.957 Info Media Info: Audio Stream #1 Updated to: AAC 2.0 [LC] (Default)
2022-09-29 10:57:13.003 Info Media Info: Audio Track successfully Written & Exited with Code 0
2022-09-29 10:57:13.003 Info Media Info: Audio Stream #2 Updated to: Dolby Digital+ 5.1
2022-09-29 10:57:13.023 Info Media Info: Item Tags found =  
2022-09-29 10:57:13.023 Info Media Info: PROCESSING OF The Woods Are Lovely, Dark and Deep HAS COMPLETED Successfully

 

Link to comment
Share on other sites

rbjtech
8 hours ago, Dizzy49 said:

I'm going to restart the server to kill it and try to run it again starting a new log file, and hope it doesn't try to start from the beginning.

If possible, Stop/Cancel the process using the emby scheduler - this will gracefully write the progress XML file so it knows what it has already completed.

The file it writes is :

<your emby root>/programdata/plugins/configurations/Emby.MediaInfo.xml

If you kill it - I fear it will not and you will need to start again ... :(

Link to comment
Share on other sites

Cheesegeezer
39 minutes ago, rbjtech said:

If possible, Stop/Cancel the process using the emby scheduler - this will gracefully write the progress XML file so it knows what it has already completed.

The file it writes is :

<your emby root>/programdata/plugins/configurations/Emby.MediaInfo.xml

If you kill it - I fear it will not and you will need to start again ... :(

@Dizzy49 

after each item is completed and written to the processed list, it saves the xml. So you should be fine. 
 

just wondering if a library scan kicked in and locked the database prevent the plugin access.

Link to comment
Share on other sites

Cheesegeezer

Version 1.0.1.10 just released to the plugin

  1. Fix Linux Library issues (i hope) in both MediaInfo and Bif Generator
  2. Ignore case sensitivity for file extensions.
  3. Added Identification of DV5 formats that are incorrectly identified with HDR (Shown as DV5** HDR)

image.png.93e2eb4257c663d88359e86be169eba5.png

  • Like 3
Link to comment
Share on other sites

On 9/29/2022 at 5:08 AM, Cheesegeezer said:

@Dizzy49 

after each item is completed and written to the processed list, it saves the xml. So you should be fine. 
 

just wondering if a library scan kicked in and locked the database prevent the plugin access.

By the time I got around to trying to kill it I noticed it was in fact still running, just REALLY SLOWLY.  Like .1% an hour.  It JUST finished.  Interesting that it reports it took 9h 34m when in fact it took several days to complete.  Does it count the actual time processed, or use a start and end timer and compare the diff?  It seemed to really slow down when it hit my TV series.

My Library Scan is set to run at 4am every day.  I will also manually hit the Organize New Media Files 6 or 7 times a day.  It then of course gets the metadata and generates bif files for the new files as well.  Ongoing I don't expect any major issues like that, it's always that first time through that takes forever.

I had some video that were hybrid containing both DV and HDR10 and I was curious how that would appear.  "4K DV8 HDR10"  :D

As I go through and spot files missing their info is there a way I can get those to run again?  Maybe delete the .nfo and .bif?

Screenshot_58.png

Link to comment
Share on other sites

FrostByte
11 minutes ago, Dizzy49 said:

 

As I go through and spot files missing their info is there a way I can get those to run again?  Maybe delete the .nfo and .bif?

Screenshot_58.png

WOW!! That's a long time

Just add the ID in the Reprocess Items box

Link to comment
Share on other sites

21 minutes ago, FrostByte said:

WOW!! That's a long time

Just add the ID in the Reprocess Items box

Where can I find the ID?

Link to comment
Share on other sites

FrostByte
7 minutes ago, Dizzy49 said:

Where can I find the ID?

Look at the http link in your browser when viewing the movie details page there should be the text "id=" followed by a number

  • Haha 1
Link to comment
Share on other sites

Cheesegeezer
7 minutes ago, Dizzy49 said:

Where can I find the ID?

Web UI is the best…  click on the item and then look in the address bar, it will have itemId=xxx in the long address request.

 

285B919A-A9A1-48EC-86CB-0ABB4B99450C.thumb.jpeg.fb3b16dbe9aeef1d88ede29a9dc044f2.jpeg

Link to comment
Share on other sites

2 minutes ago, Cheesegeezer said:

Web UI is the best…  click on the item and then look in the address bar, it will have itemId=xxx in the long address request.

 

285B919A-A9A1-48EC-86CB-0ABB4B99450C.thumb.jpeg.fb3b16dbe9aeef1d88ede29a9dc044f2.jpeg

They should make that easier to find.  I never use the webUI.  It should be at the bottom of the file with all of the file data.

Link to comment
Share on other sites

Cheesegeezer
1 minute ago, Dizzy49 said:

They should make that easier to find.  I never use the webUI.  It should be at the bottom of the file with all of the file data.

Yep its not even in the metadata either

  • Agree 1
Link to comment
Share on other sites

4 hours ago, Dizzy49 said:

They should make that easier to find.  I never use the webUI.  It should be at the bottom of the file with all of the file data.

Yea, I agree, but for admin accounts only.

Link to comment
Share on other sites

  • 2 weeks later...
Trevor68

Is there something that would cause this plugin to just run for 1 second? 

I download the CLI version of mediainfor for 64bit windows, and also the portable version of mkvtoolnix, but still it doesn't seem to run. 

 

mediapaths.jpg

Link to comment
Share on other sites

rbjtech

Turn on debug logging in emby and look at or post the log .. it will tell you exactly what is going on .  

Link to comment
Share on other sites

rbjtech

I'll take a look at this later for you, on the train atm and can't view the log properly.

In the mean time, make sure the paths to the mediainfo cli and mkvpropedit are correct.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...