implement shift
add some code for image import