Minor changes
PIL image creation is added
functions for image creation are improved