View Source ExAzureVision.ImageAnalysis (ExAzureVision v0.1.0)

Module for analyzing image.

Link to this section Summary

Functions

Analyzes the image using url. Returns Jason decoded value or error message.

Link to this section Functions

Link to this function

analyze(image_url, query_params)

View Source (since 0.1.0)
@spec analyze(String.t(), map()) ::
  {:ok, response :: map()} | {:error, reason :: atom()}

Analyzes the image using url. Returns Jason decoded value or error message.

examples

Examples

image_url = "https://example.gif/sample.jpg"

query_params =
  %{
    "visualFeatures" => "Categories,Adult,Tags,Description,Faces,Objects",
    "details" => "Landmarks",
    "language" => "en",
    "model-version" => "latest"
  }

iex> annotate_image(image_url, query_params)
%{
  "categories" => [...],
  ...
}