Results are getting black color. Is it need to uncomment the line before saving to get proper result # imgtest = imgtest * 255.0 # imgtest.astype(np.uint8) save_images(imgtest, [8,8] ,newPoke_path + '/epoch' + str(i) + '.jpg')