DNB Portrait Detector
A YOLO-based object detection model for identifying portrait engravings in digitized historical documents.
This model was developed as part of the HERMES-Forschungsstudienprogramm to support the automatic detection and extraction of portrait illustrations from historical collections.
You can find the result for the model inference here: https://huggingface.co/datasets/luanamcosta/dnb-buchhandlerportrats
Overview
The detector identifies portrait regions on scanned pages containing historical engravings, illustrations, and printed portraits. The resulting bounding boxes can be used as a preprocessing step for:
- automatic portrait cropping
- image retrieval
- metadata enrichment
- large-scale analysis of historical portrait collections
- digital humanities workflows
The model was trained on manually annotated historical images from the Deutsche Nationalbibliothek (DNB). Github Repository: https://github.com/luanamoraescosta/Buchhandlerportrats
Model
The trained weights are available at:
runs/detect/portrait_detector-3/best.pt
Performance
Validation results show:
- Best F1 Score: 0.97
- Optimal confidence threshold: 0.34
The detector performs reliably across different engraving styles, page layouts, and portrait sizes.
Example Predictions
The model successfully detects portraits in historical printed material with high confidence.
Example predictions are available in:
runs/detect/portrait_detector-3/
including
- validation predictions
- precision-recall curves
- F1-confidence curve
- confusion matrix
- training statistics
Repository Structure
runs/
βββ detect/
βββ portrait_detector-3/
βββ best.pt
βββ last.pt
βββ results.png
βββ PR_curve.png
βββ F1_curve.png
βββ confusion_matrix.png
βββ val_batch*.jpg
βββ ...
Usage
Using Ultralytics YOLO:
from ultralytics import YOLO
model = YOLO("best.pt")
results = model.predict(
source="image.jpg",
conf=0.34
)
Project
This work was carried out within the HERMES-Forschungsstudienprogramm in collaboration with the Deutsche Nationalbibliothek (DNB).
The detector was developed to support automated processing of digitized historical collections in Digital Humanities research.
License
Please refer to the repository license for usage conditions.
Model tree for luanamcosta/dnb-portrait-cropper
Base model
Ultralytics/YOLO26