Update app.py
Browse files
app.py
CHANGED
|
@@ -787,7 +787,12 @@ def process_image(input_image):
|
|
| 787 |
print(" ✓ Professional UI with branding")
|
| 788 |
print("=" * 80)
|
| 789 |
|
| 790 |
-
# Launch the application
|
| 791 |
if __name__ == "__main__":
|
| 792 |
print("Launching Gradio interface...")
|
| 793 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 787 |
print(" ✓ Professional UI with branding")
|
| 788 |
print("=" * 80)
|
| 789 |
|
| 790 |
+
# Launch the application - HuggingFace Spaces compatible
|
| 791 |
if __name__ == "__main__":
|
| 792 |
print("Launching Gradio interface...")
|
| 793 |
+
import sys
|
| 794 |
+
if "google.colab" in sys.modules:
|
| 795 |
+
demo.launch(debug=True)
|
| 796 |
+
else:
|
| 797 |
+
# For HuggingFace Spaces
|
| 798 |
+
demo.launch(server_name="0.0.0.0", server_port=7860)
|