Spaces:
No application file
No application file
Update app.py
Browse files
app.py
CHANGED
|
@@ -993,6 +993,7 @@ def create_interface():
|
|
| 993 |
|
| 994 |
return iface
|
| 995 |
|
|
|
|
| 996 |
# --- Main Execution ---
|
| 997 |
if __name__ == "__main__":
|
| 998 |
try:
|
|
@@ -1018,12 +1019,10 @@ if __name__ == "__main__":
|
|
| 1018 |
# Create and launch interface
|
| 1019 |
iface = create_interface()
|
| 1020 |
iface.launch(
|
| 1021 |
-
share=False,
|
| 1022 |
server_name="0.0.0.0", # Allow connections from any IP
|
| 1023 |
server_port=7860, # Default Gradio port
|
| 1024 |
-
show_error=True
|
| 1025 |
-
enable_queue=True, # Enable queuing for long-running tasks
|
| 1026 |
-
max_threads=4 # Limit concurrent processing
|
| 1027 |
)
|
| 1028 |
|
| 1029 |
except Exception as e:
|
|
|
|
| 993 |
|
| 994 |
return iface
|
| 995 |
|
| 996 |
+
# --- Main Execution ---
|
| 997 |
# --- Main Execution ---
|
| 998 |
if __name__ == "__main__":
|
| 999 |
try:
|
|
|
|
| 1019 |
# Create and launch interface
|
| 1020 |
iface = create_interface()
|
| 1021 |
iface.launch(
|
| 1022 |
+
share=False, # Set to True if you want to create a public link
|
| 1023 |
server_name="0.0.0.0", # Allow connections from any IP
|
| 1024 |
server_port=7860, # Default Gradio port
|
| 1025 |
+
show_error=True # Show errors in the interface
|
|
|
|
|
|
|
| 1026 |
)
|
| 1027 |
|
| 1028 |
except Exception as e:
|