image_optim Wed Jan 16 23:51:04 CET 2013
move initial checks to a function, remove unused MAX_CORES var.