PHPackages                             guijianshi/baidu-ocr - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. guijianshi/baidu-ocr

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

guijianshi/baidu-ocr
====================

百度ocr包

2.2.3(7y ago)43.9k↓75%MITPHP

Since Oct 16Pushed 7y ago1 watchersCompare

[ Source](https://github.com/guijianshi/baidu_ocr)[ Packagist](https://packagist.org/packages/guijianshi/baidu-ocr)[ RSS](/packages/guijianshi-baidu-ocr/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

百度ocr识别sdk php的composer包
========================

[](#百度ocr识别sdk-php的composer包)

此包适用于各类支持composer的php框架

安装
--

[](#安装)

```
composer require guijianshi/baidu-ocr

```

版本说明
----

[](#版本说明)

版本与官方保持一致可以根据自己实际使用选择最低版本为(2.2.3)

使用
--

[](#使用)

使用与官方文档一致

```
//本地图片识别
$client = new baidu\ocr\AipOcr(APP_ID, API_KEY, SECRET_KEY);
$image = file_get_contents(__DIR__ . '/test.png'); // 图片地址 (远程地址https可用这个)
$result = $client->basicGeneral($image);

```

```
//远程图片识别
$client = new baidu\ocr\AipOcr(APP_ID, API_KEY, SECRET_KEY);
$url = 'http://test.com'; // 只支持http地址(不支持https)图片地址 https可以用楼上方法
$result = $client->basicGeneral($url);

```

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity61

Established project with proven stability

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2772d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7e5a945a12bf131d201ad5033b27605737eb1adf40165e5f3d70afc1836ce87c?d=identicon)[guijianshi](/maintainers/guijianshi)

### Embed Badge

![Health badge](/badges/guijianshi-baidu-ocr/health.svg)

```
[![Health](https://phpackages.com/badges/guijianshi-baidu-ocr/health.svg)](https://phpackages.com/packages/guijianshi-baidu-ocr)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
