Fix a lot of bugs and add dataImage