Browse Source

上传文件至 ''

自动脚本
Caner 4 years ago
parent
commit
b3c7da15b3
1 changed files with 55 additions and 0 deletions
  1. 55 0
      start.bat

+ 55 - 0
start.bat

@@ -0,0 +1,55 @@
+echo 1 Create Box File
+tesseract num.font.exp0.tif num.font.exp0 -l chi_sim --psm 7 batch.nochop makebox
+
+pause
+
+
+echo 2 Create Tr File
+tesseract num.font.exp0.tif num.font.exp0 -l chi_sim --psm 7 box.train
+
+
+echo 3 Create Unicharset File
+unicharset_extractor num.font.exp0.box
+
+
+echo 4 Create font_properties File
+echo "font 0 0 0 0 0" > font_properties
+
+
+echo 5 Create Shape File
+shapeclustering -F font_properties -U unicharset -O num.unicharset num.font.exp0.tr
+
+
+echo 6 Training the data
+mftraining -F font_properties -U unicharset -O num.unicharset num.font.exp0.tr
+
+
+echo 7 Create Shapetable Inttemp Pffmtable Normproto File
+cntraining num.font.exp0.tr
+
+
+echo 8 Rename four files
+rename shapetable num.shapetable
+rename inttemp num.inttemp
+rename pffmtable num.pffmtable
+rename normproto num.normproto
+
+
+echo 9 Create .traineddata file
+combine_tessdata num.
+
+
+echo 10 remove files
+del font_properties -y
+del unicharset -y
+del num.font.exp0.tr -y
+del num.inttemp -y
+del num.pffmtable -y
+del num.shapetable -y
+del num.unicharset -y
+del num.normproto -y
+
+echo 11 copy files
+copy num.traineddata D:\Tesseract-OCR\tessdata
+
+pause