Class: Google::Apis::VisionV1p1beta1::GoogleCloudVisionV1p4beta1CropHint
- Inherits:
- 
      Object
      
        - Object
- Google::Apis::VisionV1p1beta1::GoogleCloudVisionV1p4beta1CropHint
 
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/vision_v1p1beta1/classes.rb,
 lib/google/apis/vision_v1p1beta1/representations.rb,
 lib/google/apis/vision_v1p1beta1/representations.rb
Overview
Single crop hint that is used to generate a new crop when serving an image.
Instance Attribute Summary collapse
- 
  
    
      #bounding_poly  ⇒ Google::Apis::VisionV1p1beta1::GoogleCloudVisionV1p4beta1BoundingPoly 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    A bounding polygon for the detected image annotation. 
- 
  
    
      #confidence  ⇒ Float 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    Confidence of this being a salient region. 
- 
  
    
      #importance_fraction  ⇒ Float 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    Fraction of importance of this salient region with respect to the original image. 
Instance Method Summary collapse
- 
  
    
      #initialize(**args)  ⇒ GoogleCloudVisionV1p4beta1CropHint 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of GoogleCloudVisionV1p4beta1CropHint. 
- 
  
    
      #update!(**args)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    Update properties of this object. 
Constructor Details
#initialize(**args) ⇒ GoogleCloudVisionV1p4beta1CropHint
Returns a new instance of GoogleCloudVisionV1p4beta1CropHint.
| 7245 7246 7247 | # File 'lib/google/apis/vision_v1p1beta1/classes.rb', line 7245 def initialize(**args) update!(**args) end | 
Instance Attribute Details
#bounding_poly ⇒ Google::Apis::VisionV1p1beta1::GoogleCloudVisionV1p4beta1BoundingPoly
A bounding polygon for the detected image annotation.
Corresponds to the JSON property boundingPoly
| 7232 7233 7234 | # File 'lib/google/apis/vision_v1p1beta1/classes.rb', line 7232 def bounding_poly @bounding_poly end | 
#confidence ⇒ Float
Confidence of this being a salient region. Range [0, 1].
Corresponds to the JSON property confidence
| 7237 7238 7239 | # File 'lib/google/apis/vision_v1p1beta1/classes.rb', line 7237 def confidence @confidence end | 
#importance_fraction ⇒ Float
Fraction of importance of this salient region with respect to the original
image.
Corresponds to the JSON property importanceFraction
| 7243 7244 7245 | # File 'lib/google/apis/vision_v1p1beta1/classes.rb', line 7243 def importance_fraction @importance_fraction end | 
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
| 7250 7251 7252 7253 7254 | # File 'lib/google/apis/vision_v1p1beta1/classes.rb', line 7250 def update!(**args) @bounding_poly = args[:bounding_poly] if args.key?(:bounding_poly) @confidence = args[:confidence] if args.key?(:confidence) @importance_fraction = args[:importance_fraction] if args.key?(:importance_fraction) end |