Code: Select all
>>> path='Star.Wars.Rebels.S01E08.WEBRiP.x264-QCF.mp4'
>>> matcher = guessit.matcher.IterativeMatcher(unicode(path), filetype='autodetect', opts=['nolanguage', 'nocountry'])
>>> guess = matcher.matched()
>>> print guess.nice_string()
{
[1.00] "mimetype": "video/mp4",
[1.00] "episodeNumber": 8,
[1.00] "videoCodec": "h264",
[1.00] "container": "mp4",
[1.00] "format": "WEBRip",
[0.70] "series": "Wars Rebels",
[0.80] "subtitleLanguage": [
"Arabic"
],
[1.00] "releaseGroup": "QCF",
[1.00] "season": 1,
[1.00] "type": "episode"
}
Code: Select all
>>> path='Star.Wars.Rebels.S01E08.WEBRiP.x264-QCF.mp4'
>>> guess = guessit.guess_file_info(path, info=['filename'])
>>> print guess.nice_string()
{
[1.00] "mimetype": "video/mp4",
[1.00] "episodeNumber": 8,
[1.00] "videoCodec": "h264",
[1.00] "container": "mp4",
[1.00] "format": "WEBRip",
[0.70] "series": "Star Wars Rebels",
[1.00] "releaseGroup": "QCF",
[1.00] "season": 1,
[1.00] "type": "episode"
}
I opened an issue ticket on the guessit project site: https://github.com/wackou/guessit/issues/177