Download the PHP package mohuishou/image-ocr without Composer

On this page you can find all versions of the php package mohuishou/image-ocr. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package image-ocr

ImageOCR

php 验证码识别库,对于非粘连字符具有很好的识别效果,对于一般粘连字符也能有较为良好的识别 除噪算法支持孤立点除杂和连通域除噪,分割算法支持等宽分割、连通域分割以及滴水算法分割

示例效果

Install

使用方法

例子详见 example

use docker

点击 http://localhost:8088 查看效果

大致流程:

初始化

对象初始化

初始化二值化阈值

初始化标准化图片宽高

开启 Debug

灰度化

二值化

注意:这一步的前提是需要先执行上一步灰度化,不然会抛出一个错误

二值化支持两种方式,第一种$image_ocr->hash($max_grey=null,$min_grey=null)即为上面那种固定的阈值范围,第二种为hashByBackground($model=self::MAX_MODEL,$max_grey=null,$min_grey=null),通过背景图像的灰度值,动态取阈值,支持三种模式MAX_MODEL,MIN_MODEL,BG_MODEL分别是最大值、最小值和背景模式,最大值模式会用背景的灰度值替换阈值的上限,最小值模式替换下限,背景模式上下限都替换,即为只去除背景

除噪点

前置条件为二值化

孤立点除噪法
连通域除噪法

[如果要使用连通域分割法,可以跳过连通域除噪点,分割的同时可以一并除噪]

分割

非粘连字符串

连通域分割法

粘连字符串

滴水算法分割

TODO: 待测试

标准化

识别

TODO:待完善

API

CHANGELOG

0.2 [2017-4-1]

0.1 [2016-10-7]

  1. 默认模板保存方式由数据库改为文件,保存路径为./db/db.json
  2. 使用 composer 安装

All versions of image-ocr with dependencies

PHP Build Version
Package Version
Requires php Version >5.5
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mohuishou/image-ocr contains the following files

Loading the files please wait ....