Spaces:
Sleeping
Sleeping
adding security
Browse files
app.py
CHANGED
@@ -113,9 +113,12 @@ with gr.Blocks(theme='sudeepshouche/minimalist') as demo:
|
|
113 |
classify_image_button.click(classify_image, inputs=[input_image,drop_2], outputs=class_predicted)
|
114 |
#classify_segmented_button.click(classify_image, inputs=[segmented_image,drop_2], outputs=class_predicted)
|
115 |
|
116 |
-
|
117 |
|
118 |
-
|
|
|
|
|
|
|
119 |
|
120 |
|
121 |
|
|
|
113 |
classify_image_button.click(classify_image, inputs=[input_image,drop_2], outputs=class_predicted)
|
114 |
#classify_segmented_button.click(classify_image, inputs=[segmented_image,drop_2], outputs=class_predicted)
|
115 |
|
116 |
+
demo.queue()
|
117 |
|
118 |
+
if os.getenv('SYSTEM') == 'spaces':
|
119 |
+
demo.launch(width='40%',auth=(os.environ.get('USERNAME'), os.environ.get('PASSWORD')))
|
120 |
+
else:
|
121 |
+
demo.launch()
|
122 |
|
123 |
|
124 |
|