sdafd commited on
Commit
85b3f51
·
verified ·
1 Parent(s): df81416

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -201,8 +201,8 @@ def process_video(video_path, num_frames):
201
  frame_results = []
202
 
203
  for frame_path in frames:
204
- img_url = f"file://{frame_path}"
205
- nsfw_detected = check_nsfw_final(img_url)
206
  frame_results.append({
207
  "frame_path": frame_path,
208
  "nsfw_detected": nsfw_detected
 
201
  frame_results = []
202
 
203
  for frame_path in frames:
204
+ print(f"https://sdafd-video-nsfw-detect-api.hf.space/file=/tmp/gradio/{frame_path}")
205
+ nsfw_detected = check_nsfw_final(f"https://sdafd-video-nsfw-detect-api.hf.space/file=/tmp/gradio/{frame_path}")
206
  frame_results.append({
207
  "frame_path": frame_path,
208
  "nsfw_detected": nsfw_detected