Solved by ptrblck in post #4 
              
              
                Thanks for the code! 
I’ve debugged it and it seems PIL is unable to properly create an image out of the np array. 
In fact Image.from_array(j, mode="RGB") creates the same interleaved output. 
You could fix it via: 
images_data=[]
for j in padded:
    j = j * 255.
    j = j.astype(np.uint8)
    ima…