Matplotlib draw Figures during ginput()

217 Views Asked by At

I am using ginput on an image. I would like to extend the ginput function a little, such that when I click somewhere, it will immediately draw a box with specific dimensions around the selected point. Is there a way to update the image every time after I clicked somewhere?

1

There are 1 best solutions below

0
On

I had a similar problem, and found the solution in this post - you can force an update using the pause command after you have plotted your box, this forces an update:

plt.pause(0.05)