Issue with vectorisation of .tiff image

Akashkumar Barot (HCL TECHNOLOGIES CORPORATE SER) 40 Reputation points Microsoft External Staff
2025-05-16T22:41:30.7333333+00:00

I'm currently using the Azure Vision API to generate vector embeddings from .tiff images, which I then compare against pre-vectorized images stored in a database.

When testing with .jpg or .png formats, the image similarity search works as expected and returns relevant results. However, when using the .tiff format, the results are inaccurate or irrelevant.

Interestingly, if I convert the same .tiff image to .jpg using Microsoft Paint, the system returns correct and relevant results—indicating the content is being interpreted correctly in .jpg format.

At this point, I’m unsure if the issue lies in how the Azure Vision API processes .tiff files, or if there's an inconsistency in how the vector is being generated for that format. Further investigation is needed to determine whether this is a format compatibility, encoding, or preprocessing issue.

Azure AI Custom Vision
Azure AI Custom Vision
An Azure artificial intelligence service and end-to-end platform for applying computer vision to specific domains.
0 comments No comments
{count} votes

Accepted answer
  1. Divyesh Govaerdhanan 8,340 Reputation points
    2025-05-16T23:43:46.12+00:00

    Hello,

    Welcome to Microsoft Q&A,

    .tiff files often contain multi-page images, layers, or high bit-depth channels. Azure Vision API may not normalize, flatten, or convert .tiff images the same way as it does with .jpg or .png. If the API processes only the first page or doesn't handle compression schemes like LZW or Deflate, the result may be distorted or misinterpreted.

    JPEGs are uniformly RGB, 8-bit, single-frame, and they are easier for the model to process consistently. But TIFFs could be grayscale, CMYK, or RGBA, introducing variations in how the model extracts features.

    Feeding models with .tiff might bypass or confuse normalization routines (e.g., resizing, color correction), leading to inconsistent vector generation.

    Its recommended to convert all images into .jpg or .png before embedding.

    Please Upvote and accept the answer if it helps!!

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.