Google Cloud Ai Platform V1 Client - Class Visualization (0.22.0)

Reference documentation and code samples for the Google Cloud Ai Platform V1 Client class Visualization.

Visualization configurations for image explanation.

Generated from protobuf message google.cloud.aiplatform.v1.ExplanationMetadata.InputMetadata.Visualization

Namespace

Google \ Cloud \ AIPlatform \ V1 \ ExplanationMetadata \ InputMetadata

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ type int

Type of the image visualization. Only applicable to Integrated Gradients attribution. OUTLINES shows regions of attribution, while PIXELS shows per-pixel attribution. Defaults to OUTLINES.

↳ polarity int

Whether to only highlight pixels with positive contributions, negative or both. Defaults to POSITIVE.

↳ color_map int

The color scheme used for the highlighted areas. Defaults to PINK_GREEN for Integrated Gradients attribution, which shows positive attributions in green and negative in pink. Defaults to VIRIDIS for XRAI attribution, which highlights the most influential regions in yellow and the least influential in blue.

↳ clip_percent_upperbound float

Excludes attributions above the specified percentile from the highlighted areas. Using the clip_percent_upperbound and clip_percent_lowerbound together can be useful for filtering out noise and making it easier to see areas of strong attribution. Defaults to 99.9.

↳ clip_percent_lowerbound float

Excludes attributions below the specified percentile, from the highlighted areas. Defaults to 62.

↳ overlay_type int

How the original image is displayed in the visualization. Adjusting the overlay can help increase visual clarity if the original image makes it difficult to view the visualization. Defaults to NONE.

getType

Type of the image visualization. Only applicable to Integrated Gradients attribution.

OUTLINES shows regions of attribution, while PIXELS shows per-pixel attribution. Defaults to OUTLINES.

Returns
TypeDescription
int

setType

Type of the image visualization. Only applicable to Integrated Gradients attribution.

OUTLINES shows regions of attribution, while PIXELS shows per-pixel attribution. Defaults to OUTLINES.

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getPolarity

Whether to only highlight pixels with positive contributions, negative or both. Defaults to POSITIVE.

Returns
TypeDescription
int

setPolarity

Whether to only highlight pixels with positive contributions, negative or both. Defaults to POSITIVE.

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getColorMap

The color scheme used for the highlighted areas.

Defaults to PINK_GREEN for Integrated Gradients attribution, which shows positive attributions in green and negative in pink. Defaults to VIRIDIS for XRAI attribution, which highlights the most influential regions in yellow and the least influential in blue.

Returns
TypeDescription
int

setColorMap

The color scheme used for the highlighted areas.

Defaults to PINK_GREEN for Integrated Gradients attribution, which shows positive attributions in green and negative in pink. Defaults to VIRIDIS for XRAI attribution, which highlights the most influential regions in yellow and the least influential in blue.

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getClipPercentUpperbound

Excludes attributions above the specified percentile from the highlighted areas. Using the clip_percent_upperbound and clip_percent_lowerbound together can be useful for filtering out noise and making it easier to see areas of strong attribution. Defaults to 99.9.

Returns
TypeDescription
float

setClipPercentUpperbound

Excludes attributions above the specified percentile from the highlighted areas. Using the clip_percent_upperbound and clip_percent_lowerbound together can be useful for filtering out noise and making it easier to see areas of strong attribution. Defaults to 99.9.

Parameter
NameDescription
var float
Returns
TypeDescription
$this

getClipPercentLowerbound

Excludes attributions below the specified percentile, from the highlighted areas. Defaults to 62.

Returns
TypeDescription
float

setClipPercentLowerbound

Excludes attributions below the specified percentile, from the highlighted areas. Defaults to 62.

Parameter
NameDescription
var float
Returns
TypeDescription
$this

getOverlayType

How the original image is displayed in the visualization.

Adjusting the overlay can help increase visual clarity if the original image makes it difficult to view the visualization. Defaults to NONE.

Returns
TypeDescription
int

setOverlayType

How the original image is displayed in the visualization.

Adjusting the overlay can help increase visual clarity if the original image makes it difficult to view the visualization. Defaults to NONE.

Parameter
NameDescription
var int
Returns
TypeDescription
$this