🚀 rt-detr-finetuned-for-satellite-image-roofs-detection
This model is designed for roof detection in remote sensing tasks, offering high - precision object detection capabilities for satellite images.
🚀 Quick Start
Use the code below to get started with the model.
from transformers import AutoModelForObjectDetection, AutoImageProcessor
import torch
import cv2
image_path=YOUR_IMAGE_PATH
image = cv2.imread(image_path)
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
model = AutoModelForObjectDetection.from_pretrained("Yifeng-Liu/rt-detr-finetuned-for-satellite-image-roofs-detection")
image_processor = AutoImageProcessor.from_pretrained("Yifeng-Liu/rt-detr-finetuned-for-satellite-image-roofs-detection")
CONFIDENCE_TRESHOLD = 0.5
with torch.no_grad():
model.to(device)
inputs = image_processor(images=image, return_tensors='pt').to(device)
outputs = model(**inputs)
target_sizes = torch.tensor([image.shape[:2]]).to(device)
results = image_processor.post_process_object_detection(
outputs=outputs,
threshold=CONFIDENCE_TRESHOLD,
target_sizes=target_sizes
)[0]
✨ Features
- Task - Specific: Specialized for object detection in remote sensing tasks, especially for roof detection in satellite images.
- Metrics - Driven: Evaluated with metrics such as Average Precision (AP) and Average Recall (AR) to ensure high - quality performance.
📚 Documentation
Model Details
Model Description
- Model type: Object Detection for Remote Sensing task.
- License: MIT
Model Sources
Limitations
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model.
Model Information
Property |
Details |
Base Model |
PekingU/rtdetr_r101vd_coco_o365 |
Datasets |
keremberke/satellite-building-segmentation |
Library Name |
transformers |
License |
mit |
Metrics |
Average Precision (AP), Average Recall (AR) |
Pipeline Tag |
object - detection |
Tags |
remote sensing, object detection |
Model Results
- Model Name: rt - detr - finetuned - for - satellite - image - roofs - detection
- Task Type: object - detection
- Dataset: keremberke/satellite - building - segmentation (image - segmentation)
Metric Type |
Value |
Metric Name |
AP (IoU = 0.50:0.95) |
0.434 |
AP @ IoU = 0.50:0.95 | area = all | maxDets = 100 |
AP (IoU = 0.50) |
0.652 |
AP @ IoU = 0.50 | area = all | maxDets = 100 |
AP (IoU = 0.75) |
0.464 |
AP @ IoU = 0.75 | area = all | maxDets = 100 |
AP (IoU = 0.50:0.95) small objects |
0.248 |
AP @ IoU = 0.50:0.95 | area = small | maxDets = 100 |
AP (IoU = 0.50:0.95) medium objects |
0.510 |
AP @ IoU = 0.50:0.95 | area = medium | maxDets = 100 |
AP (IoU = 0.50:0.95) large objects |
0.632 |
AP @ IoU = 0.50:0.95 | area = large | maxDets = 100 |
AR (IoU = 0.50:0.95) maxDets = 1 |
0.056 |
AR @ IoU = 0.50:0.95 | area = all | maxDets = 1 |
AR (IoU = 0.50:0.95) maxDets = 10 |
0.328 |
AR @ IoU = 0.50:0.95 | area = all | maxDets = 10 |
AR (IoU = 0.50:0.95) maxDets = 100 |
0.519 |
AR @ IoU = 0.50:0.95 | area = all | maxDets = 100 |
AR (IoU = 0.50:0.95) small objects |
0.337 |
AR @ IoU = 0.50:0.95 | area = small | maxDets = 100 |
AR (IoU = 0.50:0.95) medium objects |
0.601 |
AR @ IoU = 0.50:0.95 | area = medium | maxDets = 100 |
AR (IoU = 0.50:0.95) large objects |
0.714 |
AR @ IoU = 0.50:0.95 | area = large | maxDets = 100 |