cloudmersive-image-recognition-api-client 2.0.4 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +26 -19
- data/cloudmersive-image-recognition-api-client.gemspec +1 -1
- data/docs/AgeDetectionResult.md +1 -1
- data/docs/AiImageDetectionApi.md +63 -0
- data/docs/ConvertApi.md +58 -3
- data/docs/FaceApi.md +4 -4
- data/docs/FineTextItem.md +1 -0
- data/docs/ImageAiDetectionResult.md +10 -0
- data/docs/ImageSimilarityComparisonResponse.md +10 -0
- data/docs/ImageSimilarityHashDistanceRequest.md +9 -0
- data/docs/ImageSimilarityHashDistanceResponse.md +9 -0
- data/docs/ImageSimilarityHashResponse.md +9 -0
- data/docs/NsfwAdvancedResult.md +19 -0
- data/docs/NsfwApi.md +169 -4
- data/docs/PersonWithAge.md +4 -1
- data/docs/RecognizeApi.md +124 -58
- data/docs/ResizeApi.md +55 -0
- data/docs/TextItem.md +1 -0
- data/lib/cloudmersive-image-recognition-api-client/api/ai_image_detection_api.rb +78 -0
- data/lib/cloudmersive-image-recognition-api-client/api/artistic_api.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api/convert_api.rb +58 -3
- data/lib/cloudmersive-image-recognition-api-client/api/edit_api.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api/face_api.rb +8 -8
- data/lib/cloudmersive-image-recognition-api-client/api/filter_api.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api/info_api.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api/nsfw_api.rb +170 -5
- data/lib/cloudmersive-image-recognition-api-client/api/recognize_api.rb +171 -104
- data/lib/cloudmersive-image-recognition-api-client/api/resize_api.rb +56 -1
- data/lib/cloudmersive-image-recognition-api-client/api/text_generation_api.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api_client.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api_error.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/configuration.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/age_detection_result.rb +3 -3
- data/lib/cloudmersive-image-recognition-api-client/models/color_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/create_handwriting_request.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/detected_license_plate.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/dominant_color_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/draw_polygon_instance.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/draw_polygon_request.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/draw_rectangle_instance.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/draw_rectangle_request.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/draw_text_instance.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/draw_text_request.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face_compare_response.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face_locate_response.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face_locate_with_landmarks_response.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face_match.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face_point.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/face_with_landmarks.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/find_symbol_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/fine_text_detection_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/fine_text_item.rb +12 -2
- data/lib/cloudmersive-image-recognition-api-client/models/{person_with_gender.rb → image_ai_detection_result.rb} +25 -25
- data/lib/cloudmersive-image-recognition-api-client/models/image_description_response.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/image_metadata.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/image_metadata_exif_value.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/{detected_object.rb → image_similarity_comparison_response.rb} +25 -55
- data/lib/cloudmersive-image-recognition-api-client/models/image_similarity_hash_distance_request.rb +196 -0
- data/lib/cloudmersive-image-recognition-api-client/models/{object_detection_result.rb → image_similarity_hash_distance_response.rb} +12 -24
- data/lib/cloudmersive-image-recognition-api-client/models/{gender_detection_result.rb → image_similarity_hash_response.rb} +12 -24
- data/lib/cloudmersive-image-recognition-api-client/models/nsfw_advanced_result.rb +296 -0
- data/lib/cloudmersive-image-recognition-api-client/models/nsfw_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/person_with_age.rb +36 -5
- data/lib/cloudmersive-image-recognition-api-client/models/polygon_point.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/recognition_outcome.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/text_detection_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/models/text_item.rb +12 -2
- data/lib/cloudmersive-image-recognition-api-client/models/vehicle_license_plate_detection_result.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/version.rb +2 -2
- data/lib/cloudmersive-image-recognition-api-client.rb +8 -5
- data/spec/api/ai_image_detection_api_spec.rb +47 -0
- data/spec/api/artistic_api_spec.rb +1 -1
- data/spec/api/convert_api_spec.rb +14 -2
- data/spec/api/edit_api_spec.rb +1 -1
- data/spec/api/face_api_spec.rb +4 -4
- data/spec/api/filter_api_spec.rb +1 -1
- data/spec/api/info_api_spec.rb +1 -1
- data/spec/api/nsfw_api_spec.rb +39 -3
- data/spec/api/recognize_api_spec.rb +40 -25
- data/spec/api/resize_api_spec.rb +13 -1
- data/spec/api/text_generation_api_spec.rb +1 -1
- data/spec/api_client_spec.rb +1 -1
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/age_detection_result_spec.rb +1 -1
- data/spec/models/color_result_spec.rb +1 -1
- data/spec/models/create_handwriting_request_spec.rb +1 -1
- data/spec/models/detected_license_plate_spec.rb +1 -1
- data/spec/models/dominant_color_result_spec.rb +1 -1
- data/spec/models/draw_polygon_instance_spec.rb +1 -1
- data/spec/models/draw_polygon_request_spec.rb +1 -1
- data/spec/models/draw_rectangle_instance_spec.rb +1 -1
- data/spec/models/draw_rectangle_request_spec.rb +1 -1
- data/spec/models/draw_text_instance_spec.rb +1 -1
- data/spec/models/draw_text_request_spec.rb +1 -1
- data/spec/models/face_compare_response_spec.rb +1 -1
- data/spec/models/face_locate_response_spec.rb +1 -1
- data/spec/models/face_locate_with_landmarks_response_spec.rb +1 -1
- data/spec/models/face_match_spec.rb +1 -1
- data/spec/models/face_point_spec.rb +1 -1
- data/spec/models/face_spec.rb +1 -1
- data/spec/models/face_with_landmarks_spec.rb +1 -1
- data/spec/models/find_symbol_result_spec.rb +1 -1
- data/spec/models/fine_text_detection_result_spec.rb +1 -1
- data/spec/models/fine_text_item_spec.rb +7 -1
- data/spec/models/{person_with_gender_spec.rb → image_ai_detection_result_spec.rb} +10 -10
- data/spec/models/image_description_response_spec.rb +1 -1
- data/spec/models/image_metadata_exif_value_spec.rb +1 -1
- data/spec/models/image_metadata_spec.rb +1 -1
- data/spec/models/{gender_detection_result_spec.rb → image_similarity_comparison_response_spec.rb} +9 -9
- data/spec/models/image_similarity_hash_distance_request_spec.rb +47 -0
- data/spec/models/{object_detection_result_spec.rb → image_similarity_hash_distance_response_spec.rb} +8 -14
- data/spec/models/image_similarity_hash_response_spec.rb +47 -0
- data/spec/models/nsfw_advanced_result_spec.rb +107 -0
- data/spec/models/nsfw_result_spec.rb +1 -1
- data/spec/models/person_with_age_spec.rb +19 -1
- data/spec/models/polygon_point_spec.rb +1 -1
- data/spec/models/recognition_outcome_spec.rb +1 -1
- data/spec/models/text_detection_result_spec.rb +1 -1
- data/spec/models/text_item_spec.rb +7 -1
- data/spec/models/vehicle_license_plate_detection_result_spec.rb +1 -1
- data/spec/spec_helper.rb +1 -1
- metadata +39 -30
- data/docs/DetectedObject.md +0 -13
- data/docs/GenderDetectionResult.md +0 -10
- data/docs/ObjectDetectionResult.md +0 -10
- data/docs/PersonWithGender.md +0 -10
- data/spec/models/detected_object_spec.rb +0 -71
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -24,15 +24,28 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
24
24
|
# The person's age range classification result in years; possible values are \"0-2\", \"4-6\", \"8-13\", \"15-20\", \"25-32\", \"38-43\", \"48-53\", \"60+\"
|
|
25
25
|
attr_accessor :age_class
|
|
26
26
|
|
|
27
|
+
# The specific estimated age of the person
|
|
27
28
|
attr_accessor :age
|
|
28
29
|
|
|
30
|
+
# Gender estimation classification as Female or Male
|
|
31
|
+
attr_accessor :gender_classification
|
|
32
|
+
|
|
33
|
+
# Confidence level of classification as female; possible values are between 0.0 and 1.0
|
|
34
|
+
attr_accessor :gender_female_confidence
|
|
35
|
+
|
|
36
|
+
# Confidence level of classification as male; possible values are between 0.0 and 1.0
|
|
37
|
+
attr_accessor :gender_male_confidence
|
|
38
|
+
|
|
29
39
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
30
40
|
def self.attribute_map
|
|
31
41
|
{
|
|
32
42
|
:'face_location' => :'FaceLocation',
|
|
33
43
|
:'age_classification_confidence' => :'AgeClassificationConfidence',
|
|
34
44
|
:'age_class' => :'AgeClass',
|
|
35
|
-
:'age' => :'Age'
|
|
45
|
+
:'age' => :'Age',
|
|
46
|
+
:'gender_classification' => :'GenderClassification',
|
|
47
|
+
:'gender_female_confidence' => :'GenderFemaleConfidence',
|
|
48
|
+
:'gender_male_confidence' => :'GenderMaleConfidence'
|
|
36
49
|
}
|
|
37
50
|
end
|
|
38
51
|
|
|
@@ -42,7 +55,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
42
55
|
:'face_location' => :'Face',
|
|
43
56
|
:'age_classification_confidence' => :'Float',
|
|
44
57
|
:'age_class' => :'String',
|
|
45
|
-
:'age' => :'Float'
|
|
58
|
+
:'age' => :'Float',
|
|
59
|
+
:'gender_classification' => :'String',
|
|
60
|
+
:'gender_female_confidence' => :'Float',
|
|
61
|
+
:'gender_male_confidence' => :'Float'
|
|
46
62
|
}
|
|
47
63
|
end
|
|
48
64
|
|
|
@@ -69,6 +85,18 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
69
85
|
if attributes.has_key?(:'Age')
|
|
70
86
|
self.age = attributes[:'Age']
|
|
71
87
|
end
|
|
88
|
+
|
|
89
|
+
if attributes.has_key?(:'GenderClassification')
|
|
90
|
+
self.gender_classification = attributes[:'GenderClassification']
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
if attributes.has_key?(:'GenderFemaleConfidence')
|
|
94
|
+
self.gender_female_confidence = attributes[:'GenderFemaleConfidence']
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
if attributes.has_key?(:'GenderMaleConfidence')
|
|
98
|
+
self.gender_male_confidence = attributes[:'GenderMaleConfidence']
|
|
99
|
+
end
|
|
72
100
|
end
|
|
73
101
|
|
|
74
102
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -92,7 +120,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
92
120
|
face_location == o.face_location &&
|
|
93
121
|
age_classification_confidence == o.age_classification_confidence &&
|
|
94
122
|
age_class == o.age_class &&
|
|
95
|
-
age == o.age
|
|
123
|
+
age == o.age &&
|
|
124
|
+
gender_classification == o.gender_classification &&
|
|
125
|
+
gender_female_confidence == o.gender_female_confidence &&
|
|
126
|
+
gender_male_confidence == o.gender_male_confidence
|
|
96
127
|
end
|
|
97
128
|
|
|
98
129
|
# @see the `==` method
|
|
@@ -104,7 +135,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
104
135
|
# Calculates hash code according to all attributes.
|
|
105
136
|
# @return [Fixnum] Hash code
|
|
106
137
|
def hash
|
|
107
|
-
[face_location, age_classification_confidence, age_class, age].hash
|
|
138
|
+
[face_location, age_classification_confidence, age_class, age, gender_classification, gender_female_confidence, gender_male_confidence].hash
|
|
108
139
|
end
|
|
109
140
|
|
|
110
141
|
# Builds the object from hash
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -15,6 +15,9 @@ require 'date'
|
|
|
15
15
|
module CloudmersiveImageRecognitionApiClient
|
|
16
16
|
# Individual instance of text occuring in an image; one piece of text
|
|
17
17
|
class TextItem
|
|
18
|
+
# Text detected in the image
|
|
19
|
+
attr_accessor :detected_text
|
|
20
|
+
|
|
18
21
|
# Left X coordinate of the text location; 0 represents the left edge of the input image
|
|
19
22
|
attr_accessor :left_x
|
|
20
23
|
|
|
@@ -30,6 +33,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
30
33
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
31
34
|
def self.attribute_map
|
|
32
35
|
{
|
|
36
|
+
:'detected_text' => :'DetectedText',
|
|
33
37
|
:'left_x' => :'LeftX',
|
|
34
38
|
:'top_y' => :'TopY',
|
|
35
39
|
:'width' => :'Width',
|
|
@@ -40,6 +44,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
40
44
|
# Attribute type mapping.
|
|
41
45
|
def self.swagger_types
|
|
42
46
|
{
|
|
47
|
+
:'detected_text' => :'String',
|
|
43
48
|
:'left_x' => :'Integer',
|
|
44
49
|
:'top_y' => :'Integer',
|
|
45
50
|
:'width' => :'Integer',
|
|
@@ -55,6 +60,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
55
60
|
# convert string to symbol for hash key
|
|
56
61
|
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
57
62
|
|
|
63
|
+
if attributes.has_key?(:'DetectedText')
|
|
64
|
+
self.detected_text = attributes[:'DetectedText']
|
|
65
|
+
end
|
|
66
|
+
|
|
58
67
|
if attributes.has_key?(:'LeftX')
|
|
59
68
|
self.left_x = attributes[:'LeftX']
|
|
60
69
|
end
|
|
@@ -90,6 +99,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
90
99
|
def ==(o)
|
|
91
100
|
return true if self.equal?(o)
|
|
92
101
|
self.class == o.class &&
|
|
102
|
+
detected_text == o.detected_text &&
|
|
93
103
|
left_x == o.left_x &&
|
|
94
104
|
top_y == o.top_y &&
|
|
95
105
|
width == o.width &&
|
|
@@ -105,7 +115,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
|
105
115
|
# Calculates hash code according to all attributes.
|
|
106
116
|
# @return [Fixnum] Hash code
|
|
107
117
|
def hash
|
|
108
|
-
[left_x, top_y, width, height].hash
|
|
118
|
+
[detected_text, left_x, top_y, width, height].hash
|
|
109
119
|
end
|
|
110
120
|
|
|
111
121
|
# Builds the object from hash
|
data/lib/cloudmersive-image-recognition-api-client/models/vehicle_license_plate_detection_result.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -11,5 +11,5 @@ Swagger Codegen version: 2.4.14
|
|
|
11
11
|
=end
|
|
12
12
|
|
|
13
13
|
module CloudmersiveImageRecognitionApiClient
|
|
14
|
-
VERSION = '2.0
|
|
14
|
+
VERSION = '2.1.0'
|
|
15
15
|
end
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -21,7 +21,6 @@ require 'cloudmersive-image-recognition-api-client/models/age_detection_result'
|
|
|
21
21
|
require 'cloudmersive-image-recognition-api-client/models/color_result'
|
|
22
22
|
require 'cloudmersive-image-recognition-api-client/models/create_handwriting_request'
|
|
23
23
|
require 'cloudmersive-image-recognition-api-client/models/detected_license_plate'
|
|
24
|
-
require 'cloudmersive-image-recognition-api-client/models/detected_object'
|
|
25
24
|
require 'cloudmersive-image-recognition-api-client/models/dominant_color_result'
|
|
26
25
|
require 'cloudmersive-image-recognition-api-client/models/draw_polygon_instance'
|
|
27
26
|
require 'cloudmersive-image-recognition-api-client/models/draw_polygon_request'
|
|
@@ -39,14 +38,17 @@ require 'cloudmersive-image-recognition-api-client/models/face_with_landmarks'
|
|
|
39
38
|
require 'cloudmersive-image-recognition-api-client/models/find_symbol_result'
|
|
40
39
|
require 'cloudmersive-image-recognition-api-client/models/fine_text_detection_result'
|
|
41
40
|
require 'cloudmersive-image-recognition-api-client/models/fine_text_item'
|
|
42
|
-
require 'cloudmersive-image-recognition-api-client/models/
|
|
41
|
+
require 'cloudmersive-image-recognition-api-client/models/image_ai_detection_result'
|
|
43
42
|
require 'cloudmersive-image-recognition-api-client/models/image_description_response'
|
|
44
43
|
require 'cloudmersive-image-recognition-api-client/models/image_metadata'
|
|
45
44
|
require 'cloudmersive-image-recognition-api-client/models/image_metadata_exif_value'
|
|
45
|
+
require 'cloudmersive-image-recognition-api-client/models/image_similarity_comparison_response'
|
|
46
|
+
require 'cloudmersive-image-recognition-api-client/models/image_similarity_hash_distance_request'
|
|
47
|
+
require 'cloudmersive-image-recognition-api-client/models/image_similarity_hash_distance_response'
|
|
48
|
+
require 'cloudmersive-image-recognition-api-client/models/image_similarity_hash_response'
|
|
49
|
+
require 'cloudmersive-image-recognition-api-client/models/nsfw_advanced_result'
|
|
46
50
|
require 'cloudmersive-image-recognition-api-client/models/nsfw_result'
|
|
47
|
-
require 'cloudmersive-image-recognition-api-client/models/object_detection_result'
|
|
48
51
|
require 'cloudmersive-image-recognition-api-client/models/person_with_age'
|
|
49
|
-
require 'cloudmersive-image-recognition-api-client/models/person_with_gender'
|
|
50
52
|
require 'cloudmersive-image-recognition-api-client/models/polygon_point'
|
|
51
53
|
require 'cloudmersive-image-recognition-api-client/models/recognition_outcome'
|
|
52
54
|
require 'cloudmersive-image-recognition-api-client/models/text_detection_result'
|
|
@@ -54,6 +56,7 @@ require 'cloudmersive-image-recognition-api-client/models/text_item'
|
|
|
54
56
|
require 'cloudmersive-image-recognition-api-client/models/vehicle_license_plate_detection_result'
|
|
55
57
|
|
|
56
58
|
# APIs
|
|
59
|
+
require 'cloudmersive-image-recognition-api-client/api/ai_image_detection_api'
|
|
57
60
|
require 'cloudmersive-image-recognition-api-client/api/artistic_api'
|
|
58
61
|
require 'cloudmersive-image-recognition-api-client/api/convert_api'
|
|
59
62
|
require 'cloudmersive-image-recognition-api-client/api/edit_api'
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#imageapi
|
|
3
|
+
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
|
+
|
|
6
|
+
OpenAPI spec version: v1
|
|
7
|
+
|
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
|
9
|
+
Swagger Codegen version: 2.4.14
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'spec_helper'
|
|
14
|
+
require 'json'
|
|
15
|
+
|
|
16
|
+
# Unit tests for CloudmersiveImageRecognitionApiClient::AiImageDetectionApi
|
|
17
|
+
# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
|
|
18
|
+
# Please update as you see appropriate
|
|
19
|
+
describe 'AiImageDetectionApi' do
|
|
20
|
+
before do
|
|
21
|
+
# run before each test
|
|
22
|
+
@instance = CloudmersiveImageRecognitionApiClient::AiImageDetectionApi.new
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
after do
|
|
26
|
+
# run after each test
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
describe 'test an instance of AiImageDetectionApi' do
|
|
30
|
+
it 'should create an instance of AiImageDetectionApi' do
|
|
31
|
+
expect(@instance).to be_instance_of(CloudmersiveImageRecognitionApiClient::AiImageDetectionApi)
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# unit tests for ai_image_detection_detect_file
|
|
36
|
+
# Detect if an input image was generated using AI
|
|
37
|
+
# Detects if the input image was generated using AI tools.
|
|
38
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
39
|
+
# @param [Hash] opts the optional parameters
|
|
40
|
+
# @return [ImageAiDetectionResult]
|
|
41
|
+
describe 'ai_image_detection_detect_file test' do
|
|
42
|
+
it 'should work' do
|
|
43
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
44
|
+
end
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
end
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -57,7 +57,7 @@ describe 'ConvertApi' do
|
|
|
57
57
|
end
|
|
58
58
|
|
|
59
59
|
# unit tests for convert_to_jpg
|
|
60
|
-
# Convert input image to JPG, JPEG format
|
|
60
|
+
# Convert input image to JPG, JPEG format at specific quality
|
|
61
61
|
# Converts the input image into JPEG/JPG format. Customize encoding parameters. Supported input file formats include AAI, ART, ARW, AVS, BPG, BMP, BMP2, BMP3, BRF, CALS, CGM, CIN, CMYK, CMYKA, CR2, CRW, CUR, CUT, DCM, DCR, DCX, DDS, DIB, DJVU, DNG, DOT, DPX, EMF, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EXR, FAX, FIG, FITS, FPX, GIF, GPLT, GRAY, HDR, HEIC, HPGL, HRZ, ICO, ISOBRL, ISBRL6, JBIG, JNG, JP2, JPT, J2C, J2K, JPEG/JPG, JXR, MAT, MONO, MNG, M2V, MRW, MTV, NEF, ORF, OTB, P7, PALM, PAM, PBM, PCD, PCDS, PCL, PCX, PDF, PEF, PES, PFA, PFB, PFM, PGM, PICON, PICT, PIX, PNG, PNG8, PNG00, PNG24, PNG32, PNG48, PNG64, PNM, PPM, PSB, PSD, PTIF, PWB, RAD, RAF, RGB, RGBA, RGF, RLA, RLE, SCT, SFW, SGI, SID, SUN, SVG, TGA, TIFF, TIM, UIL, VIFF, VICAR, VBMP, WDP, WEBP, WPG, X, XBM, XCF, XPM, XWD, X3F, YCbCr, YCbCrA, YUV.
|
|
62
62
|
# @param quality Set the JPEG quality level; lowest quality is 1 (highest compression), highest quality (lowest compression) is 100; recommended value is 75
|
|
63
63
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
@@ -69,6 +69,18 @@ describe 'ConvertApi' do
|
|
|
69
69
|
end
|
|
70
70
|
end
|
|
71
71
|
|
|
72
|
+
# unit tests for convert_to_jpg_default_quality
|
|
73
|
+
# Convert input image to JPG, JPEG format
|
|
74
|
+
# Converts the input image into JPEG/JPG format. Customize encoding parameters. Supported input file formats include AAI, ART, ARW, AVS, BPG, BMP, BMP2, BMP3, BRF, CALS, CGM, CIN, CMYK, CMYKA, CR2, CRW, CUR, CUT, DCM, DCR, DCX, DDS, DIB, DJVU, DNG, DOT, DPX, EMF, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EXR, FAX, FIG, FITS, FPX, GIF, GPLT, GRAY, HDR, HEIC, HPGL, HRZ, ICO, ISOBRL, ISBRL6, JBIG, JNG, JP2, JPT, J2C, J2K, JPEG/JPG, JXR, MAT, MONO, MNG, M2V, MRW, MTV, NEF, ORF, OTB, P7, PALM, PAM, PBM, PCD, PCDS, PCL, PCX, PDF, PEF, PES, PFA, PFB, PFM, PGM, PICON, PICT, PIX, PNG, PNG8, PNG00, PNG24, PNG32, PNG48, PNG64, PNM, PPM, PSB, PSD, PTIF, PWB, RAD, RAF, RGB, RGBA, RGF, RLA, RLE, SCT, SFW, SGI, SID, SUN, SVG, TGA, TIFF, TIM, UIL, VIFF, VICAR, VBMP, WDP, WEBP, WPG, X, XBM, XCF, XPM, XWD, X3F, YCbCr, YCbCrA, YUV.
|
|
75
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
76
|
+
# @param [Hash] opts the optional parameters
|
|
77
|
+
# @return [Object]
|
|
78
|
+
describe 'convert_to_jpg_default_quality test' do
|
|
79
|
+
it 'should work' do
|
|
80
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
|
|
72
84
|
# unit tests for convert_to_photoshop
|
|
73
85
|
# Convert input image to Photoshop PSD format
|
|
74
86
|
# Converts the input image into PSD format. Supported input file formats include AAI, ART, ARW, AVS, BPG, BMP, BMP2, BMP3, BRF, CALS, CGM, CIN, CMYK, CMYKA, CR2, CRW, CUR, CUT, DCM, DCR, DCX, DDS, DIB, DJVU, DNG, DOT, DPX, EMF, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EXR, FAX, FIG, FITS, FPX, GIF, GPLT, GRAY, HDR, HEIC, HPGL, HRZ, ICO, ISOBRL, ISBRL6, JBIG, JNG, JP2, JPT, J2C, J2K, JPEG/JPG, JXR, MAT, MONO, MNG, M2V, MRW, MTV, NEF, ORF, OTB, P7, PALM, PAM, PBM, PCD, PCDS, PCL, PCX, PDF, PEF, PES, PFA, PFB, PFM, PGM, PICON, PICT, PIX, PNG, PNG8, PNG00, PNG24, PNG32, PNG48, PNG64, PNM, PPM, PSB, PSD, PTIF, PWB, RAD, RAF, RGB, RGBA, RGF, RLA, RLE, SCT, SFW, SGI, SID, SUN, SVG, TGA, TIFF, TIM, UIL, VIFF, VICAR, VBMP, WDP, WEBP, WPG, X, XBM, XCF, XPM, XWD, X3F, YCbCr, YCbCrA, YUV.
|
data/spec/api/edit_api_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
data/spec/api/face_api_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -71,7 +71,7 @@ describe 'FaceApi' do
|
|
|
71
71
|
|
|
72
72
|
# unit tests for face_detect_age
|
|
73
73
|
# Detect the age of people in an image
|
|
74
|
-
# Identify the age, position, and size of human faces in an image, along with a recognition confidence level. People in the image do NOT need to be facing the camera; they can be facing away, edge-on, etc.
|
|
74
|
+
# Identify the age, position, and size of human faces in an image, along with a recognition confidence level. People in the image do NOT need to be facing the camera; they can be facing away, edge-on, etc. Input image should be a PNG or JPG. Consumes 20 API calls.
|
|
75
75
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
76
76
|
# @param [Hash] opts the optional parameters
|
|
77
77
|
# @return [AgeDetectionResult]
|
|
@@ -83,10 +83,10 @@ describe 'FaceApi' do
|
|
|
83
83
|
|
|
84
84
|
# unit tests for face_detect_gender
|
|
85
85
|
# Detect the gender of people in an image
|
|
86
|
-
# Identify the gender, position, and size of human faces in an image, along with a recognition confidence level. People in the image should be facing the camera.
|
|
86
|
+
# Identify the gender, position, and size of human faces in an image, along with a recognition confidence level. People in the image should be facing the camera. Input image should be a PNG or JPG. Consumes 20 API calls.
|
|
87
87
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
88
88
|
# @param [Hash] opts the optional parameters
|
|
89
|
-
# @return [
|
|
89
|
+
# @return [AgeDetectionResult]
|
|
90
90
|
describe 'face_detect_gender test' do
|
|
91
91
|
it 'should work' do
|
|
92
92
|
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
data/spec/api/filter_api_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
data/spec/api/info_api_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
data/spec/api/nsfw_api_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -33,8 +33,8 @@ describe 'NsfwApi' do
|
|
|
33
33
|
end
|
|
34
34
|
|
|
35
35
|
# unit tests for nsfw_classify
|
|
36
|
-
# Not safe for work NSFW
|
|
37
|
-
# Classify an image into Not Safe For Work (NSFW)/
|
|
36
|
+
# Not safe for work (NSFW) content classification for Images
|
|
37
|
+
# Classify an image into Not Safe For Work (NSFW)/Pornographic/Nudity/Racy content and Safe Content. Helpful for filtering out unsafe content when processing user images. Input image should be JPG, PNG or GIF. Consumes 20 API calls.
|
|
38
38
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
39
39
|
# @param [Hash] opts the optional parameters
|
|
40
40
|
# @return [NsfwResult]
|
|
@@ -44,4 +44,40 @@ describe 'NsfwApi' do
|
|
|
44
44
|
end
|
|
45
45
|
end
|
|
46
46
|
|
|
47
|
+
# unit tests for nsfw_classify_advanced
|
|
48
|
+
# Advanced content moderation and not safe for work (NSFW) content classification for Images
|
|
49
|
+
# Uses advanced AI to classify an image into Not Safe For Work (NSFW) or not and determine if it contains nudity, graphic violence, non-graphic violence, self-harm, hate, potential illegal activity, medical imagery, or profanity. Helpful for filtering out unsafe content when processing user images. Input image should be JPG, PNG. Consumes 100 API calls. Requires Managed Instance or Private Cloud deployment, and a GPU.
|
|
50
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
51
|
+
# @param [Hash] opts the optional parameters
|
|
52
|
+
# @return [NsfwAdvancedResult]
|
|
53
|
+
describe 'nsfw_classify_advanced test' do
|
|
54
|
+
it 'should work' do
|
|
55
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# unit tests for nsfw_classify_document
|
|
60
|
+
# Not safe for work (NSFW) content classification for Documents
|
|
61
|
+
# Classify a document (PDF, DOCX, DOC, XLSX, XLS, PPTX, PPT) into Not Safe For Work (NSFW)/Pornographic/Nudity/Racy content and Safe Content. Helpful for filtering out unsafe content when processing user images. Consumes 20 API calls per image.
|
|
62
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
63
|
+
# @param [Hash] opts the optional parameters
|
|
64
|
+
# @return [NsfwResult]
|
|
65
|
+
describe 'nsfw_classify_document test' do
|
|
66
|
+
it 'should work' do
|
|
67
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
68
|
+
end
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
# unit tests for nsfw_classify_video
|
|
72
|
+
# Not safe for work (NSFW) content classification for Video
|
|
73
|
+
# Classify a video into Not Safe For Work (NSFW)/Pornographic/Nudity/Racy content and Safe Content. Helpful for filtering out unsafe content when processing user images. Input image should be MP4, MOV, WEBM, MKV, AVI, FLV, MPG, GIF. Consumes 20 API calls per frame analyzed. Requires Cloudmersive Managed Instance or Private Cloud deployment.
|
|
74
|
+
# @param video_file Video file to perform the operation on. Common file formats such as MP4, MPG are supported.
|
|
75
|
+
# @param [Hash] opts the optional parameters
|
|
76
|
+
# @return [NsfwResult]
|
|
77
|
+
describe 'nsfw_classify_video test' do
|
|
78
|
+
it 'should work' do
|
|
79
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
|
|
47
83
|
end
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -57,30 +57,6 @@ describe 'RecognizeApi' do
|
|
|
57
57
|
end
|
|
58
58
|
end
|
|
59
59
|
|
|
60
|
-
# unit tests for recognize_detect_objects
|
|
61
|
-
# Detect objects including types and locations in an image
|
|
62
|
-
# Identify the position, size and description of objects in an image, along with a recognition confidence level. Detects both human people and objects in an image.
|
|
63
|
-
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
64
|
-
# @param [Hash] opts the optional parameters
|
|
65
|
-
# @return [ObjectDetectionResult]
|
|
66
|
-
describe 'recognize_detect_objects test' do
|
|
67
|
-
it 'should work' do
|
|
68
|
-
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
69
|
-
end
|
|
70
|
-
end
|
|
71
|
-
|
|
72
|
-
# unit tests for recognize_detect_people
|
|
73
|
-
# Detect people including locations in an image
|
|
74
|
-
# Identify the position, and size of human people in an image, along with a recognition confidence level. People in the image do NOT need to be facing the camera; they can be facing away, edge-on, etc.
|
|
75
|
-
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
76
|
-
# @param [Hash] opts the optional parameters
|
|
77
|
-
# @return [ObjectDetectionResult]
|
|
78
|
-
describe 'recognize_detect_people test' do
|
|
79
|
-
it 'should work' do
|
|
80
|
-
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
81
|
-
end
|
|
82
|
-
end
|
|
83
|
-
|
|
84
60
|
# unit tests for recognize_detect_text_fine
|
|
85
61
|
# Detect fine text in a photo of a document
|
|
86
62
|
# Identify the position, and size of small/fine text within a photograph of a document. Identify the location of small text in a photo - such as words and other forms of high density text. Can be used on a scan of a document or a photograph (e.g. smartphone camera) of a document, page or receipt. For OCR purposes - please see our Deep Learning OCR APIs.
|
|
@@ -130,4 +106,43 @@ describe 'RecognizeApi' do
|
|
|
130
106
|
end
|
|
131
107
|
end
|
|
132
108
|
|
|
109
|
+
# unit tests for recognize_similarity_compare
|
|
110
|
+
# Compare two images for similarity
|
|
111
|
+
# Generates an image similarity score using Deep Learning between 0.0 and 1.0, values closer to 1.0 indicate greater similarity
|
|
112
|
+
# @param base_image Image file to compare against. Common file formats such as PNG, JPEG are supported.
|
|
113
|
+
# @param comparison_image Image to compare to the base image.
|
|
114
|
+
# @param [Hash] opts the optional parameters
|
|
115
|
+
# @option opts [String] :recognition_mode Optional, specify the recognition mode; possible values are Normal, Basic and Advanced. Default is Normal.
|
|
116
|
+
# @return [String]
|
|
117
|
+
describe 'recognize_similarity_compare test' do
|
|
118
|
+
it 'should work' do
|
|
119
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
120
|
+
end
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# unit tests for recognize_similarity_hash
|
|
124
|
+
# Generate a perceptual image hash
|
|
125
|
+
# Generates a hash value for the image; hash values that are closer together in terms of Hamming Distance are more similar.
|
|
126
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
127
|
+
# @param [Hash] opts the optional parameters
|
|
128
|
+
# @option opts [String] :recognition_mode Optional, specify the recognition mode; possible values are Normal, Basic and Advanced. Default is Normal.
|
|
129
|
+
# @return [ImageSimilarityHashResponse]
|
|
130
|
+
describe 'recognize_similarity_hash test' do
|
|
131
|
+
it 'should work' do
|
|
132
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
# unit tests for recognize_similarity_hash_distance
|
|
137
|
+
# Calculates the similarity between two perceptual image hashes
|
|
138
|
+
# Calculates the similarity between two perceptual image hashes by computing the Hamming Distance between them.
|
|
139
|
+
# @param request
|
|
140
|
+
# @param [Hash] opts the optional parameters
|
|
141
|
+
# @return [ImageSimilarityHashDistanceResponse]
|
|
142
|
+
describe 'recognize_similarity_hash_distance test' do
|
|
143
|
+
it 'should work' do
|
|
144
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
145
|
+
end
|
|
146
|
+
end
|
|
147
|
+
|
|
133
148
|
end
|
data/spec/api/resize_api_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -46,6 +46,18 @@ describe 'ResizeApi' do
|
|
|
46
46
|
end
|
|
47
47
|
end
|
|
48
48
|
|
|
49
|
+
# unit tests for resize_resize_ai_super_sampling
|
|
50
|
+
# Resize an image with AI super sampling
|
|
51
|
+
# Use AI super sampling to resize a small or low resolution image to twice the size. Input image should be PNG or JPG, and smaller than 200 x 200 pixels (larger images will be resized down). Consumes 20 API calls.
|
|
52
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
|
53
|
+
# @param [Hash] opts the optional parameters
|
|
54
|
+
# @return [String]
|
|
55
|
+
describe 'resize_resize_ai_super_sampling test' do
|
|
56
|
+
it 'should work' do
|
|
57
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
|
58
|
+
end
|
|
59
|
+
end
|
|
60
|
+
|
|
49
61
|
# unit tests for resize_resize_simple
|
|
50
62
|
# Resize an image
|
|
51
63
|
# Resize an image to a specific width and specific height. Resize is EXIF-aware.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
data/spec/api_client_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
data/spec/configuration_spec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
=begin
|
|
2
2
|
#imageapi
|
|
3
3
|
|
|
4
|
-
#Image Recognition and Processing APIs let you use Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
4
|
+
#Image Recognition and Processing APIs let you use Artificial Intelligence and Machine Learning to recognize and process images, and also perform useful image modification operations.
|
|
5
5
|
|
|
6
6
|
OpenAPI spec version: v1
|
|
7
7
|
|