Google Cloud Vision API reports (x,) in boundingBox when (x,y) is expected

I have this piece of response where (x,y) information for 4-points of the bounding box is expected but you’ll see a point where only (x,) is reported.

“boundingBox”: {
“vertices”: [
{
“x”: 81,
“y”: 1
},
{
“x”: 144
},
{
“x”: 144,
“y”: 9
},
{
“x”: 81,
“y”: 10
}
]
}

Good day @faraday ,

Welcome to Google Cloud Community!

There are several reasons why you are encountering this issue, you can check these solutions if it will solve your problem:

  1. You are not following the right format. By default, Vision API only supports several image types:

  2. JPEG

  3. PNG8

  4. PNG24

  5. GIF

  6. Animated GIF (first frame only)

  7. BMP

  8. WEBP

  9. RAW

  10. ICO

  11. PDF

  12. TIFF

Please note that some image formats may reduce the Vision API accuracy since they are “lossy” (e.g. JPEG).
You can check this link for more information: https://cloud.google.com/vision/docs/supported-files#file_formats

  1. The image must be at least 640 x 480 pixels in order to accurately detect the image. Vision API Features have recommended sizes. You can check this link to learn more: https://cloud.google.com/vision/docs/supported-files#file_formats

  2. File Size is also a factor, it must not exceed 20 MB. You check this link for more information: https://cloud.google.com/vision/docs/supported-files#file_size

  3. It is also possible that the y value may be equal to 0. If this is the case, the y value will not be included in the response.

You can also reach out to Google Cloud Support: https://cloud.google.com/support

Hope this helps!