blib/lib/Paws/MachineLearning/RDSDataSpec.pm untested

filter: Statementstmt 0.0% 0 / 14 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 1 Podpod n/a totaltotal 0.0% 0 / 15 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
CRAP 2.0
1 # Generated by default/object.tt
2 package Paws::MachineLearning::RDSDataSpec;
3 use Moose;
4 has DatabaseCredentials => (is => 'ro', isa => 'Paws::MachineLearning::RDSDatabaseCredentials', required => 1);
5 has DatabaseInformation => (is => 'ro', isa => 'Paws::MachineLearning::RDSDatabase', required => 1);
6 has DataRearrangement => (is => 'ro', isa => 'Str');
7 has DataSchema => (is => 'ro', isa => 'Str');
8 has DataSchemaUri => (is => 'ro', isa => 'Str');
9 has ResourceRole => (is => 'ro', isa => 'Str', required => 1);
10 has S3StagingLocation => (is => 'ro', isa => 'Str', required => 1);
11 has SecurityGroupIds => (is => 'ro', isa => 'ArrayRef[Str|Undef]', required => 1);
12 has SelectSqlQuery => (is => 'ro', isa => 'Str', required => 1);
13 has ServiceRole => (is => 'ro', isa => 'Str', required => 1);
14 has SubnetId => (is => 'ro', isa => 'Str', required => 1);
15  
16 1;
17  
18 ### main pod documentation begin ###
19  
20 =head1 NAME
21  
22 Paws::MachineLearning::RDSDataSpec
23  
24 =head1 USAGE
25  
26 This class represents one of two things:
27  
28 =head3 Arguments in a call to a service
29  
30 Use the attributes of this class as arguments to methods. You shouldn't make instances of this class.
31 Each attribute should be used as a named argument in the calls that expect this type of object.
32  
33 As an example, if Att1 is expected to be a Paws::MachineLearning::RDSDataSpec object:
34  
35 $service_obj->Method(Att1 => { DatabaseCredentials => $value, ..., SubnetId => $value });
36  
37 =head3 Results returned from an API call
38  
39 Use accessors for each attribute. If Att1 is expected to be an Paws::MachineLearning::RDSDataSpec object:
40  
41 $result = $service_obj->Method(...);
42 $result->Att1->DatabaseCredentials
43  
44 =head1 DESCRIPTION
45  
46 The data specification of an Amazon Relational Database Service (Amazon
47 RDS) C<DataSource>.
48  
49 =head1 ATTRIBUTES
50  
51  
52 =head2 B<REQUIRED> DatabaseCredentials => L<Paws::MachineLearning::RDSDatabaseCredentials>
53  
54 The AWS Identity and Access Management (IAM) credentials that are used
55 connect to the Amazon RDS database.
56  
57  
58 =head2 B<REQUIRED> DatabaseInformation => L<Paws::MachineLearning::RDSDatabase>
59  
60 Describes the C<DatabaseName> and C<InstanceIdentifier> of an Amazon
61 RDS database.
62  
63  
64 =head2 DataRearrangement => Str
65  
66 A JSON string that represents the splitting and rearrangement
67 processing to be applied to a C<DataSource>. If the
68 C<DataRearrangement> parameter is not provided, all of the input data
69 is used to create the C<Datasource>.
70  
71 There are multiple parameters that control what data is used to create
72 a datasource:
73  
74 =over
75  
76 =item *
77  
78 B<C<percentBegin>>
79  
80 Use C<percentBegin> to indicate the beginning of the range of the data
81 used to create the Datasource. If you do not include C<percentBegin>
82 and C<percentEnd>, Amazon ML includes all of the data when creating the
83 datasource.
84  
85 =item *
86  
87 B<C<percentEnd>>
88  
89 Use C<percentEnd> to indicate the end of the range of the data used to
90 create the Datasource. If you do not include C<percentBegin> and
91 C<percentEnd>, Amazon ML includes all of the data when creating the
92 datasource.
93  
94 =item *
95  
96 B<C<complement>>
97  
98 The C<complement> parameter instructs Amazon ML to use the data that is
99 not included in the range of C<percentBegin> to C<percentEnd> to create
100 a datasource. The C<complement> parameter is useful if you need to
101 create complementary datasources for training and evaluation. To create
102 a complementary datasource, use the same values for C<percentBegin> and
103 C<percentEnd>, along with the C<complement> parameter.
104  
105 For example, the following two datasources do not share any data, and
106 can be used to train and evaluate a model. The first datasource has 25
107 percent of the data, and the second one has 75 percent of the data.
108  
109 Datasource for evaluation: C<{"splitting":{"percentBegin":0,
110 "percentEnd":25}}>
111  
112 Datasource for training: C<{"splitting":{"percentBegin":0,
113 "percentEnd":25, "complement":"true"}}>
114  
115 =item *
116  
117 B<C<strategy>>
118  
119 To change how Amazon ML splits the data for a datasource, use the
120 C<strategy> parameter.
121  
122 The default value for the C<strategy> parameter is C<sequential>,
123 meaning that Amazon ML takes all of the data records between the
124 C<percentBegin> and C<percentEnd> parameters for the datasource, in the
125 order that the records appear in the input data.
126  
127 The following two C<DataRearrangement> lines are examples of
128 sequentially ordered training and evaluation datasources:
129  
130 Datasource for evaluation: C<{"splitting":{"percentBegin":70,
131 "percentEnd":100, "strategy":"sequential"}}>
132  
133 Datasource for training: C<{"splitting":{"percentBegin":70,
134 "percentEnd":100, "strategy":"sequential", "complement":"true"}}>
135  
136 To randomly split the input data into the proportions indicated by the
137 percentBegin and percentEnd parameters, set the C<strategy> parameter
138 to C<random> and provide a string that is used as the seed value for
139 the random data splitting (for example, you can use the S3 path to your
140 data as the random seed string). If you choose the random split
141 strategy, Amazon ML assigns each row of data a pseudo-random number
142 between 0 and 100, and then selects the rows that have an assigned
143 number between C<percentBegin> and C<percentEnd>. Pseudo-random numbers
144 are assigned using both the input seed string value and the byte offset
145 as a seed, so changing the data results in a different split. Any
146 existing ordering is preserved. The random splitting strategy ensures
147 that variables in the training and evaluation data are distributed
148 similarly. It is useful in the cases where the input data may have an
149 implicit sort order, which would otherwise result in training and
150 evaluation datasources containing non-similar data records.
151  
152 The following two C<DataRearrangement> lines are examples of
153 non-sequentially ordered training and evaluation datasources:
154  
155 Datasource for evaluation: C<{"splitting":{"percentBegin":70,
156 "percentEnd":100, "strategy":"random",
157 "randomSeed"="s3://my_s3_path/bucket/file.csv"}}>
158  
159 Datasource for training: C<{"splitting":{"percentBegin":70,
160 "percentEnd":100, "strategy":"random",
161 "randomSeed"="s3://my_s3_path/bucket/file.csv", "complement":"true"}}>
162  
163 =back
164  
165  
166  
167 =head2 DataSchema => Str
168  
169 A JSON string that represents the schema for an Amazon RDS
170 C<DataSource>. The C<DataSchema> defines the structure of the
171 observation data in the data file(s) referenced in the C<DataSource>.
172  
173 A C<DataSchema> is not required if you specify a C<DataSchemaUri>
174  
175 Define your C<DataSchema> as a series of key-value pairs. C<attributes>
176 and C<excludedVariableNames> have an array of key-value pairs for their
177 value. Use the following format to define your C<DataSchema>.
178  
179 { "version": "1.0",
180  
181 "recordAnnotationFieldName": "F1",
182  
183 "recordWeightFieldName": "F2",
184  
185 "targetFieldName": "F3",
186  
187 "dataFormat": "CSV",
188  
189 "dataFileContainsHeader": true,
190  
191 "attributes": [
192  
193 { "fieldName": "F1", "fieldType": "TEXT" }, { "fieldName": "F2",
194 "fieldType": "NUMERIC" }, { "fieldName": "F3", "fieldType":
195 "CATEGORICAL" }, { "fieldName": "F4", "fieldType": "NUMERIC" }, {
196 "fieldName": "F5", "fieldType": "CATEGORICAL" }, { "fieldName": "F6",
197 "fieldType": "TEXT" }, { "fieldName": "F7", "fieldType":
198 "WEIGHTED_INT_SEQUENCE" }, { "fieldName": "F8", "fieldType":
199 "WEIGHTED_STRING_SEQUENCE" } ],
200  
201 "excludedVariableNames": [ "F6" ] }
202  
203  
204 =head2 DataSchemaUri => Str
205  
206 The Amazon S3 location of the C<DataSchema>.
207  
208  
209 =head2 B<REQUIRED> ResourceRole => Str
210  
211 The role (DataPipelineDefaultResourceRole) assumed by an Amazon Elastic
212 Compute Cloud (Amazon EC2) instance to carry out the copy operation
213 from Amazon RDS to an Amazon S3 task. For more information, see Role
214 templates
215 (https://docs.aws.amazon.com/datapipeline/latest/DeveloperGuide/dp-iam-roles.html)
216 for data pipelines.
217  
218  
219 =head2 B<REQUIRED> S3StagingLocation => Str
220  
221 The Amazon S3 location for staging Amazon RDS data. The data retrieved
222 from Amazon RDS using C<SelectSqlQuery> is stored in this location.
223  
224  
225 =head2 B<REQUIRED> SecurityGroupIds => ArrayRef[Str|Undef]
226  
227 The security group IDs to be used to access a VPC-based RDS DB
228 instance. Ensure that there are appropriate ingress rules set up to
229 allow access to the RDS DB instance. This attribute is used by Data
230 Pipeline to carry out the copy operation from Amazon RDS to an Amazon
231 S3 task.
232  
233  
234 =head2 B<REQUIRED> SelectSqlQuery => Str
235  
236 The query that is used to retrieve the observation data for the
237 C<DataSource>.
238  
239  
240 =head2 B<REQUIRED> ServiceRole => Str
241  
242 The role (DataPipelineDefaultRole) assumed by AWS Data Pipeline service
243 to monitor the progress of the copy task from Amazon RDS to Amazon S3.
244 For more information, see Role templates
245 (https://docs.aws.amazon.com/datapipeline/latest/DeveloperGuide/dp-iam-roles.html)
246 for data pipelines.
247  
248  
249 =head2 B<REQUIRED> SubnetId => Str
250  
251 The subnet ID to be used to access a VPC-based RDS DB instance. This
252 attribute is used by Data Pipeline to carry out the copy task from
253 Amazon RDS to Amazon S3.
254  
255  
256  
257 =head1 SEE ALSO
258  
259 This class forms part of L<Paws>, describing an object used in L<Paws::MachineLearning>
260  
261 =head1 BUGS and CONTRIBUTIONS
262  
263 The source code is located here: L<https://github.com/pplu/aws-sdk-perl>
264  
265 Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues>
266  
267 =cut
268