compress images with optimg, work in progress