samxkevin commited on
Commit
9b74a94
Β·
verified Β·
1 Parent(s): ed4d016

Changes made to the website

Browse files
Files changed (3) hide show
  1. README.md +43 -18
  2. app.py +0 -0
  3. requirements.txt +26 -11
README.md CHANGED
@@ -1,26 +1,51 @@
1
  ---
2
  title: SceneSolver
3
- author: samxkevin
 
 
4
  sdk: gradio
5
- sdk_version: 5.49.1
 
6
  app_file: app.py
7
- license: mit
8
- short_description: Multimodal surveillance analysis and evidence synthesis
 
9
  ---
10
 
11
  # SceneSolver
12
 
13
- SceneSolver is a multimodal surveillance-analysis system. The public demo exposes the inference pipeline while the trained model assets remain in the author's Hugging Face repositories.
14
-
15
- ## Pipeline
16
-
17
- AE anomaly signal β†’ TimeSformer binary gate β†’ TimeSformer multi-class classification β†’ YOLO weapon detection β†’ audio features β†’ tracking/behavior extraction β†’ fusion reasoning β†’ RL3033 temporal reasoning β†’ optional LLaVA contextual explanation.
18
-
19
- ## Model sources
20
-
21
- - `samxkevin/scenesolver-assets`
22
- - `samxkevin/SceneDescriptionModel`
23
-
24
- ## Notes
25
-
26
- The system is an experimental/research project. Results are not definitive conclusions and require human review.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  title: SceneSolver
3
+ emoji: πŸ•΅οΈ
4
+ colorFrom: gray
5
+ colorTo: red
6
  sdk: gradio
7
+ sdk_version: "4.44.0"
8
+ python_version: "3.10"
9
  app_file: app.py
10
+ pinned: false
11
+ short_description: Nine-stage forensic video analysis agent (SceneSolver)
12
+ suggested_hardware: zero-a10g
13
  ---
14
 
15
  # SceneSolver
16
 
17
+ A nine-stage forensic video analysis pipeline (AutoEncoder anomaly signal,
18
+ TimeSformer binary + multi-class classification, YOLO weapon detection, audio
19
+ feature extraction, motion tracking, a fusion reasoning layer, an RL3033
20
+ temporal-reasoning agent, and a LLaVA-based contextual explanation stage),
21
+ wrapped in a Gradio interface with an agentic "Sherl0ck" escalation layer.
22
+
23
+ Model assets: `samxkevin/scenesolver-assets` (pipeline weights) and
24
+ `samxkevin/SceneDescriptionModel` (the VLM used by Stage 8 / LLaVA).
25
+
26
+ ## Running on ZeroGPU β€” before you deploy
27
+
28
+ - **Creating** a ZeroGPU Space requires a Hugging Face **PRO** personal account
29
+ or a Team/Enterprise organization. (Anyone can *use* a public ZeroGPU Space
30
+ for free once it exists β€” the PRO/Enterprise requirement is only for the
31
+ owner who creates it.)
32
+ - Setting `suggested_hardware: zero-a10g` above is a display hint only. You
33
+ still need to explicitly select **ZeroGPU** in the Space's
34
+ **Settings β†’ Hardware** panel for it to actually run there.
35
+ - `COHERE_API_KEY` must be set as a **repository secret**
36
+ (Settings β†’ Variables and secrets) β€” it is read from the environment and is
37
+ no longer hardcoded in the source (see the security note below).
38
+ - The `@spaces.GPU(duration=300)` timeout on the Analyse pipeline is a
39
+ starting estimate covering AutoEncoder + TimeSformer (x2) + YOLO + audio +
40
+ tracking + fusion + RL3033 + optional LLaVA. Watch the Space logs after the
41
+ first real run and raise/lower `duration` in `app.py` to match observed
42
+ runtime.
43
+ - Verify `samxkevin/scenesolver-assets` and `samxkevin/SceneDescriptionModel`
44
+ are public repos. If either is private, add an `HF_TOKEN` repository secret
45
+ with read access, or the Space will fail to download weights at startup.
46
+
47
+ ## Security note
48
+
49
+ The uploaded source notebook contained a hardcoded, live Cohere API key. It
50
+ has been removed from this port. **That key should be rotated in the Cohere
51
+ dashboard**, since it was exposed in plaintext in the original file.
app.py CHANGED
The diff for this file is too large to render. See raw diff
 
requirements.txt CHANGED
@@ -1,20 +1,35 @@
1
- gradio>=5.0,<6.0
2
- spaces>=0.38.0
3
- huggingface_hub>=0.34.0
4
- numpy
 
 
 
 
 
 
 
 
 
 
 
 
5
  opencv-python-headless
6
- torch
7
- torchvision
8
- transformers>=4.45
9
- accelerate
10
- safetensors
11
  Pillow
12
  tqdm
13
- matplotlib
14
  reportlab
 
15
  stable-baselines3
16
  ultralytics
17
  lap
 
18
  librosa
19
- openai-whisper
 
20
  cohere>=5.0.0
 
 
 
 
1
+ # SceneSolver β€” Hugging Face Space (ZeroGPU) requirements
2
+ # Derived directly from the imports actually used in app.py (source: NewChecker.ipynb).
3
+ # NOTE: torch/torchvision versions should be checked against the current
4
+ # ZeroGPU CUDA build before first deploy β€” see
5
+ # https://huggingface.co/docs/hub/spaces-zerogpu (the backing GPU/CUDA image
6
+ # changes over time, and torch must match the wheel it was built against).
7
+
8
+ spaces
9
+ gradio>=4.44.0
10
+
11
+ torch>=2.1.0
12
+ torchvision>=0.16.0
13
+
14
+ transformers>=4.40.0
15
+ huggingface_hub>=0.23.0
16
+
17
  opencv-python-headless
18
+ numpy
19
+ matplotlib
 
 
 
20
  Pillow
21
  tqdm
22
+
23
  reportlab
24
+
25
  stable-baselines3
26
  ultralytics
27
  lap
28
+
29
  librosa
30
+ soundfile
31
+
32
  cohere>=5.0.0
33
+ liquid-audio
34
+
35
+ requests