Downloads · 30 days
125
34% of all-time downloads
cszhangai/ancient-chinese-character-detection
ancient-chinese-character-detection is a object detection model from cszhangai. Use it when you need objects located in an image. It is set up for ultralytics. The card lists the license as cc-by-nc-4.0.
Downloads · 30 days
125
34% of all-time downloads
All-time downloads
367
Public
Repo size
131 MB
Likes
1
Public
Click a slice to open those files.
.pt131 MB · 100%
From the Hugging Face model README
作者 / Author: 张重生 Chongsheng Zhang(河南大学)
基于 YOLO26m 训练的古文字目标检测模型,支持甲骨文(商代)和简牍文字(汉代)的单字检测与定位。
A YOLO26m-based ancient Chinese character detection model trained for Oracle Bone Inscriptions (Shang Dynasty) and Bamboo Slip characters (Han Dynasty).
| 域 / Domain | mAP50 |
|---|---|
| 甲骨文 Oracle Bone Inscriptions | 89.92% |
| 简牍 Bamboo Slips | 94.22% |
| 项目 | 值 |
|---|---|
| 架构 | YOLO26m |
| 参数量 | 20.4M |
| 模型大小 | 126 MB |
| 输入尺寸 | 640×640 |
| 检测类别 | character(单类别) |
访问 HuggingFace Space:Ancient Chinese Character Detection
from ultralytics import YOLO
from huggingface_hub import hf_hub_download
# 下载模型
model_path = hf_hub_download(
repo_id="cszhangai/ancient-chinese-character-detection",
filename="General_Ancient_Character_Detection.pt"
)
# 加载模型
model = YOLO(model_path)
# 单张检测
results = model.predict(
source="your_image.jpg",
imgsz=640,
conf=0.25, # 甲骨文建议 0.20,简牍建议 0.25
iou=0.45,
device=0, # GPU;改为 'cpu' 使用 CPU
save=True,
)
# 获取检测框坐标
for result in results:
for box in result.boxes:
x1, y1, x2, y2 = box.xyxy[0].tolist()
conf = box.conf[0].item()
print(f"box: ({x1:.0f},{y1:.0f}) → ({x2:.0f},{y2:.0f}) conf={conf:.3f}")
conf=0.20(字符变异大,阈值过高易漏检)conf=0.25Copyright © Chongsheng Zhang(张重生,河南大学) https://cszhanglmu.github.io/