compare method for Image class

Signed-off-by: easymodo <easymodofrf@gmail.com>