eienmojiki commited on
Commit
b4e799c
·
verified ·
1 Parent(s): 96bd4e6

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -6
app.py CHANGED
@@ -26,12 +26,10 @@ def create_app():
26
 
27
  # Thêm các control vào UI
28
  control_components = []
29
- for filter_name, control_list in controls.items():
30
- group = gr.Group(visible=filter_name == "Original") # Create group here, outside with
31
- filter_groups[filter_name] = group # Store group
32
- with group: # Put controls inside the group
33
- for component in control_list:
34
- control_components.append(component) # Collect sliders for event handling
35
 
36
  with gr.Column():
37
  output_image = gr.Image(label="Filtered Image")
 
26
 
27
  # Thêm các control vào UI
28
  control_components = []
29
+ filter_groups = controls # Assign controls directly to filter_groups
30
+ for filter_name, group in filter_groups.items():
31
+ for component in group.children: # Iterate over children of the group
32
+ control_components.append(component) # Collect sliders for event handling
 
 
33
 
34
  with gr.Column():
35
  output_image = gr.Image(label="Filtered Image")