Daniil-Domino commited on
Commit
0adb8ac
·
verified ·
1 Parent(s): 635c6ba

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +69 -3
README.md CHANGED
@@ -1,3 +1,69 @@
1
- ---
2
- license: agpl-3.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: agpl-3.0
3
+ language:
4
+ - ru
5
+ base_model:
6
+ - Daniil-Domino/yolo11x-text-detection
7
+ library_name: ultralytics
8
+ library_version: 8.3.155
9
+ pipeline_tag: object-detection
10
+ tags:
11
+ - yolo
12
+ - yolo11
13
+ - yolo11x
14
+ - htr
15
+ - text-detection
16
+ - dialectic
17
+ - linguistics
18
+ ---
19
+ # Handwritten Russian Dialectic Text Detection using YOLO11
20
+
21
+ The [YOLO11x-text-detection](https://huggingface.co/Daniil-Domino/yolo11x-text-detection) model was fine-tuned on a dataset of nearly 150 images containing handwritten Russian dialectic texts.
22
+
23
+ ## Model description
24
+
25
+ YOLO11x-text-detection was fine-tuned for Handwritten Russian Dialectic Text Detection in dialectological cards.
26
+ The model was trained for 100 epochs with a batch size of 32 using dual NVIDIA T4 GPUs. Fifteen layers were frozen during training as part of the transfer learning process. The entire training took approximately 7 minutes.
27
+
28
+ # Example Usage
29
+
30
+ ```python
31
+ # Load libraries
32
+ import cv2
33
+ from ultralytics import YOLO
34
+ from pathlib import Path
35
+ import matplotlib.pyplot as plt
36
+ from huggingface_hub import hf_hub_download
37
+
38
+
39
+ # Download model
40
+ model_path = hf_hub_download(repo_id="Daniil-Domino/yolo11x-dialectic", filename="model.pt")
41
+
42
+ # Load model
43
+ model = YOLO(model_path)
44
+
45
+ # Inference
46
+ image_path = "/path/to/image"
47
+ image = cv2.imread(image_path).copy()
48
+ output = model.predict(image, conf=0.3)
49
+
50
+ # Draw bounding boxes
51
+ out_image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB)
52
+ for data in output[0].boxes.data.tolist():
53
+ xmin, ymin, xmax, ymax, _, _ = map(int, data)
54
+ cv2.rectangle(out_image, (xmin, ymin), (xmax, ymax), color=(0, 0, 255), thickness=3)
55
+
56
+ # Display result
57
+ plt.figure(figsize=(15, 10))
58
+ plt.imshow(out_image)
59
+ plt.axis('off')
60
+ plt.show()
61
+
62
+ ```
63
+
64
+ # Metrics
65
+ Below are the key evaluation metrics on the validation set:
66
+ - **Precision**: 0.940
67
+ - **Recall**: 0.924
68
+ - **mAP50**: 0.972
69
+ - **mAP50-95**: 0.656