Added DEBUG preprocessing.
Added automatically opening the picture file on DEBUG.