Sephfox commited on
Commit
621e2cf
·
verified ·
1 Parent(s): fec1916

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -511,7 +511,7 @@ if uploaded_file is not None:
511
  clicked_points = []
512
 
513
  def onclick(event):
514
- nonlocal touch_x, touch_y # Ensure we update the outer variables
515
  if event.xdata and event.ydata:
516
  touch_x, touch_y = int(event.xdata), int(event.ydata)
517
  clicked_points.append((touch_x, touch_y))
 
511
  clicked_points = []
512
 
513
  def onclick(event):
514
+ global touch_x, touch_y # Use global to update the outer variables
515
  if event.xdata and event.ydata:
516
  touch_x, touch_y = int(event.xdata), int(event.ydata)
517
  clicked_points.append((touch_x, touch_y))