ryuu / image-recognition
image recognition api
This package's canonical repository appears to be gone and the package has been frozen as a result.
dev-master
2020-02-24 07:39 UTC
Requires
- guzzlehttp/guzzle: ~6.0
- phpunit/phpunit: ^8.5
Requires (Dev)
- phpunit/phpunit: ^8.5
This package is not auto-updated.
Last update: 2021-02-21 15:26:40 UTC
README
百度ai
$client = new ImageRecognition/ImageRecognition()->createGateway('baidu');
获取accessToken
参数 | 备注 |
---|---|
apikey | apikey |
secretKey | secretkey |
$client->getAccessToken($apiKey, $secretKey)
添加自定义菜品入库
参数 | 备注 |
---|---|
accessToken | 百度token |
image | base64格式图片 |
brief | 备注,json格式 |
$client->addRealtimeDish($accessToken, $image, $brief = '')
搜索自定义菜品
参数 s | 备注 |
---|---|
accessToken | 百度token |
image | base64格式图片 |
$client->searchRealtimeDish($accessToken, $image)
删除自定义菜品
参数 | 备注 |
---|---|
accessToken | 百度token |
image | base64格式图片 |
contSign | 签名 |
$client->deleteRealtimeDish($accessToken, $image, $contSign = '')