Colorization Using Optimization
With everyone talking about the Colorization Using Optimization technology, I thought people without access to MATLAB might enjoy a usable program that employs it.
The MATLAB MCR (installs the shared libraries you need to run compiled MATLAB programs) for Windows is huge, so I made it into a torrent:
Download torrent [83.26MB]
View torrent stats
Windows build:
Download the compiled build here: colorize-win32.zip [1.55MB]
Then:
- Download and run the MATLAB R7SP1 MCR Installer from the torrent.
- Open up a command window, navigate to where you’ve extracted the executable and CTF file, and run “colorize.exe infile.bmp infile_marked.bmp outfile.bmp”
- Wait a while, because this build uses the “exact” solver, it’s rather slow.
If Windows complains that CTF is not a registered file type and it can’t find the proper program, you may need to reboot. You can use the example bitmaps from the source zip linked on the original website if you want to see what input should look like.
Linux build:
Download the compiled build here: colorize-linux.tar.bz2 [3.6MB]
You don’t need the MCR for this build, all the required libraries should be included.
- Put /path/to/colorize-linux/sharedobj on your LD_LIBRARY_PATH with export or setenv. (example:
export LD_LIBRARY_PATH= /home/blah/colorize-linux/sharedobj:$LD_LIBRARY_PATH) - Run “./colorize infile.bmp infile_marked.bmp outfile.bmp”
The torrent is down at the moment, I found another MCR but it was for 7.2, returns an error. Looks like I need 7.1, can you reseed the torrent. Or give a link to the file?
Hi! I’ve managed to make the method work for bmp files. When I tried with gif (animated) files I’ve got an error response
Error in ==> C:\matlabR12\work\getColorExact.m
On line 3 ==> n=size(ntscIm,1); m=size(ntscIm,2);
??? Error using ==> rgb2ntsc
RGBMAP must have 3 columns.
Error in ==> C:\matlabR12\work\colorize.m
On line 16 ==> sgI=rgb2ntsc(gI);
I don’t know what I’m doing wrong.
Now that I have some more bandwidth/storage and the torrent is long dead, here’s a link to the R7SP1 Windows MCR: http://cryptosystem.org/projects/colorize/MCRInstaller.exe
As for animated GIF’s, I’m not sure. I haven’t looked at the code in almost a year, but it’s quite possible that despite the paper talking about tracking regions across image sequences, that the Matlab code only handles bitmaps. You could try breaking up the GIF’s into bitmaps with something like ImageMagick and seeing how that goes.