broadfield-dev commited on
Commit
786f81b
·
verified ·
1 Parent(s): b977bdd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -11,12 +11,12 @@ from bs4 import BeautifulSoup
11
 
12
  # Default parameters
13
  low_int = 10
14
- high_int = 150
15
  edge_thresh = 100
16
- accum_thresh = 45
17
- center_tol = 30
18
- morph_dia = 3
19
- min_rad = 70
20
 
21
  def fetch_sdo_images(max_images, size="1024by960", tool="ccor1"):
22
  """Fetch SDO images from NOAA URL directory."""
@@ -301,7 +301,7 @@ with gr.Blocks(title="Solar CME Detection") as demo:
301
  upper_bound = gr.Slider(minimum=0, maximum=255, value=high_int, step=1, label="Upper Intensity Bound (0-255)")
302
  param1 = gr.Slider(minimum=10, maximum=200, value=edge_thresh, step=1, label="Hough Param1 (Edge Threshold)")
303
  param2 = gr.Slider(minimum=1, maximum=50, value=accum_thresh, step=1, label="Hough Param2 (Accumulator Threshold)")
304
- center_tolerance = gr.Slider(minimum=10, maximum=100, value=center_tol, step=1, label="Center Tolerance (Pixels)")
305
  morph_iterations = gr.Slider(minimum=1, maximum=5, value=morph_dia, step=1, label="Morphological Dilation Iterations")
306
  min_rad = gr.Slider(minimum=1, maximum=100, value=min_rad, step=1, label="Minimum Circle Radius")
307
  display_mode = gr.Dropdown(
 
11
 
12
  # Default parameters
13
  low_int = 10
14
+ high_int = 255
15
  edge_thresh = 100
16
+ accum_thresh = 20
17
+ center_tol = 60
18
+ morph_dia = 2
19
+ min_rad = 40
20
 
21
  def fetch_sdo_images(max_images, size="1024by960", tool="ccor1"):
22
  """Fetch SDO images from NOAA URL directory."""
 
301
  upper_bound = gr.Slider(minimum=0, maximum=255, value=high_int, step=1, label="Upper Intensity Bound (0-255)")
302
  param1 = gr.Slider(minimum=10, maximum=200, value=edge_thresh, step=1, label="Hough Param1 (Edge Threshold)")
303
  param2 = gr.Slider(minimum=1, maximum=50, value=accum_thresh, step=1, label="Hough Param2 (Accumulator Threshold)")
304
+ center_tolerance = gr.Slider(minimum=10, maximum=300, value=center_tol, step=1, label="Center Tolerance (Pixels)")
305
  morph_iterations = gr.Slider(minimum=1, maximum=5, value=morph_dia, step=1, label="Morphological Dilation Iterations")
306
  min_rad = gr.Slider(minimum=1, maximum=100, value=min_rad, step=1, label="Minimum Circle Radius")
307
  display_mode = gr.Dropdown(