I have an image with a white background that I would like to rotate. The rotation, however, creates an unwanted border around the image (not the axes, but the grey outline around the pencil below). How can I remove this border?
fig,ax = plt.subplots(figsize=(8,6))
pencil = mpimg.imread('Pencil.jpg')
pencil = ndimage.rotate(pencil,105)
ax.imshow(pencil,aspect='equal')