avi index breaker
Switch branches/tags
Nothing to show
Clone or download
itsKaspar added -ss and -t like in ffmpeg
changed -ign to -ss
and added -t
just like ffmpeg command line 
-ss defines start of glitch
-t defines how long you want to glitch
both of these are in frames
Latest commit 3247ba7 Dec 13, 2018
Type Name Latest commit message Commit time
Failed to load latest commit information.
LICENSE Initial commit Mar 27, 2017
README.md jiggle and overlapped modes Oct 12, 2017
automato.py Update automato.py Oct 11, 2018
bake.py Update bake.py Feb 12, 2018
prepcmd.txt Create prepcmd.txt Oct 11, 2017
tomato.py added -ss and -t like in ffmpeg Dec 13, 2018



tomato is a python script and datamoshing kit for AVI files

It was designed to operate video frame ordering, substraction and duplication.

  • ikill - destroys all of the i-frames
  • iswap - retreats all of the i-frames one sequence earlier [under construction: whole mode not programmed]
  • bloom - duplicates c times p-frame number n
  • pulse - duplicates groups of c p-frames every n frames
  • shuffle - every p-frame gets a p % chance to be shuffled [under construction: -p not available]
  • overlapped - copy group of c frames taken from every nth position
  • jiggle - take frame from around current position. n parameter is spread size

regardless of the option used the 1st iframe of the video will remain unaffected

Examples of usage

python tomato.py -i input.avi -m ikill output.avi

Takes out all iframes except for the first one

python tomato.py -i input.avi -m bloom -c 50 -n 100 output.avi

Duplicate 50 times the 100th frame

python tomato.py -i input.avi -m pulse -c 5 -n 10 output.avi

Duplicates 5 times a frame every 10 frame

python tomato.py -i input.avi -m shuffle output.avi

Shuffles all of the frames in the video

python tomato.py -i input.avi -m overlapped -c 4 -n 2 output.avi

Copy 4 frames taken starting from every 2nd frame. [1 2 3 4 3 4 5 6 5 6 7 8 7 8...]

Why did we develop tomato ?

Most datamoshing utilities out there are pretty cool but restrain you into using specific codecs or just can't handle big files and/or large resolutions.

tomato is different in the sense that

  • it can be used with any AVI file regardless of the codec/resolution
  • it doesn't corrupt the video content, just the stream
  • it's a lot faster than anything else

However there is still room for improvement

  • it can't act on AVI files that do not have an index (which means I should add options to force an index creation, or divide a video if it is over >4GB)

So how does it work ?

Basically when you input an AVI file, it ignores the content and skips to the frame index to operate on it. Video players reading the resulting file through the index will interpret and glitch the video on the fly.

For practicles purposes sounds frames are all deleted

How should you use it

No dependencies are needed to run tomato but I recommend preparing your AVI files with ffmpeg and the codec library of your choice. To read your glitched files I recommend VLC or Xine if you're under Linux. Both are great for visualazing content (especially xine for the shuffle mode) but keep in mind you should always be experimenting and using different visualizers or tools to bake your files. If you have any questions or ideas feel free to send me an email at kaspar.ravel@gmail.com