home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 2
General
this view could not be built
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="morpheus_xx" data-source="post: 1164484" data-attributes="member: 48495"><p>If there are multiple results from an online query, then it is tried to find the best matching title by various steps:</p><p></p><p>A single lookup is executed like this:</p><p><a href="https://github.com/MediaPortal/MediaPortal-2/blob/master/MediaPortal/Source/Extensions/MetadataExtractors/OnlineLibraries/TheMovieDB/TheMovieDbWrapper.cs#L127-L172" target="_blank">https://github.com/MediaPortal/MediaPortal-2/blob/master/MediaPortal/Source/Extensions/MetadataExtractors/OnlineLibraries/TheMovieDB/TheMovieDbWrapper.cs#L127-L172</a></p><p></p><ol> <li data-xf-list-type="ol">Try to find exact one entry, where the text is the "same" (exact or LevenshteinDistance) exactMatches = movies.FindAll(s => s.Title == moviesName || s.OriginalTitle == moviesName || GetLevenshteinDistance(s, moviesName) == 0);</li> <li data-xf-list-type="ol">If there are still multiple matches, a maybe given year is considered next: var yearFiltered = exactMatches.FindAll(s => s.ReleaseDate.HasValue && s.ReleaseDate.Value.Year == year);</li> <li data-xf-list-type="ol">As last, it's tried to find exact one title with LevenshteinDistance with maximum tolerance: movies = movies.Where(s => GetLevenshteinDistance(s, moviesName) <= MAX_LEVENSHTEIN_DIST).ToList();</li> </ol><p></p><p>Then there is additionally an outer processing which tries to split titles by "-" (which is quite common for translated titles, where the original one is followed by a localized title):</p><p><a href="https://github.com/MediaPortal/MediaPortal-2/blob/master/MediaPortal/Source/Extensions/MetadataExtractors/OnlineLibraries/TheMovieDB/TheMovieDbWrapper.cs#L82-L113" target="_blank">https://github.com/MediaPortal/MediaPortal-2/blob/master/MediaPortal/Source/Extensions/MetadataExtractors/OnlineLibraries/TheMovieDB/TheMovieDbWrapper.cs#L82-L113</a></p><p></p><p></p><p>So the lookup algorithmn is quite complex already, but will still fail if there are more then 1 possible result after all tests.</p><p></p><p>In your case I also think that only the file name is used here for lookup, the full name in the parent folder is not considered.</p><p></p><p></p><p></p><p>The best way is to have a IMDBId available, either from;</p><ul> <li data-xf-list-type="ul">File name<br /> </li> <li data-xf-list-type="ul">Folder name</li> <li data-xf-list-type="ul">MatroskaTags<br /> </li> <li data-xf-list-type="ul">.NFO file</li> </ul><p>Then there is no texual lookup, but a IMDBid based one, which gives exact matching.</p><p></p><p>So if you name your file: C:/video/Sweeney Todd The Demon Barber of Fleet Street (2007)/Sweeney Todd <strong>[tt0408236]</strong>.mkv it should be already enough for an unique match.</p><p></p><p></p><p>Why the supplied .nfo was not considered in your last try, I don't know...</p></blockquote><p></p>
[QUOTE="morpheus_xx, post: 1164484, member: 48495"] If there are multiple results from an online query, then it is tried to find the best matching title by various steps: A single lookup is executed like this: [URL]https://github.com/MediaPortal/MediaPortal-2/blob/master/MediaPortal/Source/Extensions/MetadataExtractors/OnlineLibraries/TheMovieDB/TheMovieDbWrapper.cs#L127-L172[/URL] [LIST=1] [*]Try to find exact one entry, where the text is the "same" (exact or LevenshteinDistance) exactMatches = movies.FindAll(s => s.Title == moviesName || s.OriginalTitle == moviesName || GetLevenshteinDistance(s, moviesName) == 0); [*]If there are still multiple matches, a maybe given year is considered next: var yearFiltered = exactMatches.FindAll(s => s.ReleaseDate.HasValue && s.ReleaseDate.Value.Year == year); [*]As last, it's tried to find exact one title with LevenshteinDistance with maximum tolerance: movies = movies.Where(s => GetLevenshteinDistance(s, moviesName) <= MAX_LEVENSHTEIN_DIST).ToList(); [/LIST] Then there is additionally an outer processing which tries to split titles by "-" (which is quite common for translated titles, where the original one is followed by a localized title): [URL]https://github.com/MediaPortal/MediaPortal-2/blob/master/MediaPortal/Source/Extensions/MetadataExtractors/OnlineLibraries/TheMovieDB/TheMovieDbWrapper.cs#L82-L113[/URL] So the lookup algorithmn is quite complex already, but will still fail if there are more then 1 possible result after all tests. In your case I also think that only the file name is used here for lookup, the full name in the parent folder is not considered. The best way is to have a IMDBId available, either from; [LIST] [*]File name [*]Folder name [*]MatroskaTags [*].NFO file [/LIST] Then there is no texual lookup, but a IMDBid based one, which gives exact matching. So if you name your file: C:/video/Sweeney Todd The Demon Barber of Fleet Street (2007)/Sweeney Todd [B][tt0408236][/B].mkv it should be already enough for an unique match. Why the supplied .nfo was not considered in your last try, I don't know... [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 2
General
this view could not be built
Contact us
RSS
Top
Bottom