hymns/microsoft-cognitive-vision
Composer 安装命令:
composer require hymns/microsoft-cognitive-vision
包简介
PHP client library for Vision module in Microsoft Cognitive Services
README 文档
README
The cloud-based Vision API provides developers with access to advanced image algorithms. Microsoft Vision algorithms enable OCR attribute detection.
Requirements
Installation
You can use Composer or simply Download the Release
Composer
The preferred method is via composer. Follow the installation instructions if you do not already have composer installed.
Once composer is installed, execute the following command in your project root to install this library:
composer require hymns/microsoft-cognitive-vision
Finally, be sure to include the autoloader:
require_once '/path/to/your-project/vendor/autoload.php';
Download the Release
If you abhor using composer, you can download the package in its entirety. The Releases page lists all stable versions. Download any file
with the name microsoft-cognitive-vision-[RELEASE_NAME].zip for a package including this library and its dependencies.
Uncompress the zip file you download, and include the autoloader in your project:
require_once '/path/to/microsoft-cognitive-vision/vendor/autoload.php';
Examples
Analyze Image
// include your composer dependencies require_once 'vendor/autoload.php'; $client = new \Hymns\MicrosoftCognitiveVision\Client('YOUR_APP_KEY', 'YOUR_REGION'); $vision = $client->vision()->analyze('URL_IMAGE'); print_r($vision);
Describe Image
require_once 'vendor/autoload.php'; $client = new \Hymns\MicrosoftCognitiveVision\Client('YOUR_APP_KEY', 'YOUR_REGION'); $vision = $client->vision()->describe('URL_IMAGE'); print_r($vision);
Optical Character Recognition (OCR)
require_once 'vendor/autoload.php'; $client = new \Hymns\MicrosoftCognitiveVision\Client('YOUR_APP_KEY', 'YOUR_REGION'); $vision = $client->vision()->ocr('URL_IMAGE'); print_r($vision);
统计信息
- 总下载量: 98
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 3
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-10-05