N00bML commited on
Commit
fd036b3
·
verified ·
1 Parent(s): b08f1f9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -7
app.py CHANGED
@@ -84,9 +84,9 @@ if os.path.exists('best_model.pth'):
84
  model.load_state_dict(checkpoint['model_state_dict'])
85
  print("✓ Trained model loaded successfully!")
86
  except Exception as e:
87
- print(f"⚠️ Could not load trained weights: {str(e)}")
88
  else:
89
- print("⚠️ No trained model found. Using random initialization.")
90
 
91
  model.eval()
92
 
@@ -336,11 +336,11 @@ with gr.Blocks(css=css, theme=gr.themes.Soft()) as demo:
336
  gr.Markdown("### Upload Video")
337
 
338
  with gr.Group(elem_id="upload-zone"):
339
- video_input = gr.Video(
340
- label="",
341
- sources=["upload"],
342
- show_label=False
343
- )
344
 
345
  # Add a second video component for playback
346
  video_preview = gr.Video(
 
84
  model.load_state_dict(checkpoint['model_state_dict'])
85
  print("✓ Trained model loaded successfully!")
86
  except Exception as e:
87
+ print(f" Could not load trained weights: {str(e)}")
88
  else:
89
+ print(" No trained model found. Using random initialization.")
90
 
91
  model.eval()
92
 
 
336
  gr.Markdown("### Upload Video")
337
 
338
  with gr.Group(elem_id="upload-zone"):
339
+ video_input = gr.File(
340
+ label="Drop video file here or click to upload",
341
+ file_types=["video"],
342
+ type="filepath"
343
+ )
344
 
345
  # Add a second video component for playback
346
  video_preview = gr.Video(