Add model card
Browse files
README.md
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: cc-by-nc-3.0
|
| 3 |
+
pipeline_tag: object-detection
|
| 4 |
+
tags:
|
| 5 |
+
- vision
|
| 6 |
+
- yolo
|
| 7 |
+
- ultralytics
|
| 8 |
+
- document-processing
|
| 9 |
+
- line-segmentation
|
| 10 |
+
- obb
|
| 11 |
+
---
|
| 12 |
+
|
| 13 |
+
# Tzefa Line Segmentation Model (YOLO11x-OBB)
|
| 14 |
+
|
| 15 |
+
Custom-trained oriented bounding box (OBB) model for detecting text lines in handwritten code images.
|
| 16 |
+
|
| 17 |
+
## Architecture
|
| 18 |
+
- **Model:** YOLO11x-OBB (Ultralytics)
|
| 19 |
+
- **Task:** Oriented Bounding Box detection
|
| 20 |
+
- **Classes:** 1 (text_line)
|
| 21 |
+
- **Input:** RGB image (letterboxed to 640x640 internally)
|
| 22 |
+
- **Output:** OBB coordinates per text line, sorted top-to-bottom
|
| 23 |
+
|
| 24 |
+
## Usage
|
| 25 |
+
```python
|
| 26 |
+
from huggingface_hub import hf_hub_download
|
| 27 |
+
from ultralytics import YOLO
|
| 28 |
+
|
| 29 |
+
weights = hf_hub_download("WARAJA/Tzefa-Line-Segmentation-YOLO", "best.pt")
|
| 30 |
+
model = YOLO(weights)
|
| 31 |
+
results = model.predict("your_image.png", imgsz=640, conf=0.2, iou=0.2)
|
| 32 |
+
```
|
| 33 |
+
|
| 34 |
+
## Training
|
| 35 |
+
- See `training_artifacts/` for training curves, confusion matrices, and configuration.
|
| 36 |
+
|
| 37 |
+
## Related
|
| 38 |
+
- [Full Tzefa Pipeline](https://huggingface.co/spaces/WARAJA/Tzefa)
|
| 39 |
+
- [OCR Demo](https://huggingface.co/spaces/WARAJA/Tzefa-OCR)
|
| 40 |
+
- [Line Segmentation Dataset](https://huggingface.co/datasets/WARAJA/Tzefa-Line-Segmentation-Dataset)
|