• 1
  • 3
  • 4
  • 5(current)
  • 6
  • 7
Thumbnail Overlay Generator - makeshift HD video flagging script
#61
thanks, this does the trick.. works like a charm Smile
Reply
#62
Hi there, nice script but I get an error:

Code:
Doing overlays for  /media/WD1/Filme 1/Metropolis/Metropolis.avi
PARSING: Found video line containing msmpeg4 and 25.00 tb(r)
PARSING: Found audio line containing mp3 and stereo
Traceback (most recent call last):
  File "tog.py", line 326, in <module>
    results = scanAllFiles(sys.argv[2:])
  File "tog.py", line 268, in scanAllFiles
    results = scanAllFiles (filter(lambda x: x.endswith(AUTOSCAN_EXTENSIONS) or os.path.isdir(x), [os.path.join(file, x) for x in os.listdir(file)]))
  File "tog.py", line 268, in scanAllFiles
    results = scanAllFiles (filter(lambda x: x.endswith(AUTOSCAN_EXTENSIONS) or os.path.isdir(x), [os.path.join(file, x) for x in os.listdir(file)]))
  File "tog.py", line 276, in scanAllFiles
    result = doFile(file)
  File "tog.py", line 67, in doFile
    ffmpegResults = parseffmpegInfo(getffmpegInfo(filename))
  File "tog.py", line 218, in parseffmpegInfo
    return [videoCodec, parseVideoResolution(videoResolution), parseAudioCodec(audioCodec), parseAudioChannels(audioChannels)]
  File "tog.py", line 245, in parseVideoResolution
    width = int(resolution.partition("x")[0])
ValueError: invalid literal for int() with base 10: '25.00 tb(r)'

Btw: I changed the images in the media dir after having already scanned some files. Now I would like to rescan the old backup files and use the new overlay pictures. Is there an easy way to accomplish that ?

Thanks !
Reply
#63
hotzenpl0tz Wrote:Btw: I changed the images in the media dir after having already scanned some files. Now I would like to rescan the old backup files and use the new overlay pictures. Is there an easy way to accomplish that ?

Thanks !

Do a scan with the -revert option.

And do a new scan with the new images Smile
Reply
#64
Hello,

I try to use your script under Windows XP and every time i try to scan a movie i've got this error

Code:
D:\tog>tog.py -scan "d:\Downloads\Film_freebox\Les_Tontons_flingueurs.avi"
Doing overlays for  d:\Downloads\Film_freebox\Les_Tontons_flingueurs.avi
DEBUG: Command string: ('D:\\ffmpeg.exe', '-i', 'd:\\Downloads\\Film_freebox\\Le
s_Tontons_flingueurs.avi')
DEBUG: ffmpeg output: ['FFmpeg version SVN-r15815, Copyright (c) 2000-2008 Fabri
ce Bellard, et al.\r', '  configuration: --enable-memalign-hack --enable-postpro
c --enable-swscale --enable-gpl --enable-libfaac --enable-libfaad --enable-libgs
m --enable-libmp3lame --enable-libvorbis --enable-libtheora --enable-libx264 --e
nable-libxvid --disable-ffserver --disable-vhook --enable-avisynth --enable-pthr
eads\r', '  libavutil     49.12. 0 / 49.12. 0\r', '  libavcodec    52. 3. 0 / 52
. 3. 0\r', '  libavformat   52.23. 1 / 52.23. 1\r', '  libavdevice   52. 1. 0 /
52. 1. 0\r', '  libswscale     0. 6. 1 /  0. 6. 1\r', '  libpostproc   51. 2. 0
/ 51. 2. 0\r', '  built on Nov 13 2008 10:28:29, gcc: 4.2.4 (TDM-1 for MinGW)\r'
, "Input #0, mpegts, from 'd:\\Downloads\\Film_freebox\\Les_Tontons_flingueurs.a
vi':\r", '  Duration: 02:40:00.12, start: 51784.187456, bitrate: 3197 kb/s\r', '
  Program 8801 \r', '    Stream #0.0[0xa3]: Video: mpeg2video, yuv420p, 480x576
[PAR 8:5 DAR 4:3], 15000 kb/s, 25.00 tb(r)\r', '    Stream #0.1[0x778](fra): Aud
io: mp2, 48000 Hz, stereo, s16, 192 kb/s\r', 'Must supply at least one output fi
le\r', '']
PARSING: FFmpeg version SVN-r15815, Copyright (c) 2000-2008 Fabrice Bellard, et
al.
PARSING: Line didn't match known results format.
PARSING:   configuration: --enable-memalign-hack --enable-postproc --enable-swsc
ale --enable-gpl --enable-libfaac --enable-libfaad --enable-libgsm --enable-libm
p3lame --enable-libvorbis --enable-libtheora --enable-libx264 --enable-libxvid -
-disable-ffserver --disable-vhook --enable-avisynth --enable-pthreads
PARSING: Line didn't match known results format.
PARSING:   libavutil     49.12. 0 / 49.12. 0
PARSING: Line didn't match known results format.
PARSING:   libavcodec    52. 3. 0 / 52. 3. 0
PARSING: Line didn't match known results format.
PARSING:   libavformat   52.23. 1 / 52.23. 1
PARSING: Line didn't match known results format.
PARSING:   libavdevice   52. 1. 0 / 52. 1. 0
PARSING: Line didn't match known results format.
PARSING:   libswscale     0. 6. 1 /  0. 6. 1
PARSING: Line didn't match known results format.
PARSING:   libpostproc   51. 2. 0 / 51. 2. 0
PARSING: Line didn't match known results format.
PARSING:   built on Nov 13 2008 10:28:29, gcc: 4.2.4 (TDM-1 for MinGW)
PARSING: Line didn't match known results format.
PARSING: Input #0, mpegts, from 'd:\Downloads\Film_freebox\Les_Tontons_flingueur
s.avi':
PARSING: Line didn't match known results format.
PARSING:   Duration: 02:40:00.12, start: 51784.187456, bitrate: 3197 kb/s
PARSING: Line didn't match known results format.
PARSING:   Program 8801
PARSING: Line didn't match known results format.
PARSING:     Stream #0.0[0xa3]: Video: mpeg2video, yuv420p, 480x576 [PAR 8:5 DAR
4:3], 15000 kb/s, 25.00 tb(r)
PARSING: Line didn't match known results format.
PARSING:     Stream #0.1[0x778](fra): Audio: mp2, 48000 Hz, stereo, s16, 192 kb/
s
PARSING: Line didn't match known results format.
PARSING: Must supply at least one output file
PARSING: Line didn't match known results format.
PARSING:
PARSING: Line didn't match known results format.
DEBUG: INFO: Scanned d:\Downloads\Film_freebox\Les_Tontons_flingueurs.avi got No
ne
ERROR: unable to scan d:\Downloads\Film_freebox\Les_Tontons_flingueurs.avi with
ffmpeg
Successfully created overlays on 0 of 1 thumbnails (1 failures)

I use the version 0.3.3 of the python script. Did y made a mistake somewhere ?
Reply
#65
I cannot get this to work at all all i get is that damn error that it cant find ffmpeg here is what i have set the py to.

Code:
FFMPEG_PATH = 'c:'
FFMPEG_PROCESS = 'ffmpeg.EXE'
IMAGEMAGICK_PATH = 'c:\ImageMagick'
IMAGEMAGICK_IDENTIFY_PROCESS = 'identify.exe'
IMAGEMAGICK_COMPOSITE_PROCESS = 'composite.exe'
AUTOSCAN_EXTENSIONS = ('.mkv', '.avi')
DEBUG = 1

no matter what i do still the same error even if its on E:\, G:\, O:\ and X:\ all hdds
Reply
#66
If ffmpeg.exe is on the root of c then the path would be c:\ffmpeg.exe

eg
FFMPEG_PATH = 'c:\ffmpeg.exe'
FFMPEG_PROCESS = 'ffmpeg.exe'
IMAGEMAGICK_PATH = 'c:\ImageMagick'
IMAGEMAGICK_IDENTIFY_PROCESS = 'identify.exe'
IMAGEMAGICK_COMPOSITE_PROCESS = 'composite.exe'
AUTOSCAN_EXTENSIONS = ('.mkv', '.avi')
DEBUG = 1

edit: im using linux so i might be wrong. Also try just c:\ as FFMPEG_PATH

cheers
Reply
#67
harryzimm Wrote:If ffmpeg.exe is on the root of c then the path would be c:\ffmpeg.exe

eg
FFMPEG_PATH = 'c:\ffmpeg.exe'
FFMPEG_PROCESS = 'ffmpeg.EXE'
IMAGEMAGICK_PATH = 'c:\ImageMagick'
IMAGEMAGICK_IDENTIFY_PROCESS = 'identify.exe'
IMAGEMAGICK_COMPOSITE_PROCESS = 'composite.exe'
AUTOSCAN_EXTENSIONS = ('.mkv', '.avi')
DEBUG = 1

nup same error driving me mad lol.
Reply
#68
harryzimm Wrote:If ffmpeg.exe is on the root of c then the path would be c:\ffmpeg.exe

eg
FFMPEG_PATH = 'c:\ffmpeg.exe'
FFMPEG_PROCESS = 'ffmpeg.exe'
IMAGEMAGICK_PATH = 'c:\ImageMagick'
IMAGEMAGICK_IDENTIFY_PROCESS = 'identify.exe'
IMAGEMAGICK_COMPOSITE_PROCESS = 'composite.exe'
AUTOSCAN_EXTENSIONS = ('.mkv', '.avi')
DEBUG = 1

edit: im using linux so i might be wrong. Also try just c:\ as FFMPEG_PATH

cheers

As you can see in the output of the debug mod, ffmpeg analyse the movie, but may be the information isn't ine the same format than in the linux one, it could explain the problem.
Reply
#69
Rocky5 Wrote:I cannot get this to work at all all i get is that damn error that it cant find ffmpeg here is what i have set the py to.

Code:
FFMPEG_PATH = 'c:'
FFMPEG_PROCESS = 'ffmpeg.EXE'
IMAGEMAGICK_PATH = 'c:\ImageMagick'
IMAGEMAGICK_IDENTIFY_PROCESS = 'identify.exe'
IMAGEMAGICK_COMPOSITE_PROCESS = 'composite.exe'
AUTOSCAN_EXTENSIONS = ('.mkv', '.avi')
DEBUG = 1

no matter what i do still the same error even if its on E:\, G:\, O:\ and X:\ all hdds

for the FFMPEG_PATH put c:\\
Reply
#70
Tarlak Wrote:for the FFMPEG_PATH put c:\\

nup same again here is a screenshot of the error

Image

thanks any how.
Reply
#71
Ayla: Thanks, totally overlooked the revert option Smile
Reply
#72
hi there thanks for your script Smile

-but i had a problem with mkv 5.1 audio....when scanning an mkv the script gives back "5.1/r" - dont know why, but i had to change the code:

Code:
def parseAudioChannels (channels):

    if channels == "5:1":
        return "5.1"
    elif channels =="5:1\r":
                return "5.1"
    elif channels == "7:1":
        return "7.1"
    else:
        return channels

edit: same for mkv and stereo
Reply
#73
OK guys it looks like there are many different variations of ffmpeg output than the one that I am using, this is causing most of the errors. I will try to address them and release a 0.3.3 proper in a day or 2.

hotzenpl0tz: Turn DEBUG=1 and run it again and paste your output. I will then be able to see what is different in your ffmpeg output and change the regex accordingly.

Tarlak: I will update the regex and this will be fixed in 0.3.3.

Rocky5: I'm not sure, I've never tried it on Windows. Maybe ask somebody here who uses Windows where they have their tog.py and ffmpeg.exe files and what settings they used.

cptplanet: Well I have no idea what 5:1\r means in the ffmpeg output, I guess just another special case that I haven't run into. There was stereo\r too? I'll add them into 0.3.3 which I'll release soon. (was it 5:1\r or 5:1/r ? You have both in your post)
Reply
#74
midgetspy thanks a lot, i try your script under linux, great no problem with it
Reply
#75
midgetspy Wrote:OK guys it looks like there are many different variations of ffmpeg output than the one that I am using, this is causing most of the errors. I will try to address them and release a 0.3.3 proper in a day or 2.

Rocky5: I'm not sure, I've never tried it on Windows. Maybe ask somebody here who uses Windows where they have their tog.py and ffmpeg.exe files and what settings they used.

Cheers for the reply this is what versions of programs and your nice py file

Windows XP SP3

python 3.0 Fixed this version doesn't work you need version 2.6
Image Magick 6.4.7-1
tog.py 0.3.3

tog.py setup
Code:
FFMPEG_PATH = 'c:\' ( C: ) doesn't work ether. no drive for that matter
FFMPEG_PROCESS = 'ffmpeg.exe'
IMAGEMAGICK_PATH = 'c:\ImageMagick'
IMAGEMAGICK_IDENTIFY_PROCESS = 'identify.exe'
IMAGEMAGICK_COMPOSITE_PROCESS = 'composite.exe'
AUTOSCAN_EXTENSIONS = ('.mkv', '.avi')
DEBUG = 1

Fixed it
Reply
  • 1
  • 3
  • 4
  • 5(current)
  • 6
  • 7

Logout Mark Read Team Forum Stats Members Help
Thumbnail Overlay Generator - makeshift HD video flagging script0