I have a python code like this:
import matplotlib.pyplot as plt
import matplotlib.image as mpimg
img = mpimg.imread('xxx.png')
fig = plt.figure(figsize=(8,10))
ax1 = fig.add_axes([0., 0.92, 0.1, 0.08])
ax1.imshow(img)
ax1.axvline(0.5, 0, 1, color='gray')
plt.show()
Running this code shows the img in the axes area. However, the vline does not show up.
If I remove the line: ax1.imshow(img)
and run again I do see the vline.
Any suggestion?