Forum rules
Under no circumstances is spamming or advertising of any kind allowed. Do not post any abusive, obscene, vulgar, slanderous, hateful, threatening, sexually-orientated or any other material that may violate others security. Profanity or any kind of insolent behavior to other members (regardless of rank) will not be tolerated. Remember, what you don’t find offensive can be offensive to other members. Please treat each other with the kind of reverence you’d expect from other members.
Failure to comply with any of the above will result in users being banned without notice. If any further details are needed, contact: “The team” using the link at the bottom of the forum page. Thank you.
Cel
Posts: 4
Joined: Tue Jul 22, 2014 12:48 pm

Movie size when searching by query after hash search fails

Tue Jul 22, 2014 1:06 pm

When no results are found with the recommended hash and bytesize search, I use a full-text query search which yields some relevant results.
However, while the movie / episode match is fine i.e. all query results point to Breaking Bad S02E03 subtitles for instance, I would like to find the suitable result amongst them in terms of having the subtitles synced to the video all the way to the end.
Given the hash search failed, the only decent filtering criterion I came up with was to compare the size of the target video with the size of the subtitle result MovieByteSize property, and then download the subtitle with the smallest difference.
For example, if my breaking bad video file is 750000000 bytes and the query results would show MovieByteSizes a) 350000000 b) 749000000 c) 760000000 bytes then I would download the middle subtitle as it has the best chance of being in sync.

However, when searching by query, the SearchSubtitles API sets MovieByteSize to 0 :(
"Some data (IDSubMovieFile, MovieHash, MovieByteSize, MovieTimeMS) are set to 0, when searching by imdbid or query "
http://trac.opensubtitles.org/projects/ ... hSubtitles

Is there any way I could get MovieByteSize if searching by query? e.g. I couldn't find any way to search opensubtitles by IDSubtitle (which is populated in query search) and maybe get MovieByteSize with that?
Or I could use MovieTimeMS property instead, but that is set to 0 as well with query search .. (why?)

Thanks.

User avatar
oss
Site Admin
Posts: 5882
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: Movie size when searching by query after hash search fai

Sun Jul 27, 2014 6:01 am

it is simple - it is just because 1 subtitle file can be matched to many video files and vice versa. if we return all matched videofiles per subtitle file, it would generate high load (well, maybe there is possible to cache this, but again response will be higher, and I dont think this is really useful). Most clients should implement upload feature, so we will get more exact matches, so you will not come to this situation.

Cel
Posts: 4
Joined: Tue Jul 22, 2014 12:48 pm

Re: Movie size when searching by query after hash search fai

Sun Jul 27, 2014 10:59 am

i think you have misunderstood the question - it is not about returning more results but getting the movie size of (current) results when searching by query..

User avatar
oss
Site Admin
Posts: 5882
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: Movie size when searching by query after hash search fai

Sun Jul 27, 2014 1:51 pm

I understood question, with query searching (fulltext) you want return also moviesizes or other data, which you can use for approximate pairing. Again, 1 subtitle can match many movies, so that means, with one subtitle there can be lets say 20 different movie sizes. Of course they are hold in another table, so it is complicated, another join coming to the game, it will be slow on server side, responses would be bigger if implemented and you would be only one who will use it. I dont think it is good approach, back in time, I didnt want to have even fulltext (not-exact) searching in API for obvious reasons.

User avatar
oss
Site Admin
Posts: 5882
Joined: Sat Feb 25, 2006 11:26 pm
Contact: Website

Re: Movie size when searching by query after hash search fai

Sun Jul 27, 2014 1:58 pm

I understood question, with query searching (fulltext) you want return also moviesizes or other data, which you can use for approximate pairing. Again, 1 subtitle can match many movies, so that means, with one subtitle there can be lets say 20 different movie sizes. Of course they are hold in another table, so it is complicated, another join coming to the game, it will be slow on server side, responses would be bigger if implemented and you would be only one who will use it. I dont think it is good approach, back in time, I didnt want to have even fulltext (not-exact) searching in API for obvious reasons.

Return to “Developing”

Who is online

Users browsing this forum: No registered users and 12 guests