cali_fire_risk / README.md
gdurkin's picture
Update README with YAML on main (homepage card)
2e5c93b verified
metadata
pipeline_tag: image-segmentation
library_name: transformers
base_model: gdurkin/cdl_mask2former_v3_mspc
license: apache-2.0
tags:
  - mask2former
  - semantic-segmentation
  - image-segmentation
  - remote-sensing
  - aerial-imagery
  - wildfire-risk
datasets:
  - gdurkin/fire_risk_properties
metrics:
  - mean_iou
  - fw_iou
model-index:
  - name: cali_fire_risk
    results:
      - task:
          type: image-segmentation
          name: Image Segmentation
        dataset:
          name: Fire Risk Properties (NAIP 512px)
          type: gdurkin/fire_risk_properties
        metrics:
          - type: mean_iou
            value: 0.460028
          - type: fw_iou
            value: 0.580636

Fire-risk Superbuckets Mask2Former (fine-tuned)

Base: gdurkin/cdl_mask2former_v3_mspc
Labels: ['background', 'road_paved', 'dirt_gravel', 'grass_dry', 'grass_healthy', 'vegetation', 'water', 'building_all']

This repo hosts a Mask2Former model fine-tuned on NAIP 512×512 chips for wildfire-related landcover “superbuckets.”

  • Checkpoint source: gdurkin/cali_fire_risk@best-20250920_160245
  • Export time: 2025-09-20 16:40:47Z

Evaluation

  • mIoU: 0.4600
  • FWIoU (frequency-weighted IoU): 0.5806

FWIoU is the mean IoU weighted by each class's pixel frequency: sum_c f_c * IoU_c. It emphasizes overall pixelwise accuracy while still penalizing mistakes.

Per-class IoU

id label IoU support
0 background 0.0000 172666
1 road_paved 0.6855 80261762
2 dirt_gravel 0.3848 57473062
3 grass_dry 0.2654 22281420
4 grass_healthy 0.4975 40281607
5 vegetation 0.6658 47722088
6 water 0.4366 3090841
7 building_all 0.7445 59095050

Usage

import torch
from transformers import AutoImageProcessor, Mask2FormerForUniversalSegmentation

repo = "gdurkin/cali_fire_risk"
rev  = "best-20250920_160245"  # or a tag like "v0.1"

processor = AutoImageProcessor.from_pretrained(repo, revision=rev)
model = Mask2FormerForUniversalSegmentation.from_pretrained(repo, revision=rev).eval()
device = "cuda" if torch.cuda.is_available() else "cpu"
model.to(device)

# pv: FloatTensor[B,3,H,W] normalized per `processor`
with torch.no_grad():
    out = model(pixel_values=pv.to(device))
pred = processor.post_process_semantic_segmentation(out, target_sizes=[(H, W)])[0]