initial commit
This commit is contained in:
commit
0c7ea419db
2
.idea/.gitignore
vendored
Normal file
2
.idea/.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
# Default ignored files
|
||||
/workspace.xml
|
6
.idea/inspectionProfiles/profiles_settings.xml
Normal file
6
.idea/inspectionProfiles/profiles_settings.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<settings>
|
||||
<option name="USE_PROJECT_PROFILE" value="false" />
|
||||
<version value="1.0" />
|
||||
</settings>
|
||||
</component>
|
4
.idea/misc.xml
Normal file
4
.idea/misc.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.6" project-jdk-type="Python SDK" />
|
||||
</project>
|
8
.idea/modules.xml
Normal file
8
.idea/modules.xml
Normal file
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/tesseract-box.iml" filepath="$PROJECT_DIR$/.idea/tesseract-box.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
8
.idea/tesseract-box.iml
Normal file
8
.idea/tesseract-box.iml
Normal file
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="PYTHON_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
40
Vagrantfile
vendored
Normal file
40
Vagrantfile
vendored
Normal file
@ -0,0 +1,40 @@
|
||||
# encoding: utf-8
|
||||
# -*- mode: ruby -*-
|
||||
# vi: set ft=ruby :
|
||||
|
||||
Vagrant.configure("2") do |config|
|
||||
config.vm.box = "generic/debian10"
|
||||
config.vm.box_check_update = false
|
||||
|
||||
config.vm.provider :virtualbox do |vb|
|
||||
vb.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
|
||||
# Display the VirtualBox GUI when booting the machine
|
||||
# vb.gui = true
|
||||
|
||||
# Customize the amount of memory on the VM:
|
||||
vb.memory = "4096"
|
||||
|
||||
# Use 1 CPUs
|
||||
vb.cpus = 4
|
||||
end
|
||||
|
||||
config.vm.network "forwarded_port", guest: 8000, host: 8001, auto_correct: true
|
||||
config.vm.network "forwarded_port", guest: 80, host: 81, auto_correct: true
|
||||
config.vm.network "forwarded_port", guest: 5000, host: 5001, auto_correct: true
|
||||
|
||||
config.vm.synced_folder ".", "/vagrant"
|
||||
|
||||
config.vm.provision "shell", privileged: true, path: "./provision.sh"
|
||||
|
||||
# Error:
|
||||
# [default] GuestAdditions seems to be installed (5.1.38) correctly, but not running.
|
||||
# @see solution from: https://github.com/dotless-de/vagrant-vbguest/issues/333#issuecomment-487105544
|
||||
if Vagrant.has_plugin?("vagrant-vbguest")
|
||||
config.vbguest.auto_update = false
|
||||
end
|
||||
|
||||
# Enable X11 forwarding for graphical apps.
|
||||
# Make sure you have xquartz installed if using OSX host!
|
||||
config.ssh.forward_agent = true
|
||||
config.ssh.forward_x11 = true
|
||||
end
|
BIN
fonts/GOST 2.304-81 type A (plotter).FON
Normal file
BIN
fonts/GOST 2.304-81 type A (plotter).FON
Normal file
Binary file not shown.
BIN
fonts/GOST 2.304-81 type A.ttf
Normal file
BIN
fonts/GOST 2.304-81 type A.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST 2.304-81 type B (plotter).FON
Normal file
BIN
fonts/GOST 2.304-81 type B (plotter).FON
Normal file
Binary file not shown.
BIN
fonts/GOST 2.304-81 type B.ttf
Normal file
BIN
fonts/GOST 2.304-81 type B.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST Type A ru ital.ttf
Normal file
BIN
fonts/GOST Type A ru ital.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST Type A ru.ttf
Normal file
BIN
fonts/GOST Type A ru.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST Type AU.ttf
Normal file
BIN
fonts/GOST Type AU.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST Type B ru ital.ttf
Normal file
BIN
fonts/GOST Type B ru ital.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST Type BU.ttf
Normal file
BIN
fonts/GOST Type BU.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST type A.TTF
Normal file
BIN
fonts/GOST type A.TTF
Normal file
Binary file not shown.
BIN
fonts/GOST type B ru.ttf
Normal file
BIN
fonts/GOST type B ru.ttf
Normal file
Binary file not shown.
BIN
fonts/GOST type B.ttf
Normal file
BIN
fonts/GOST type B.ttf
Normal file
Binary file not shown.
34
provision.sh
Normal file
34
provision.sh
Normal file
@ -0,0 +1,34 @@
|
||||
echo "%vagrant ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/vagrant
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
export PATH=$PATH:/home/vagrant/local/bin
|
||||
|
||||
# зависимости
|
||||
apt-get update
|
||||
apt-get install -y htop nano libsm6 libxext6 libxrender-dev \
|
||||
libicu-dev libpango1.0-dev libcairo2-dev g++ autoconf automake \
|
||||
libtool pkg-config libpng-dev libjpeg62-turbo-dev libtiff5-dev \
|
||||
zlib1g-dev libicu-dev libleptonica-dev
|
||||
|
||||
# Устанавливаем чертежные шрифты в систему
|
||||
export FONTS_DIR=/usr/local/share/fonts
|
||||
echo "export FONTS_DIR=$FONTS_DIR" >> /home/vagrant/.bashrc
|
||||
cp /vagrant/fonts/* $FONTS_DIR
|
||||
chmod -R 644 $FONTS_DIR
|
||||
fc-cache -v
|
||||
|
||||
# скачиваем и собираем tesseract 4.1.1
|
||||
cd /
|
||||
wget https://github.com/tesseract-ocr/tesseract/archive/4.1.1.tar.gz
|
||||
tar -zxvf 4.1.1.tar.gz
|
||||
cd /tesseract-4.1.1 || exit 1
|
||||
mkdir -p $HOME/local/include $HOME/local/lib/pkgconfig
|
||||
export PKG_CONFIG_PATH=$HOME/local/lib/pkgconfig
|
||||
./autogen.sh
|
||||
LIBLEPT_HEADERSDIR=$HOME/local/include ./configure \
|
||||
--prefix=$HOME/local/ --with-extra-libraries=$HOME/local/lib
|
||||
make
|
||||
make install
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user