Class: Google::Apis::LanguageV1::XpsResponseExplanationParameters

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/language_v1/classes.rb,
lib/google/apis/language_v1/representations.rb,
lib/google/apis/language_v1/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ XpsResponseExplanationParameters

Returns a new instance of XpsResponseExplanationParameters.



3347
3348
3349
# File 'lib/google/apis/language_v1/classes.rb', line 3347

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#integrated_gradients_attributionGoogle::Apis::LanguageV1::XpsIntegratedGradientsAttribution

An attribution method that computes the Aumann-Shapley value taking advantage of the model's fully differentiable structure. Refer to this paper for more details: https://arxiv.org/abs/1703.01365 Corresponds to the JSON property integratedGradientsAttribution



3337
3338
3339
# File 'lib/google/apis/language_v1/classes.rb', line 3337

def integrated_gradients_attribution
  @integrated_gradients_attribution
end

#xrai_attributionGoogle::Apis::LanguageV1::XpsXraiAttribution

An explanation method that redistributes Integrated Gradients attributions to segmented regions, taking advantage of the model's fully differentiable structure. Refer to this paper for more details: https://arxiv.org/abs/1906. 02825 Only supports image Models (modality is IMAGE). Corresponds to the JSON property xraiAttribution



3345
3346
3347
# File 'lib/google/apis/language_v1/classes.rb', line 3345

def xrai_attribution
  @xrai_attribution
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3352
3353
3354
3355
# File 'lib/google/apis/language_v1/classes.rb', line 3352

def update!(**args)
  @integrated_gradients_attribution = args[:integrated_gradients_attribution] if args.key?(:integrated_gradients_attribution)
  @xrai_attribution = args[:xrai_attribution] if args.key?(:xrai_attribution)
end