Class: AWSCDK::Greengrass::CfnResourceDefinition::S3MachineLearningModelResourceDataProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Greengrass::CfnResourceDefinition::S3MachineLearningModelResourceDataProperty
- Defined in:
- greengrass/cfn_resource_definition.rb
Overview
Settings for an Amazon S3 machine learning resource.
For more information, see Perform Machine Learning Inference in the Developer Guide .
In an CloudFormation template, S3MachineLearningModelResourceData can be used in the ResourceDataContainer property type.
Instance Attribute Summary collapse
-
#destination_path ⇒ String
readonly
The absolute local path of the resource inside the Lambda environment.
-
#owner_setting ⇒ AWSCDK::IResolvable, ...
readonly
The owner setting for the downloaded machine learning resource.
-
#s3_uri ⇒ String
readonly
The URI of the source model in an Amazon S3 bucket.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(destination_path:, s3_uri:, owner_setting: nil) ⇒ S3MachineLearningModelResourceDataProperty
constructor
A new instance of S3MachineLearningModelResourceDataProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(destination_path:, s3_uri:, owner_setting: nil) ⇒ S3MachineLearningModelResourceDataProperty
Returns a new instance of S3MachineLearningModelResourceDataProperty.
998 999 1000 1001 1002 1003 1004 1005 |
# File 'greengrass/cfn_resource_definition.rb', line 998 def initialize(destination_path:, s3_uri:, owner_setting: nil) @destination_path = destination_path Jsii::Type.check_type(@destination_path, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "destinationPath") @s3_uri = s3_uri Jsii::Type.check_type(@s3_uri, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "s3Uri") @owner_setting = owner_setting.is_a?(Hash) ? ::AWSCDK::Greengrass::CfnResourceDefinition::ResourceDownloadOwnerSettingProperty.new(**owner_setting.transform_keys(&:to_sym)) : owner_setting Jsii::Type.check_type(@owner_setting, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19ncmVlbmdyYXNzLkNmblJlc291cmNlRGVmaW5pdGlvbi5SZXNvdXJjZURvd25sb2FkT3duZXJTZXR0aW5nUHJvcGVydHkifV19fQ==")), "ownerSetting") unless @owner_setting.nil? end |
Instance Attribute Details
#destination_path ⇒ String (readonly)
The absolute local path of the resource inside the Lambda environment.
1011 1012 1013 |
# File 'greengrass/cfn_resource_definition.rb', line 1011 def destination_path @destination_path end |
#owner_setting ⇒ AWSCDK::IResolvable, ... (readonly)
The owner setting for the downloaded machine learning resource.
For more information, see Access Machine Learning Resources from Lambda Functions in the Developer Guide .
1025 1026 1027 |
# File 'greengrass/cfn_resource_definition.rb', line 1025 def owner_setting @owner_setting end |
#s3_uri ⇒ String (readonly)
The URI of the source model in an Amazon S3 bucket.
The model package must be in tar.gz or .zip format.
1018 1019 1020 |
# File 'greengrass/cfn_resource_definition.rb', line 1018 def s3_uri @s3_uri end |
Class Method Details
.jsii_properties ⇒ Object
1027 1028 1029 1030 1031 1032 1033 |
# File 'greengrass/cfn_resource_definition.rb', line 1027 def self.jsii_properties { :destination_path => "destinationPath", :s3_uri => "s3Uri", :owner_setting => "ownerSetting", } end |
Instance Method Details
#to_jsii ⇒ Object
1035 1036 1037 1038 1039 1040 1041 1042 1043 |
# File 'greengrass/cfn_resource_definition.rb', line 1035 def to_jsii result = {} result.merge!({ "destinationPath" => @destination_path, "s3Uri" => @s3_uri, "ownerSetting" => @owner_setting, }) result.compact end |