[PP-Script] VideoSort - better video sorting

Share your scripts or request scripts with specific features.
Forum rules
Please keep the forum clean - one topic per script. Questions not related to a specific script should be posted in Support forum.
hugbug
Developer & Admin
Posts: 7542
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: [PP-Script] VideoSort - better video sorting

Post by hugbug » 31 Oct 2014, 06:26

The problem here is that both input and output directories are the same. If you can change MoviesDir/SeriesDir in VideoSort or DestDir in NZBGet that should fix it.

binreader
Posts: 20
Joined: 07 Oct 2014, 03:00

Re: [PP-Script] VideoSort - better video sorting

Post by binreader » 31 Oct 2014, 15:26

not sure about that, definitely don't want to change the movie dir in nzbget.

I want all movie stuff to got to z:\movies.

Are you saying that video sort itself has a temp directory where the vid can be processed and renamed and then the script will move it to the nzbget movie directory?

hugbug
Developer & Admin
Posts: 7542
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: [PP-Script] VideoSort - better video sorting

Post by hugbug » 31 Oct 2014, 18:05

You set MoviesDir in VideoSort to your desired final path and DestDir in NZBGet to any path which you can now consider a temp-path. For example set MoviesDir (in VideoSort) to "z:\movies" and DestDir (in NZBGet) to "z:\movies\downloaded".

minimeh
Posts: 33
Joined: 16 Aug 2013, 09:54

Re: [PP-Script] VideoSort - better video sorting

Post by minimeh » 01 Nov 2014, 23:28

I have been having a problem sorting "Real Time with Bill Maher" for a while. Can't say exactly when it started, but it's been weeks if not months. I'm currently using NZBGet 14.0-testing-r1152 and VideoSort 5.0 on Windows 8.

An NZB like "Real.Time.with.Bill.Maher.2014.10.31.720p.HDTV.x264-BATV.nzb" results in being sorted to "Time with Bill Maher/Time.With.Bill.Maher.2014.10.31.mkv".

I turned on Verbose for VideoSort and re-downloaded. Looking at the log, it appears that "Real" is assumed to be a "Proper" designation and is therefore stripped out of the name.

Here is a snippet of the log:

Code: Select all

Sat Nov 01 11:47:33 2014	INFO	Executing post-process-script videosort\VideoSort.py for Real.Time.with.Bill.Maher.2014.10.31.720p.HDTV.x264-BATV
Sat Nov 01 11:47:35 2014	INFO	VideoSort: Forcing TV sorting (category: TV)
Sat Nov 01 11:47:35 2014	INFO	VideoSort: Skipping small: sample-real.time.with.bill.maher.2014.10.31.720p.hdtv.x264-batv.mkv
Sat Nov 01 11:47:35 2014	INFO	VideoSort: filename: Z:\Media\TV\Real.Time.with.Bill.Maher.2014.10.31.720p.HDTV.x264-BATV\Real.Time.With.Bill.Maher.2014.10.31.720p.HDTV.x264-BATV.mkv
Sat Nov 01 11:47:35 2014	INFO	VideoSort: Using NZB-Name
Sat Nov 01 11:47:35 2014	INFO	VideoSort: Guessing: Real.Time.with.Bill.Maher.2014.10.31.720p.HDTV.x264-BATV.mkv
Sat Nov 01 11:47:35 2014	INFO	VideoSort: 00000000000000000000000000000000000000000000000000000000 111
Sat Nov 01 11:47:35 2014	INFO	VideoSort: 00000000000000000000000000000000000000000000000000000000 000
Sat Nov 01 11:47:35 2014	INFO	VideoSort: 00000000000000000000000000111111111122222222222222222222 000
Sat Nov 01 11:47:35 2014	INFO	VideoSort: 00001111111111111111111111          00000011112222222222
Sat Nov 01 11:47:35 2014	INFO	VideoSort:                                     011112    0111122222
Sat Nov 01 11:47:35 2014	INFO	VideoSort:                                                    01111
Sat Nov 01 11:47:35 2014	INFO	VideoSort: ____________________________________.____.____.____-____.___
Sat Nov 01 11:47:35 2014	INFO	VideoSort: oooottttttttttttttttttttttdddddddddd ssss ffff vvvv rrrr ccc
Sat Nov 01 11:47:35 2014	INFO	VideoSort: Real.Time.with.Bill.Maher.2014.10.31.720p.HDTV.x264-BATV.mkv
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'type': u'movie'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'other': u'Proper'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'title': u'Time with Bill Maher'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'date': '2014-10-31'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'screenSize': u'720p'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'format': u'HDTV'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'videoCodec': u'h264'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'releaseGroup': u'BATV'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'container': u'mkv'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {u'container': u'mkv'}
Sat Nov 01 11:47:36 2014	INFO	VideoSort: {
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "videoCodec": "h264",
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "container": "mkv",
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "format": "HDTV",
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [0.60] "title": "Time with Bill Maher",
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "releaseGroup": "BATV",
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "other": [
Sat Nov 01 11:47:36 2014	INFO	VideoSort:         "Proper"
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     ],
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "screenSize": "720p",
Sat Nov 01 11:47:36 2014	INFO	VideoSort:     [1.00] "date": "2014-10-31",
Sat Nov 01 11:47:37 2014	INFO	VideoSort:     [1.00] "type": "movie"
Sat Nov 01 11:47:37 2014	INFO	VideoSort: }
Sat Nov 01 11:47:37 2014	INFO	VideoSort: Type: dated
Sat Nov 01 11:47:37 2014	INFO	VideoSort: format: %sn/%s.n.%y.%0m.%0d.%ext
Sat Nov 01 11:47:37 2014	INFO	VideoSort: path after subst: Time With Bill Maher/Time.With.Bill.Maher.2014.10.31..mkv
Sat Nov 01 11:47:37 2014	INFO	VideoSort: path after cleanup: Time With Bill Maher\Time.With.Bill.Maher.2014.10.31.mkv
Sat Nov 01 11:47:37 2014	INFO	VideoSort: destination path: Z:\Media\TV\Time With Bill Maher\Time.With.Bill.Maher.2014.10.31.mkv
And for giggles, I tried downloading "Real Housewives of Melbourne S01E01 HDTV x264-W4F". Sure enough, sorted as "Housewives of Melbourne/Season 1/Housewives.of.Melbourne.S01E01.mp4". Here's the log for that:

Code: Select all

Sat Nov 01 15:43:45 2014	INFO	Executing post-process-script videosort\VideoSort.py for Real Housewives of Melbourne S01E01 HDTV x264-W4F
Sat Nov 01 15:43:47 2014	INFO	VideoSort: Forcing TV sorting (category: TV)
Sat Nov 01 15:43:47 2014	INFO	VideoSort: filename: Z:\Media\TV\Real Housewives of Melbourne S01E01 HDTV x264-W4F\real.housewives.of.melbourne.s01e01.hdtv.x264-w4f.mp4
Sat Nov 01 15:43:47 2014	INFO	VideoSort: Using NZB-Name
Sat Nov 01 15:43:47 2014	INFO	VideoSort: Guessing: Real Housewives of Melbourne S01E01 HDTV x264-W4F.mp4
Sat Nov 01 15:43:47 2014	INFO	VideoSort: 0000000000000000000000000000000000000000000000000 111
Sat Nov 01 15:43:47 2014	INFO	VideoSort: 0000000000000000000000000000000000000000000000000 000
Sat Nov 01 15:43:47 2014	INFO	VideoSort: 0000000000000000000000000000000000001111222222222 000
Sat Nov 01 15:43:47 2014	INFO	VideoSort: 000011111111111111111111111111111111    011112222
Sat Nov 01 15:43:47 2014	INFO	VideoSort:     00000000000000000000000001111112         0111
Sat Nov 01 15:43:47 2014	INFO	VideoSort: ___________________________________ ____ ____-___.___
Sat Nov 01 15:43:47 2014	INFO	VideoSort: ooooTTTTTTTTTTTTTTTTTTTTTTTTTEEEEEE ffff vvvv rrr ccc
Sat Nov 01 15:43:47 2014	INFO	VideoSort: Real Housewives of Melbourne S01E01 HDTV x264-W4F.mp4
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'type': u'episode'}
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'other': u'Proper'}
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'series': u'Housewives of Melbourne'}
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'season': 1, u'episodeNumber': 1}
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'format': u'HDTV'}
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'videoCodec': u'h264'}
Sat Nov 01 15:43:47 2014	INFO	VideoSort: {u'releaseGroup': u'W4F'}
Sat Nov 01 15:43:48 2014	INFO	VideoSort: {u'mimetype': u'video/mp4', u'container': u'mp4'}
Sat Nov 01 15:43:48 2014	INFO	VideoSort: {u'container': u'mp4'}
Sat Nov 01 15:43:48 2014	INFO	VideoSort: {
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "mimetype": "video/mp4",
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "episodeNumber": 1,
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "videoCodec": "h264",
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "container": "mp4",
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "format": "HDTV",
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [0.70] "series": "Housewives of Melbourne",
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "releaseGroup": "W4F",
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "other": [
Sat Nov 01 15:43:48 2014	INFO	VideoSort:         "Proper"
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     ],
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "season": 1,
Sat Nov 01 15:43:48 2014	INFO	VideoSort:     [1.00] "type": "episode"
Sat Nov 01 15:43:48 2014	INFO	VideoSort: }
Sat Nov 01 15:43:48 2014	INFO	VideoSort: Type: series
Sat Nov 01 15:43:48 2014	INFO	VideoSort: format: %sn/Season %s/%s.n.S%0sE%0e.%ext
Sat Nov 01 15:43:48 2014	INFO	VideoSort: path after subst: Housewives of Melbourne/Season 1/Housewives.of.Melbourne.S01E01..mp4
Sat Nov 01 15:43:49 2014	INFO	VideoSort: path after cleanup: Housewives of Melbourne\Season 1\Housewives.of.Melbourne.S01E01.mp4
Sat Nov 01 15:43:49 2014	INFO	VideoSort: destination path: Z:\Media\TV\Housewives of Melbourne\Season 1\Housewives.of.Melbourne.S01E01.mp4
Sat Nov 01 15:43:49 2014	INFO	VideoSort: Moved: Z:\Media\TV\Housewives of Melbourne\Season 1\Housewives.of.Melbourne.S01E01.mp4
I see that in "guess_properties.py" at line 206 there is

Code: Select all

self.container.register_property('other', 'Real', 'Fix', canonical_form="Proper", 
On a lark, I commented out that line and re-downloaded "Real Housewives of Melbourne".

Code: Select all

Sat Nov 01 16:19:08 2014	INFO	Executing post-process-script videosort\VideoSort.py for Real Housewives of Melbourne S01E01 HDTV x264-W4F
Sat Nov 01 16:19:08 2014	INFO	VideoSort: Forcing TV sorting (category: TV)
Sat Nov 01 16:19:08 2014	INFO	VideoSort: filename: Z:\Media\TV\Real Housewives of Melbourne S01E01 HDTV x264-W4F\real.housewives.of.melbourne.s01e01.hdtv.x264-w4f.mp4
Sat Nov 01 16:19:08 2014	INFO	VideoSort: Using NZB-Name
Sat Nov 01 16:19:08 2014	INFO	VideoSort: Guessing: Real Housewives of Melbourne S01E01 HDTV x264-W4F.mp4
Sat Nov 01 16:19:08 2014	INFO	VideoSort: 0000000000000000000000000000000000000000000000000 111
Sat Nov 01 16:19:08 2014	INFO	VideoSort: 0000000000000000000000000000000000000000000000000 000
Sat Nov 01 16:19:08 2014	INFO	VideoSort: 0000000000000000000000000000000000001111222222222 000
Sat Nov 01 16:19:08 2014	INFO	VideoSort: 000000000000000000000000000001111112    011112222
Sat Nov 01 16:19:08 2014	INFO	VideoSort:                                              0111
Sat Nov 01 16:19:09 2014	INFO	VideoSort: ___________________________________ ____ ____-___.___
Sat Nov 01 16:19:09 2014	INFO	VideoSort: TTTTTTTTTTTTTTTTTTTTTTTTTTTTTEEEEEE ffff vvvv rrr ccc
Sat Nov 01 16:19:09 2014	INFO	VideoSort: Real Housewives of Melbourne S01E01 HDTV x264-W4F.mp4
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'type': u'episode'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'series': u'Real Housewives of Melbourne'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'season': 1, u'episodeNumber': 1}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'format': u'HDTV'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'videoCodec': u'h264'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'releaseGroup': u'W4F'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'mimetype': u'video/mp4', u'container': u'mp4'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {u'container': u'mp4'}
Sat Nov 01 16:19:09 2014	INFO	VideoSort: {
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "mimetype": "video/mp4",
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "episodeNumber": 1,
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "videoCodec": "h264",
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "container": "mp4",
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "format": "HDTV",
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [0.70] "series": "Real Housewives of Melbourne",
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "releaseGroup": "W4F",
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "season": 1,
Sat Nov 01 16:19:09 2014	INFO	VideoSort:     [1.00] "type": "episode"
Sat Nov 01 16:19:10 2014	INFO	VideoSort: }
Sat Nov 01 16:19:10 2014	INFO	VideoSort: Type: series
Sat Nov 01 16:19:10 2014	INFO	VideoSort: format: %sn/Season %s/%s.n.S%0sE%0e.%ext
Sat Nov 01 16:19:10 2014	INFO	VideoSort: path after subst: Real Housewives of Melbourne/Season 1/Real.Housewives.of.Melbourne.S01E01..mp4
While that seems to fix my immediate issue, knowing what unexpected ripple effects are created is above my pay-scale. :)

What might the correct solution be?

hugbug
Developer & Admin
Posts: 7542
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: [PP-Script] VideoSort - better video sorting

Post by hugbug » 02 Nov 2014, 21:41

I'll test the latest version of guessit (library videosort relies on to parse filenames) and if the issue still exists there will report to the guessit project.

minimeh
Posts: 33
Joined: 16 Aug 2013, 09:54

Re: [PP-Script] VideoSort - better video sorting

Post by minimeh » 03 Nov 2014, 23:45

I grabbed the latest guessit 0.9.3 release and found that the behavior is the same. I opened a ticket on github: https://github.com/wackou/guessit/issues/173

minimeh
Posts: 33
Joined: 16 Aug 2013, 09:54

Re: [PP-Script] VideoSort - better video sorting

Post by minimeh » 10 Nov 2014, 11:56

minimeh wrote:I grabbed the latest guessit 0.9.3 release and found that the behavior is the same. I opened a ticket on github: https://github.com/wackou/guessit/issues/173
Toilal on the guessit development team committed a fix for the issue and closed the ticket. I pulled the revision and tried it and confirm that titles that begin with "Real" are parsed correctly now.

hugbug
Developer & Admin
Posts: 7542
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: [PP-Script] VideoSort - better video sorting

Post by hugbug » 10 Nov 2014, 12:40

Thanks for the info. I'll update guessit with the next VideoSort update.

Tarom
Posts: 3
Joined: 10 Nov 2014, 17:36

Re: [PP-Script] VideoSort - better video sorting

Post by Tarom » 22 Nov 2014, 11:23

Hello! Thank you for the great job you are doing. Started using videoSort and over a period of time noticed certain discrepancies that keep coming up. Certain shows get formatted wrongly, get cropped up and end up missing words in the title - "Real Time With Bill Maher" becomes - "Time With Bill Maher", "Star Wars: Rebels" becomes Wars: Rebels. As a result they are become unrecognizable to NZBDrone (aka Sonarr) and it'is unable to process them. There is a few more, but i can't recall them from the top of my head, but I'll be sure to add them later on to my post.

Cheers

hugbug
Developer & Admin
Posts: 7542
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: [PP-Script] VideoSort - better video sorting

Post by hugbug » 22 Nov 2014, 14:11

The problem with "Real Time With Bill Maher" was reported just few posts above.

For other problem-titles please provide full file names.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests