Wildlife Detector - Detectron2

A Faster R-CNN model with optimized Inception v1 backbone for detecting 10 wildlife species.

Classes

  • Antelope
  • Buffalo
  • Elephant
  • Giraffe
  • Gorilla
  • Leopard
  • Lion
  • Rhino
  • Wolf
  • Zebra

Performance

Metric Value
AP 45.7%
AP50 81.8%
AP75 47.7%

Per-Class Performance (AP)

Animal AP Animal AP
Buffalo 58.9% Elephant 58.5%
Gorilla 51.2% Leopard 49.4%
Wolf 48.0% Antelope 46.4%
Rhino 44.1% Zebra 43.7%
Lion 31.9% Giraffe 24.5%

Usage

import torch
from detectron2.config import get_cfg
from detectron2.engine import DefaultPredictor
from detectron2 import model_zoo
from huggingface_hub import hf_hub_download

# Download model
model_path = hf_hub_download(
    repo_id="mynane/inception-wildlife-detector-detectron2", 
    filename="pytorch_model.bin"
)

# Setup config
cfg = get_cfg()
cfg.merge_from_file(model_zoo.get_config_file("COCO-Detection/faster_rcnn_R_50_C4_3x.yaml"))
cfg.MODEL.WEIGHTS = model_path
cfg.MODEL.ROI_HEADS.NUM_CLASSES = 10
cfg.MODEL.ROI_HEADS.SCORE_THRESH_TEST = 0.5

# Create predictor
predictor = DefaultPredictor(cfg)

# Inference
import cv2
image = cv2.imread("wildlife_image.jpg")
outputs = predictor(image)

Model Details

  • Architecture: Faster R-CNN with Optimized Inception v1 backbone
  • Framework: Detectron2
  • Input Size: 800x1333 (min x max)
  • Confidence Threshold: 0.5
Downloads last month
62
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Evaluation results