Skip to content

Fetch google vision

image analysis · 3rd party API · integration · model

Analyze images given their URL using the Google Vision API.

Labels and categorizes images to indicate whether they contain violent, parodic, adult, medical or racy elements.

API integration

To use this step your team needs to have the Google Vision integration configured in Graphext. The corresponding credentials are required to connect to a third-party API. See our help center for details on how to configure your team's integrations.

To enable the Google Vision integration in particular you will need access to Google's Vision service. Follow the instructions shere to create the required API key.

Example

The step has no configuration parameters, so it's simply

fetch_google_vision(ds.image_url) -> (
  ds.image_labels,
  ds.image_contains_violence,
  ds.image_is_spoof,
  ds.image_has_adult_content,
  ds.image_has_medical_content,
  ds.image_is_racy
)

Usage

The following are the step's expected inputs and outputs and their specific types.

fetch_google_vision(target_col: url) -> (
    labels: list[category],
    violence: category,
    spoof: category,
    adult: category,
    medical: category,
    racy: category
)

Inputs


target_col: column:url

Direct URLs to the images to analyze, e.g. https://upload.wikimedia.org/wikipedia/commons/c/c7/Madrid_-_El_Oso_y_el_Madro%C3%B1o.jpg.

Outputs


labels: column:list[category]

Lists of entities identified in the picture.


violence: column:category

Indicates whether the image contains violence.


spoof: column:category

Indicates whether the image is a spoof (parody).


adult: column:category

Indicates whether the image features adult content.


medical: column:category

Indicates whether the image features medical content.


racy: column:category

Indicates whether the image features racy content.