biglam/loc_beyond_words
Viewer โข Updated โข 3.56k โข 195 โข 15
Fine-tuned facebook/detr-resnet-50 (DETR, ResNet-50 backbone, Apache-2.0) on the
biglam/loc_beyond_words
dataset โ a crowdsourced collection of bounding-box annotations over WWI-era newspaper
pages from the Library of Congress Chronicling America collection.
Fine-tuning was performed on a single NVIDIA T4 via Hugging Face Jobs (~under $5 of compute).
Per-class mAP@0.5:
from transformers import AutoProcessor, DetrForObjectDetection
import torch
processor = AutoProcessor.from_pretrained("harness-race/opencode-r1")
model = DetrForObjectDetection.from_pretrained("harness-race/opencode-r1")
image = Image.open("page.jpg")
inputs = processor(images=image, return_tensors="pt")
outputs = model(**inputs)
results = processor.post_process_object_detection(
outputs, threshold=0.5, target_sizes=torch.tensor([image.size[::-1]]))[0]
facebook/detr-resnet-50: Apache-2.0biglam/loc_beyond_words: CC0-1.0 (public domain)