| 1 | package Google::Cloud::Automl::V1beta1::Classification::Types; | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | use Type::Library -base; | ||
| 7 | use Type::Utils -all; | ||
| 8 | use Types::Standard -types; | ||
| 9 | |||
| 10 | declare 'ClassificationType', | ||
| 11 | as (Int | Str); | ||
| 12 | |||
| 13 | declare 'ClassificationAnnotation', | ||
| 14 | as InstanceOf['Google::Cloud::Automl::V1beta1::Classification::ClassificationAnnotation']; | ||
| 15 | |||
| 16 | coerce 'ClassificationAnnotation', | ||
| 17 | from HashRef, via { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationAnnotation'->new($_) }; | ||
| 18 | |||
| 19 | declare 'RepeatedClassificationAnnotation', | ||
| 20 | as ArrayRef[ClassificationAnnotation()]; | ||
| 21 | |||
| 22 | coerce 'RepeatedClassificationAnnotation', | ||
| 23 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationAnnotation'->new($_) } @$_ ] }; | ||
| 24 | |||
| 25 | declare 'MapStringClassificationAnnotation', | ||
| 26 | as HashRef[ClassificationAnnotation()]; | ||
| 27 | |||
| 28 | declare 'VideoClassificationAnnotation', | ||
| 29 | as InstanceOf['Google::Cloud::Automl::V1beta1::Classification::VideoClassificationAnnotation']; | ||
| 30 | |||
| 31 | coerce 'VideoClassificationAnnotation', | ||
| 32 | from HashRef, via { 'Google::Cloud::Automl::V1beta1::Classification::VideoClassificationAnnotation'->new($_) }; | ||
| 33 | |||
| 34 | declare 'RepeatedVideoClassificationAnnotation', | ||
| 35 | as ArrayRef[VideoClassificationAnnotation()]; | ||
| 36 | |||
| 37 | coerce 'RepeatedVideoClassificationAnnotation', | ||
| 38 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Automl::V1beta1::Classification::VideoClassificationAnnotation'->new($_) } @$_ ] }; | ||
| 39 | |||
| 40 | declare 'MapStringVideoClassificationAnnotation', | ||
| 41 | as HashRef[VideoClassificationAnnotation()]; | ||
| 42 | |||
| 43 | declare 'ClassificationEvaluationMetrics', | ||
| 44 | as InstanceOf['Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics']; | ||
| 45 | |||
| 46 | coerce 'ClassificationEvaluationMetrics', | ||
| 47 | from HashRef, via { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics'->new($_) }; | ||
| 48 | |||
| 49 | declare 'RepeatedClassificationEvaluationMetrics', | ||
| 50 | as ArrayRef[ClassificationEvaluationMetrics()]; | ||
| 51 | |||
| 52 | coerce 'RepeatedClassificationEvaluationMetrics', | ||
| 53 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics'->new($_) } @$_ ] }; | ||
| 54 | |||
| 55 | declare 'MapStringClassificationEvaluationMetrics', | ||
| 56 | as HashRef[ClassificationEvaluationMetrics()]; | ||
| 57 | |||
| 58 | declare 'ConfidenceMetricsEntry', | ||
| 59 | as InstanceOf['Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfidenceMetricsEntry']; | ||
| 60 | |||
| 61 | coerce 'ConfidenceMetricsEntry', | ||
| 62 | from HashRef, via { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfidenceMetricsEntry'->new($_) }; | ||
| 63 | |||
| 64 | declare 'RepeatedConfidenceMetricsEntry', | ||
| 65 | as ArrayRef[ConfidenceMetricsEntry()]; | ||
| 66 | |||
| 67 | coerce 'RepeatedConfidenceMetricsEntry', | ||
| 68 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfidenceMetricsEntry'->new($_) } @$_ ] }; | ||
| 69 | |||
| 70 | declare 'MapStringConfidenceMetricsEntry', | ||
| 71 | as HashRef[ConfidenceMetricsEntry()]; | ||
| 72 | |||
| 73 | declare 'ConfusionMatrix', | ||
| 74 | as InstanceOf['Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfusionMatrix']; | ||
| 75 | |||
| 76 | coerce 'ConfusionMatrix', | ||
| 77 | from HashRef, via { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfusionMatrix'->new($_) }; | ||
| 78 | |||
| 79 | declare 'RepeatedConfusionMatrix', | ||
| 80 | as ArrayRef[ConfusionMatrix()]; | ||
| 81 | |||
| 82 | coerce 'RepeatedConfusionMatrix', | ||
| 83 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfusionMatrix'->new($_) } @$_ ] }; | ||
| 84 | |||
| 85 | declare 'MapStringConfusionMatrix', | ||
| 86 | as HashRef[ConfusionMatrix()]; | ||
| 87 | |||
| 88 | declare 'Row', | ||
| 89 | as InstanceOf['Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfusionMatrix::Row']; | ||
| 90 | |||
| 91 | coerce 'Row', | ||
| 92 | from HashRef, via { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfusionMatrix::Row'->new($_) }; | ||
| 93 | |||
| 94 | declare 'RepeatedRow', | ||
| 95 | as ArrayRef[Row()]; | ||
| 96 | |||
| 97 | coerce 'RepeatedRow', | ||
| 98 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Automl::V1beta1::Classification::ClassificationEvaluationMetrics::ConfusionMatrix::Row'->new($_) } @$_ ] }; | ||
| 99 | |||
| 100 | declare 'MapStringRow', | ||
| 101 | as HashRef[Row()]; | ||
| 102 | |||
| 103 | 1; | ||
| 104 | |||
| 105 | __END__ |