meaculpitt commited on
Commit
71ae3d3
·
verified ·
1 Parent(s): 479cc25

v2 fire weights (yolo26n 960 e2e, 3 classes validator-aligned, synth+sim+dfire+z5atr 25k merged, synth val mAP50=0.6395)

Browse files
Files changed (3) hide show
  1. README.md +9 -4
  2. class_names.txt +1 -1
  3. miner.py +13 -2
README.md CHANGED
@@ -1,4 +1,4 @@
1
- # ScoreVision-Fire — meaculpitt v2
2
 
3
  SN44 fire-detection miner for the `manak0/Detect-fire` element.
4
 
@@ -10,10 +10,15 @@ SN44 fire-detection miner for the `manak0/Detect-fire` element.
10
  - **Output shape**: `[1, 300, 6]` (xyxy, conf, cls)
11
  - **Latency**: ~35 ms p95 on RTX 4090 (fits the 50 ms gate)
12
 
13
- ## Classes (validator order, per HF class_names.txt)
14
  - 0: fire
15
- - 1: fire extinguisher
16
- - 2: smoke
 
 
 
 
 
17
 
18
  ## Training
19
  - 22,796 training images (validator-synth + Simuletic + D-Fire + z5atr, SHA1 deduped)
 
1
+ # ScoreVision-Fire — meaculpitt v2.1
2
 
3
  SN44 fire-detection miner for the `manak0/Detect-fire` element.
4
 
 
10
  - **Output shape**: `[1, 300, 6]` (xyxy, conf, cls)
11
  - **Latency**: ~35 ms p95 on RTX 4090 (fits the 50 ms gate)
12
 
13
+ ## Classes (validator GT order, NOT the published class_names.txt order)
14
  - 0: fire
15
+ - 1: smoke
16
+ - 2: fire extinguisher
17
+
18
+ Verified by audit of alfred8995/fire001 (scores 1.00) and navierstocks/fire
19
+ (scores 0.96): both use [fire, smoke, fire_extinguisher] and the validator's
20
+ GT order matches. Our model was trained with [fire, fire_ext, smoke]; miner.py
21
+ applies cls_remap=[0,2,1] to translate model output to validator index.
22
 
23
  ## Training
24
  - 22,796 training images (validator-synth + Simuletic + D-Fire + z5atr, SHA1 deduped)
class_names.txt CHANGED
@@ -1,3 +1,3 @@
1
  fire
2
- fire extinguisher
3
  smoke
 
 
1
  fire
 
2
  smoke
3
+ fire extinguisher
miner.py CHANGED
@@ -40,8 +40,19 @@ class TVFrameResult(BaseModel):
40
  class Miner:
41
  def __init__(self, path_hf_repo) -> None:
42
  self.path_hf_repo = Path(path_hf_repo)
43
- self.class_names = ["fire", "fire extinguisher", "smoke"]
44
- self.cls_remap = np.arange(3, dtype=np.int32)
 
 
 
 
 
 
 
 
 
 
 
45
 
46
  try:
47
  ort.preload_dlls()
 
40
  class Miner:
41
  def __init__(self, path_hf_repo) -> None:
42
  self.path_hf_repo = Path(path_hf_repo)
43
+ # Validator's actual GT class order is [fire, smoke, fire extinguisher]
44
+ # verified by audit of alfred8995/fire001 (scores 1.00) and
45
+ # navierstocks/fire (scores 0.96), both using this order. The published
46
+ # manak0/Detect-fire class_names.txt list [fire, fire_ext, smoke] does
47
+ # NOT match the actual scoring index.
48
+ # Our model was trained with [fire, fire_ext, smoke] (cls=1=ext, cls=2=smoke).
49
+ # cls_remap translates model output index → validator GT index.
50
+ self.class_names = ["fire", "smoke", "fire extinguisher"]
51
+ model_class_order = ["fire", "fire extinguisher", "smoke"]
52
+ self.cls_remap = np.array(
53
+ [self.class_names.index(n) for n in model_class_order],
54
+ dtype=np.int32,
55
+ ) # → [0, 2, 1]: model cls 0→0, 1→2, 2→1
56
 
57
  try:
58
  ort.preload_dlls()