SkyGuardAI commited on
Commit
1b50ade
·
verified ·
1 Parent(s): 06afbb1

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -8
app.py CHANGED
@@ -15,7 +15,7 @@ warnings.filterwarnings('ignore')
15
  # ============================================================
16
  print("Loading YOLOv11 model from Hugging Face Hub...")
17
  model_path = hf_hub_download(
18
- repo_id="SkyGuardAI/drone-detection-yolov11",
19
  filename="best.pt"
20
  )
21
  model = YOLO(model_path)
@@ -258,15 +258,15 @@ def drone_detection_pipeline(input_image):
258
  return blank, blank, error_msg
259
 
260
  # ============================================================
261
- # 6. SKYGUARD INTERFACE (WHITE BACKGROUND, DARK BLUE BUTTONS)
262
  # ============================================================
263
  custom_css = """
264
- /* White background for main container and body */
265
  .gradio-container, body, .gradio-container .main {
266
  background: #ffffff !important;
267
  font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', sans-serif;
268
  }
269
- /* Header styling - dark text, centered */
270
  .skyguard-header {
271
  text-align: center;
272
  padding: 1.5rem 0 0.5rem 0;
@@ -291,7 +291,7 @@ custom_css = """
291
  color: #2c5282;
292
  margin-top: 0.5rem;
293
  }
294
- /* Buttons - dark blue */
295
  .gr-button-primary {
296
  background: #0a2b4e !important;
297
  border: none !important;
@@ -308,7 +308,7 @@ custom_css = """
308
  transform: scale(1.02);
309
  box-shadow: 0 4px 12px rgba(10,43,78,0.3);
310
  }
311
- /* Tabs styling - simple and clean */
312
  .gr-tabs .tab-nav button {
313
  background-color: #eef2f5 !important;
314
  color: #0a2b4e !important;
@@ -321,7 +321,7 @@ custom_css = """
321
  background-color: #0a2b4e !important;
322
  color: white !important;
323
  }
324
- /* Input and output boxes - light grey border */
325
  .gr-box, .gr-form, .gr-input, .gr-panel {
326
  background-color: #f9fafb !important;
327
  border: 1px solid #d1d5db !important;
@@ -332,7 +332,7 @@ label, .gr-form label {
332
  color: #1e293b !important;
333
  font-weight: 500 !important;
334
  }
335
- /* Markdown text (report) */
336
  .gr-markdown p, .gr-markdown {
337
  color: #1e293b;
338
  }
 
15
  # ============================================================
16
  print("Loading YOLOv11 model from Hugging Face Hub...")
17
  model_path = hf_hub_download(
18
+ repo_id="SkyGuardAI/drone-detection-yolov11",
19
  filename="best.pt"
20
  )
21
  model = YOLO(model_path)
 
258
  return blank, blank, error_msg
259
 
260
  # ============================================================
261
+ # 6. SKYGUARD INTERFACE (WHITE BACKGROUND, DARK BLUE COLORS)
262
  # ============================================================
263
  custom_css = """
264
+ /* White background */
265
  .gradio-container, body, .gradio-container .main {
266
  background: #ffffff !important;
267
  font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', sans-serif;
268
  }
269
+ /* Header styling - dark blue text */
270
  .skyguard-header {
271
  text-align: center;
272
  padding: 1.5rem 0 0.5rem 0;
 
291
  color: #2c5282;
292
  margin-top: 0.5rem;
293
  }
294
+ /* Buttons - dark blue, no purple */
295
  .gr-button-primary {
296
  background: #0a2b4e !important;
297
  border: none !important;
 
308
  transform: scale(1.02);
309
  box-shadow: 0 4px 12px rgba(10,43,78,0.3);
310
  }
311
+ /* Tabs - clean, no purple */
312
  .gr-tabs .tab-nav button {
313
  background-color: #eef2f5 !important;
314
  color: #0a2b4e !important;
 
321
  background-color: #0a2b4e !important;
322
  color: white !important;
323
  }
324
+ /* Input/output boxes */
325
  .gr-box, .gr-form, .gr-input, .gr-panel {
326
  background-color: #f9fafb !important;
327
  border: 1px solid #d1d5db !important;
 
332
  color: #1e293b !important;
333
  font-weight: 500 !important;
334
  }
335
+ /* Markdown text */
336
  .gr-markdown p, .gr-markdown {
337
  color: #1e293b;
338
  }