Anyone know how to set LabelDetectionConfig in Google Cloud Vision api for PHP?
Apparently there is new functionality released, described here: https://cloud.google.com/vision/docs/release-notes
Improved detection models are now available for the following features:
Logo Detection Text Detection (OCR) Specify "builtin/latest" in the LabelDetectionConfig field to use the new models.
We'll support both the current model and the new model the next 90 days. After 90 days the current detection models will be deprecated and only the new detection models will be used for all logo and text (OCR) detection requests.
This is what my code looks like now:
$vision = new VisionClient([
'projectId' => XXXX
]);
$contents = get_contents($url);
$image = $vision->image($contents, ['LOGO_DETECTION']);
$result = $vision->annotate($image);