vagheshpatel commited on
Commit
dc5a87a
·
verified ·
1 Parent(s): 67ba03b

Sync ocr-text-recognition from metro-analytics-catalog

Browse files
Files changed (2) hide show
  1. config.json +21 -0
  2. export_and_quantize.sh +12 -0
config.json ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "model_type": "ocr-text-recognition",
3
+ "library_name": "openvino",
4
+ "pipeline_tag": "image-to-text",
5
+ "category": "Optical Character Recognition (Text Detection + Recognition)",
6
+ "base_model": "PP-OCRv4 (PaddlePaddle)",
7
+ "source_framework": "PaddlePaddle",
8
+ "supported_precisions": [
9
+ "FP32",
10
+ "FP16"
11
+ ],
12
+ "inference_engine": "OpenVINO",
13
+ "hardware": [
14
+ "CPU",
15
+ "GPU",
16
+ "NPU"
17
+ ],
18
+ "detected_classes": "Text regions + recognized text strings",
19
+ "hf_repo_id": "Intel/ocr-text-recognition",
20
+ "description": "OCR for text use case using the PaddleOCR PP-OCRv4 detection and recognition pipeline to detect and read text in images and video"
21
+ }
export_and_quantize.sh CHANGED
@@ -21,6 +21,18 @@ if [[ "${APPROVAL}" != "yes" ]]; then
21
  echo "Download cancelled by user."
22
  exit 0
23
  fi
 
 
 
 
 
 
 
 
 
 
 
 
24
  echo ""
25
 
26
  DET_URL="https://paddleocr.bj.bcebos.com/PP-OCRv4/chinese/ch_PP-OCRv4_det_infer.tar"
 
21
  echo "Download cancelled by user."
22
  exit 0
23
  fi
24
+
25
+ # Ping the HuggingFace repo to register a tracked download of config.json.
26
+ # This is best-effort: a failure (offline, or before the repo is published)
27
+ # must not stop the export.
28
+ echo "--- Registering HuggingFace download (tracking ping) ---"
29
+ HF_REPO_ID="Intel/ocr-text-recognition"
30
+ HF_CONFIG_URL="https://huggingface.co/${HF_REPO_ID}/resolve/main/config.json"
31
+ if curl -fsSL -o /dev/null "${HF_CONFIG_URL}"; then
32
+ echo "Registered HuggingFace download for ${HF_REPO_ID}"
33
+ else
34
+ echo "WARNING: HuggingFace tracking ping failed (offline?); continuing." >&2
35
+ fi
36
  echo ""
37
 
38
  DET_URL="https://paddleocr.bj.bcebos.com/PP-OCRv4/chinese/ch_PP-OCRv4_det_infer.tar"