cloudmersive-image-recognition-api-client 1.4.6 → 2.0.5
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/Gemfile +1 -1
- data/README.md +17 -6
- data/cloudmersive-image-recognition-api-client.gemspec +3 -3
- data/docs/ArtisticApi.md +2 -2
- data/docs/ConvertApi.md +7 -7
- data/docs/CreateHandwritingRequest.md +11 -0
- data/docs/DrawTextInstance.md +1 -1
- data/docs/EditApi.md +147 -11
- data/docs/FaceApi.md +8 -8
- data/docs/FilterApi.md +8 -8
- 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/InfoApi.md +2 -2
- data/docs/NsfwApi.md +1 -1
- data/docs/RecognizeApi.md +187 -11
- data/docs/ResizeApi.md +4 -4
- data/docs/TextGenerationApi.md +63 -0
- data/lib/cloudmersive-image-recognition-api-client.rb +7 -1
- data/lib/cloudmersive-image-recognition-api-client/api/artistic_api.rb +6 -7
- data/lib/cloudmersive-image-recognition-api-client/api/convert_api.rb +30 -37
- data/lib/cloudmersive-image-recognition-api-client/api/edit_api.rb +199 -58
- data/lib/cloudmersive-image-recognition-api-client/api/face_api.rb +31 -38
- data/lib/cloudmersive-image-recognition-api-client/api/filter_api.rb +34 -42
- data/lib/cloudmersive-image-recognition-api-client/api/info_api.rb +10 -12
- data/lib/cloudmersive-image-recognition-api-client/api/nsfw_api.rb +6 -7
- data/lib/cloudmersive-image-recognition-api-client/api/recognize_api.rb +214 -45
- data/lib/cloudmersive-image-recognition-api-client/api/resize_api.rb +14 -16
- data/lib/cloudmersive-image-recognition-api-client/api/text_generation_api.rb +77 -0
- data/lib/cloudmersive-image-recognition-api-client/api_client.rb +11 -9
- data/lib/cloudmersive-image-recognition-api-client/api_error.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/configuration.rb +2 -2
- data/lib/cloudmersive-image-recognition-api-client/models/age_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/color_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/create_handwriting_request.rb +216 -0
- data/lib/cloudmersive-image-recognition-api-client/models/detected_license_plate.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/detected_object.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/dominant_color_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/draw_polygon_instance.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/draw_polygon_request.rb +9 -13
- data/lib/cloudmersive-image-recognition-api-client/models/draw_rectangle_instance.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/draw_rectangle_request.rb +9 -13
- data/lib/cloudmersive-image-recognition-api-client/models/draw_text_instance.rb +8 -11
- data/lib/cloudmersive-image-recognition-api-client/models/draw_text_request.rb +9 -13
- data/lib/cloudmersive-image-recognition-api-client/models/face.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_compare_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_locate_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_locate_with_landmarks_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_match.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_point.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_with_landmarks.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/find_symbol_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/fine_text_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/fine_text_item.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/gender_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/image_description_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/image_metadata.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/image_metadata_exif_value.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/image_similarity_comparison_response.rb +206 -0
- data/lib/cloudmersive-image-recognition-api-client/models/image_similarity_hash_distance_request.rb +196 -0
- data/lib/cloudmersive-image-recognition-api-client/models/image_similarity_hash_distance_response.rb +196 -0
- data/lib/cloudmersive-image-recognition-api-client/models/image_similarity_hash_response.rb +196 -0
- data/lib/cloudmersive-image-recognition-api-client/models/nsfw_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/object_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/person_with_age.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/person_with_gender.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/polygon_point.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/recognition_outcome.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/text_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/text_item.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/vehicle_license_plate_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/version.rb +2 -2
- data/spec/api/artistic_api_spec.rb +2 -2
- data/spec/api/convert_api_spec.rb +8 -8
- data/spec/api/edit_api_spec.rb +47 -13
- data/spec/api/face_api_spec.rb +8 -8
- data/spec/api/filter_api_spec.rb +9 -9
- data/spec/api/info_api_spec.rb +3 -3
- data/spec/api/nsfw_api_spec.rb +2 -2
- data/spec/api/recognize_api_spec.rb +49 -10
- data/spec/api/resize_api_spec.rb +5 -5
- data/spec/api/text_generation_api_spec.rb +47 -0
- data/spec/api_client_spec.rb +52 -35
- data/spec/configuration_spec.rb +9 -9
- data/spec/models/age_detection_result_spec.rb +4 -5
- data/spec/models/color_result_spec.rb +4 -5
- data/spec/models/create_handwriting_request_spec.rb +59 -0
- data/spec/models/detected_license_plate_spec.rb +8 -9
- data/spec/models/detected_object_spec.rb +7 -8
- data/spec/models/dominant_color_result_spec.rb +3 -4
- data/spec/models/draw_polygon_instance_spec.rb +5 -6
- data/spec/models/draw_polygon_request_spec.rb +4 -5
- data/spec/models/draw_rectangle_instance_spec.rb +8 -9
- data/spec/models/draw_rectangle_request_spec.rb +4 -5
- data/spec/models/draw_text_instance_spec.rb +9 -10
- data/spec/models/draw_text_request_spec.rb +4 -5
- data/spec/models/face_compare_response_spec.rb +5 -6
- data/spec/models/face_locate_response_spec.rb +5 -6
- data/spec/models/face_locate_with_landmarks_response_spec.rb +5 -6
- data/spec/models/face_match_spec.rb +7 -8
- data/spec/models/face_point_spec.rb +3 -4
- data/spec/models/face_spec.rb +5 -6
- data/spec/models/face_with_landmarks_spec.rb +14 -15
- data/spec/models/find_symbol_result_spec.rb +7 -8
- data/spec/models/fine_text_detection_result_spec.rb +4 -5
- data/spec/models/fine_text_item_spec.rb +12 -13
- data/spec/models/gender_detection_result_spec.rb +4 -5
- data/spec/models/image_description_response_spec.rb +5 -6
- data/spec/models/image_metadata_exif_value_spec.rb +4 -5
- data/spec/models/image_metadata_spec.rb +11 -12
- data/spec/models/image_similarity_comparison_response_spec.rb +53 -0
- data/spec/models/image_similarity_hash_distance_request_spec.rb +47 -0
- data/spec/models/image_similarity_hash_distance_response_spec.rb +47 -0
- data/spec/models/image_similarity_hash_response_spec.rb +47 -0
- data/spec/models/nsfw_result_spec.rb +4 -5
- data/spec/models/object_detection_result_spec.rb +4 -5
- data/spec/models/person_with_age_spec.rb +5 -6
- data/spec/models/person_with_gender_spec.rb +4 -5
- data/spec/models/polygon_point_spec.rb +3 -4
- data/spec/models/recognition_outcome_spec.rb +3 -4
- data/spec/models/text_detection_result_spec.rb +4 -5
- data/spec/models/text_item_spec.rb +5 -6
- data/spec/models/vehicle_license_plate_detection_result_spec.rb +4 -5
- data/spec/spec_helper.rb +1 -1
- metadata +20 -2
@@ -6,11 +6,11 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
|
-
require
|
13
|
+
require 'uri'
|
14
14
|
|
15
15
|
module CloudmersiveImageRecognitionApiClient
|
16
16
|
class InfoApi
|
@@ -19,7 +19,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
|
23
22
|
# Returns the dominant colors of the image
|
24
23
|
# Uses advanced image processing to extract the top 5 dominant colors in the image, returned in the order of dominance with the most-dominant color first. These are the primary perceptual colors used in the image as perceived by a viewer.
|
25
24
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -27,7 +26,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
27
26
|
# @return [DominantColorResult]
|
28
27
|
def info_get_dominant_color(image_file, opts = {})
|
29
28
|
data, _status_code, _headers = info_get_dominant_color_with_http_info(image_file, opts)
|
30
|
-
|
29
|
+
data
|
31
30
|
end
|
32
31
|
|
33
32
|
# Returns the dominant colors of the image
|
@@ -37,14 +36,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
37
36
|
# @return [Array<(DominantColorResult, Fixnum, Hash)>] DominantColorResult data, response status code and response headers
|
38
37
|
def info_get_dominant_color_with_http_info(image_file, opts = {})
|
39
38
|
if @api_client.config.debugging
|
40
|
-
@api_client.config.logger.debug
|
39
|
+
@api_client.config.logger.debug 'Calling API: InfoApi.info_get_dominant_color ...'
|
41
40
|
end
|
42
41
|
# verify the required parameter 'image_file' is set
|
43
42
|
if @api_client.config.client_side_validation && image_file.nil?
|
44
43
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling InfoApi.info_get_dominant_color"
|
45
44
|
end
|
46
45
|
# resource path
|
47
|
-
local_var_path =
|
46
|
+
local_var_path = '/image/get-info/dominant-color'
|
48
47
|
|
49
48
|
# query parameters
|
50
49
|
query_params = {}
|
@@ -58,7 +57,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
58
57
|
|
59
58
|
# form parameters
|
60
59
|
form_params = {}
|
61
|
-
form_params[
|
60
|
+
form_params['imageFile'] = image_file
|
62
61
|
|
63
62
|
# http body (model)
|
64
63
|
post_body = nil
|
@@ -75,7 +74,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
75
74
|
end
|
76
75
|
return data, status_code, headers
|
77
76
|
end
|
78
|
-
|
79
77
|
# Returns the image metadata including EXIF and resolution
|
80
78
|
# Returns the metadata information on the image, including file type, EXIF (if available), and resolution.
|
81
79
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -83,7 +81,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
83
81
|
# @return [ImageMetadata]
|
84
82
|
def info_get_metadata(image_file, opts = {})
|
85
83
|
data, _status_code, _headers = info_get_metadata_with_http_info(image_file, opts)
|
86
|
-
|
84
|
+
data
|
87
85
|
end
|
88
86
|
|
89
87
|
# Returns the image metadata including EXIF and resolution
|
@@ -93,14 +91,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
93
91
|
# @return [Array<(ImageMetadata, Fixnum, Hash)>] ImageMetadata data, response status code and response headers
|
94
92
|
def info_get_metadata_with_http_info(image_file, opts = {})
|
95
93
|
if @api_client.config.debugging
|
96
|
-
@api_client.config.logger.debug
|
94
|
+
@api_client.config.logger.debug 'Calling API: InfoApi.info_get_metadata ...'
|
97
95
|
end
|
98
96
|
# verify the required parameter 'image_file' is set
|
99
97
|
if @api_client.config.client_side_validation && image_file.nil?
|
100
98
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling InfoApi.info_get_metadata"
|
101
99
|
end
|
102
100
|
# resource path
|
103
|
-
local_var_path =
|
101
|
+
local_var_path = '/image/get-info/metadata'
|
104
102
|
|
105
103
|
# query parameters
|
106
104
|
query_params = {}
|
@@ -114,7 +112,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
114
112
|
|
115
113
|
# form parameters
|
116
114
|
form_params = {}
|
117
|
-
form_params[
|
115
|
+
form_params['imageFile'] = image_file
|
118
116
|
|
119
117
|
# http body (model)
|
120
118
|
post_body = nil
|
@@ -6,11 +6,11 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
|
-
require
|
13
|
+
require 'uri'
|
14
14
|
|
15
15
|
module CloudmersiveImageRecognitionApiClient
|
16
16
|
class NsfwApi
|
@@ -19,7 +19,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
|
23
22
|
# Not safe for work NSFW racy content classification
|
24
23
|
# Classify an image into Not Safe For Work (NSFW)/Porn/Racy content and Safe Content.
|
25
24
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -27,7 +26,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
27
26
|
# @return [NsfwResult]
|
28
27
|
def nsfw_classify(image_file, opts = {})
|
29
28
|
data, _status_code, _headers = nsfw_classify_with_http_info(image_file, opts)
|
30
|
-
|
29
|
+
data
|
31
30
|
end
|
32
31
|
|
33
32
|
# Not safe for work NSFW racy content classification
|
@@ -37,14 +36,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
37
36
|
# @return [Array<(NsfwResult, Fixnum, Hash)>] NsfwResult data, response status code and response headers
|
38
37
|
def nsfw_classify_with_http_info(image_file, opts = {})
|
39
38
|
if @api_client.config.debugging
|
40
|
-
@api_client.config.logger.debug
|
39
|
+
@api_client.config.logger.debug 'Calling API: NsfwApi.nsfw_classify ...'
|
41
40
|
end
|
42
41
|
# verify the required parameter 'image_file' is set
|
43
42
|
if @api_client.config.client_side_validation && image_file.nil?
|
44
43
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling NsfwApi.nsfw_classify"
|
45
44
|
end
|
46
45
|
# resource path
|
47
|
-
local_var_path =
|
46
|
+
local_var_path = '/image/nsfw/classify'
|
48
47
|
|
49
48
|
# query parameters
|
50
49
|
query_params = {}
|
@@ -58,7 +57,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
58
57
|
|
59
58
|
# form parameters
|
60
59
|
form_params = {}
|
61
|
-
form_params[
|
60
|
+
form_params['imageFile'] = image_file
|
62
61
|
|
63
62
|
# http body (model)
|
64
63
|
post_body = nil
|
@@ -6,11 +6,11 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
|
-
require
|
13
|
+
require 'uri'
|
14
14
|
|
15
15
|
module CloudmersiveImageRecognitionApiClient
|
16
16
|
class RecognizeApi
|
@@ -19,7 +19,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
|
23
22
|
# Describe an image in natural language
|
24
23
|
# Generate an English language text description of the image as a sentence.
|
25
24
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -27,7 +26,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
27
26
|
# @return [ImageDescriptionResponse]
|
28
27
|
def recognize_describe(image_file, opts = {})
|
29
28
|
data, _status_code, _headers = recognize_describe_with_http_info(image_file, opts)
|
30
|
-
|
29
|
+
data
|
31
30
|
end
|
32
31
|
|
33
32
|
# Describe an image in natural language
|
@@ -37,14 +36,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
37
36
|
# @return [Array<(ImageDescriptionResponse, Fixnum, Hash)>] ImageDescriptionResponse data, response status code and response headers
|
38
37
|
def recognize_describe_with_http_info(image_file, opts = {})
|
39
38
|
if @api_client.config.debugging
|
40
|
-
@api_client.config.logger.debug
|
39
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_describe ...'
|
41
40
|
end
|
42
41
|
# verify the required parameter 'image_file' is set
|
43
42
|
if @api_client.config.client_side_validation && image_file.nil?
|
44
43
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_describe"
|
45
44
|
end
|
46
45
|
# resource path
|
47
|
-
local_var_path =
|
46
|
+
local_var_path = '/image/recognize/describe'
|
48
47
|
|
49
48
|
# query parameters
|
50
49
|
query_params = {}
|
@@ -58,7 +57,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
58
57
|
|
59
58
|
# form parameters
|
60
59
|
form_params = {}
|
61
|
-
form_params[
|
60
|
+
form_params['imageFile'] = image_file
|
62
61
|
|
63
62
|
# http body (model)
|
64
63
|
post_body = nil
|
@@ -75,7 +74,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
75
74
|
end
|
76
75
|
return data, status_code, headers
|
77
76
|
end
|
78
|
-
|
79
77
|
# Detect and unskew a photo of a document
|
80
78
|
# Detect and unskew a photo of a document (e.g. taken on a cell phone) into a perfectly square image. Great for document scanning applications; once unskewed, this image is perfect for converting to PDF using the Convert API or optical character recognition using the OCR API.
|
81
79
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -84,7 +82,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
84
82
|
# @return [String]
|
85
83
|
def recognize_detect_and_unskew_document(image_file, opts = {})
|
86
84
|
data, _status_code, _headers = recognize_detect_and_unskew_document_with_http_info(image_file, opts)
|
87
|
-
|
85
|
+
data
|
88
86
|
end
|
89
87
|
|
90
88
|
# Detect and unskew a photo of a document
|
@@ -95,14 +93,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
95
93
|
# @return [Array<(String, Fixnum, Hash)>] String data, response status code and response headers
|
96
94
|
def recognize_detect_and_unskew_document_with_http_info(image_file, opts = {})
|
97
95
|
if @api_client.config.debugging
|
98
|
-
@api_client.config.logger.debug
|
96
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_detect_and_unskew_document ...'
|
99
97
|
end
|
100
98
|
# verify the required parameter 'image_file' is set
|
101
99
|
if @api_client.config.client_side_validation && image_file.nil?
|
102
100
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_detect_and_unskew_document"
|
103
101
|
end
|
104
102
|
# resource path
|
105
|
-
local_var_path =
|
103
|
+
local_var_path = '/image/recognize/detect-document/unskew'
|
106
104
|
|
107
105
|
# query parameters
|
108
106
|
query_params = {}
|
@@ -117,7 +115,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
117
115
|
|
118
116
|
# form parameters
|
119
117
|
form_params = {}
|
120
|
-
form_params[
|
118
|
+
form_params['imageFile'] = image_file
|
121
119
|
|
122
120
|
# http body (model)
|
123
121
|
post_body = nil
|
@@ -134,7 +132,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
134
132
|
end
|
135
133
|
return data, status_code, headers
|
136
134
|
end
|
137
|
-
|
138
135
|
# Detect objects including types and locations in an image
|
139
136
|
# 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.
|
140
137
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -142,7 +139,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
142
139
|
# @return [ObjectDetectionResult]
|
143
140
|
def recognize_detect_objects(image_file, opts = {})
|
144
141
|
data, _status_code, _headers = recognize_detect_objects_with_http_info(image_file, opts)
|
145
|
-
|
142
|
+
data
|
146
143
|
end
|
147
144
|
|
148
145
|
# Detect objects including types and locations in an image
|
@@ -152,14 +149,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
152
149
|
# @return [Array<(ObjectDetectionResult, Fixnum, Hash)>] ObjectDetectionResult data, response status code and response headers
|
153
150
|
def recognize_detect_objects_with_http_info(image_file, opts = {})
|
154
151
|
if @api_client.config.debugging
|
155
|
-
@api_client.config.logger.debug
|
152
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_detect_objects ...'
|
156
153
|
end
|
157
154
|
# verify the required parameter 'image_file' is set
|
158
155
|
if @api_client.config.client_side_validation && image_file.nil?
|
159
156
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_detect_objects"
|
160
157
|
end
|
161
158
|
# resource path
|
162
|
-
local_var_path =
|
159
|
+
local_var_path = '/image/recognize/detect-objects'
|
163
160
|
|
164
161
|
# query parameters
|
165
162
|
query_params = {}
|
@@ -173,7 +170,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
173
170
|
|
174
171
|
# form parameters
|
175
172
|
form_params = {}
|
176
|
-
form_params[
|
173
|
+
form_params['imageFile'] = image_file
|
177
174
|
|
178
175
|
# http body (model)
|
179
176
|
post_body = nil
|
@@ -190,7 +187,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
190
187
|
end
|
191
188
|
return data, status_code, headers
|
192
189
|
end
|
193
|
-
|
194
190
|
# Detect people including locations in an image
|
195
191
|
# 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.
|
196
192
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -198,7 +194,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
198
194
|
# @return [ObjectDetectionResult]
|
199
195
|
def recognize_detect_people(image_file, opts = {})
|
200
196
|
data, _status_code, _headers = recognize_detect_people_with_http_info(image_file, opts)
|
201
|
-
|
197
|
+
data
|
202
198
|
end
|
203
199
|
|
204
200
|
# Detect people including locations in an image
|
@@ -208,14 +204,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
208
204
|
# @return [Array<(ObjectDetectionResult, Fixnum, Hash)>] ObjectDetectionResult data, response status code and response headers
|
209
205
|
def recognize_detect_people_with_http_info(image_file, opts = {})
|
210
206
|
if @api_client.config.debugging
|
211
|
-
@api_client.config.logger.debug
|
207
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_detect_people ...'
|
212
208
|
end
|
213
209
|
# verify the required parameter 'image_file' is set
|
214
210
|
if @api_client.config.client_side_validation && image_file.nil?
|
215
211
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_detect_people"
|
216
212
|
end
|
217
213
|
# resource path
|
218
|
-
local_var_path =
|
214
|
+
local_var_path = '/image/recognize/detect-people'
|
219
215
|
|
220
216
|
# query parameters
|
221
217
|
query_params = {}
|
@@ -229,7 +225,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
229
225
|
|
230
226
|
# form parameters
|
231
227
|
form_params = {}
|
232
|
-
form_params[
|
228
|
+
form_params['imageFile'] = image_file
|
233
229
|
|
234
230
|
# http body (model)
|
235
231
|
post_body = nil
|
@@ -246,7 +242,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
246
242
|
end
|
247
243
|
return data, status_code, headers
|
248
244
|
end
|
249
|
-
|
250
245
|
# Detect fine text in a photo of a document
|
251
246
|
# 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.
|
252
247
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -254,7 +249,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
254
249
|
# @return [FineTextDetectionResult]
|
255
250
|
def recognize_detect_text_fine(image_file, opts = {})
|
256
251
|
data, _status_code, _headers = recognize_detect_text_fine_with_http_info(image_file, opts)
|
257
|
-
|
252
|
+
data
|
258
253
|
end
|
259
254
|
|
260
255
|
# Detect fine text in a photo of a document
|
@@ -264,14 +259,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
264
259
|
# @return [Array<(FineTextDetectionResult, Fixnum, Hash)>] FineTextDetectionResult data, response status code and response headers
|
265
260
|
def recognize_detect_text_fine_with_http_info(image_file, opts = {})
|
266
261
|
if @api_client.config.debugging
|
267
|
-
@api_client.config.logger.debug
|
262
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_detect_text_fine ...'
|
268
263
|
end
|
269
264
|
# verify the required parameter 'image_file' is set
|
270
265
|
if @api_client.config.client_side_validation && image_file.nil?
|
271
266
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_detect_text_fine"
|
272
267
|
end
|
273
268
|
# resource path
|
274
|
-
local_var_path =
|
269
|
+
local_var_path = '/image/recognize/detect-text/fine'
|
275
270
|
|
276
271
|
# query parameters
|
277
272
|
query_params = {}
|
@@ -285,7 +280,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
285
280
|
|
286
281
|
# form parameters
|
287
282
|
form_params = {}
|
288
|
-
form_params[
|
283
|
+
form_params['imageFile'] = image_file
|
289
284
|
|
290
285
|
# http body (model)
|
291
286
|
post_body = nil
|
@@ -302,7 +297,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
302
297
|
end
|
303
298
|
return data, status_code, headers
|
304
299
|
end
|
305
|
-
|
306
300
|
# Detect large text in a photo
|
307
301
|
# Identify the position, and size of large text within a photograph. Identify the location of large text in a photo - such as signs, titles, etc. and other forms of large, low-density text. Not suitable for high-density text (e.g. scans of documents, receipts, etc.) for OCR purposes - for OCR, please see our Deep Learning OCR APIs.
|
308
302
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
@@ -310,7 +304,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
310
304
|
# @return [TextDetectionResult]
|
311
305
|
def recognize_detect_text_large(image_file, opts = {})
|
312
306
|
data, _status_code, _headers = recognize_detect_text_large_with_http_info(image_file, opts)
|
313
|
-
|
307
|
+
data
|
314
308
|
end
|
315
309
|
|
316
310
|
# Detect large text in a photo
|
@@ -320,14 +314,14 @@ module CloudmersiveImageRecognitionApiClient
|
|
320
314
|
# @return [Array<(TextDetectionResult, Fixnum, Hash)>] TextDetectionResult data, response status code and response headers
|
321
315
|
def recognize_detect_text_large_with_http_info(image_file, opts = {})
|
322
316
|
if @api_client.config.debugging
|
323
|
-
@api_client.config.logger.debug
|
317
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_detect_text_large ...'
|
324
318
|
end
|
325
319
|
# verify the required parameter 'image_file' is set
|
326
320
|
if @api_client.config.client_side_validation && image_file.nil?
|
327
321
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_detect_text_large"
|
328
322
|
end
|
329
323
|
# resource path
|
330
|
-
local_var_path =
|
324
|
+
local_var_path = '/image/recognize/detect-text/large'
|
331
325
|
|
332
326
|
# query parameters
|
333
327
|
query_params = {}
|
@@ -341,7 +335,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
341
335
|
|
342
336
|
# form parameters
|
343
337
|
form_params = {}
|
344
|
-
form_params[
|
338
|
+
form_params['imageFile'] = image_file
|
345
339
|
|
346
340
|
# http body (model)
|
347
341
|
post_body = nil
|
@@ -358,32 +352,31 @@ module CloudmersiveImageRecognitionApiClient
|
|
358
352
|
end
|
359
353
|
return data, status_code, headers
|
360
354
|
end
|
361
|
-
|
362
355
|
# Detect vehicle license plates in an image
|
363
|
-
# Identify the position, and size, and content of vehicle license plates in an image. License plates should be within 15-20 degrees on-axis to the camera.
|
356
|
+
# Identify the position, and size, and content of vehicle license plates in an image. License plates should be within 15-20 degrees on-axis to the camera. Supported image formats are JPG, PNG and BMP.
|
364
357
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
365
358
|
# @param [Hash] opts the optional parameters
|
366
359
|
# @return [VehicleLicensePlateDetectionResult]
|
367
360
|
def recognize_detect_vehicle_license_plates(image_file, opts = {})
|
368
361
|
data, _status_code, _headers = recognize_detect_vehicle_license_plates_with_http_info(image_file, opts)
|
369
|
-
|
362
|
+
data
|
370
363
|
end
|
371
364
|
|
372
365
|
# Detect vehicle license plates in an image
|
373
|
-
# Identify the position, and size, and content of vehicle license plates in an image. License plates should be within 15-20 degrees on-axis to the camera.
|
366
|
+
# Identify the position, and size, and content of vehicle license plates in an image. License plates should be within 15-20 degrees on-axis to the camera. Supported image formats are JPG, PNG and BMP.
|
374
367
|
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
375
368
|
# @param [Hash] opts the optional parameters
|
376
369
|
# @return [Array<(VehicleLicensePlateDetectionResult, Fixnum, Hash)>] VehicleLicensePlateDetectionResult data, response status code and response headers
|
377
370
|
def recognize_detect_vehicle_license_plates_with_http_info(image_file, opts = {})
|
378
371
|
if @api_client.config.debugging
|
379
|
-
@api_client.config.logger.debug
|
372
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_detect_vehicle_license_plates ...'
|
380
373
|
end
|
381
374
|
# verify the required parameter 'image_file' is set
|
382
375
|
if @api_client.config.client_side_validation && image_file.nil?
|
383
376
|
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_detect_vehicle_license_plates"
|
384
377
|
end
|
385
378
|
# resource path
|
386
|
-
local_var_path =
|
379
|
+
local_var_path = '/image/recognize/detect-vehicle-license-plates'
|
387
380
|
|
388
381
|
# query parameters
|
389
382
|
query_params = {}
|
@@ -397,7 +390,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
397
390
|
|
398
391
|
# form parameters
|
399
392
|
form_params = {}
|
400
|
-
form_params[
|
393
|
+
form_params['imageFile'] = image_file
|
401
394
|
|
402
395
|
# http body (model)
|
403
396
|
post_body = nil
|
@@ -414,7 +407,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
414
407
|
end
|
415
408
|
return data, status_code, headers
|
416
409
|
end
|
417
|
-
|
418
410
|
# Find the location of a symbol in an image
|
419
411
|
# Determine if an image contains a symbol, and if so, the location of that symbol in the image.
|
420
412
|
# @param input_image Image file to search through for the target image.
|
@@ -423,7 +415,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
423
415
|
# @return [FindSymbolResult]
|
424
416
|
def recognize_find_symbol(input_image, target_image, opts = {})
|
425
417
|
data, _status_code, _headers = recognize_find_symbol_with_http_info(input_image, target_image, opts)
|
426
|
-
|
418
|
+
data
|
427
419
|
end
|
428
420
|
|
429
421
|
# Find the location of a symbol in an image
|
@@ -434,7 +426,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
434
426
|
# @return [Array<(FindSymbolResult, Fixnum, Hash)>] FindSymbolResult data, response status code and response headers
|
435
427
|
def recognize_find_symbol_with_http_info(input_image, target_image, opts = {})
|
436
428
|
if @api_client.config.debugging
|
437
|
-
@api_client.config.logger.debug
|
429
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_find_symbol ...'
|
438
430
|
end
|
439
431
|
# verify the required parameter 'input_image' is set
|
440
432
|
if @api_client.config.client_side_validation && input_image.nil?
|
@@ -445,7 +437,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
445
437
|
fail ArgumentError, "Missing the required parameter 'target_image' when calling RecognizeApi.recognize_find_symbol"
|
446
438
|
end
|
447
439
|
# resource path
|
448
|
-
local_var_path =
|
440
|
+
local_var_path = '/image/recognize/find/symbol'
|
449
441
|
|
450
442
|
# query parameters
|
451
443
|
query_params = {}
|
@@ -459,8 +451,8 @@ module CloudmersiveImageRecognitionApiClient
|
|
459
451
|
|
460
452
|
# form parameters
|
461
453
|
form_params = {}
|
462
|
-
form_params[
|
463
|
-
form_params[
|
454
|
+
form_params['inputImage'] = input_image
|
455
|
+
form_params['targetImage'] = target_image
|
464
456
|
|
465
457
|
# http body (model)
|
466
458
|
post_body = nil
|
@@ -477,5 +469,182 @@ module CloudmersiveImageRecognitionApiClient
|
|
477
469
|
end
|
478
470
|
return data, status_code, headers
|
479
471
|
end
|
472
|
+
# Compare two images for similarity
|
473
|
+
# Generates an image similarity score using Deep Learning between 0.0 and 1.0, values closer to 1.0 indicate greater similarity
|
474
|
+
# @param base_image Image file to compare against. Common file formats such as PNG, JPEG are supported.
|
475
|
+
# @param comparison_image Image to compare to the base image.
|
476
|
+
# @param [Hash] opts the optional parameters
|
477
|
+
# @option opts [String] :recognition_mode Optional, specify the recognition mode; possible values are Normal, Basic and Advanced. Default is Normal.
|
478
|
+
# @return [String]
|
479
|
+
def recognize_similarity_compare(base_image, comparison_image, opts = {})
|
480
|
+
data, _status_code, _headers = recognize_similarity_compare_with_http_info(base_image, comparison_image, opts)
|
481
|
+
data
|
482
|
+
end
|
483
|
+
|
484
|
+
# Compare two images for similarity
|
485
|
+
# Generates an image similarity score using Deep Learning between 0.0 and 1.0, values closer to 1.0 indicate greater similarity
|
486
|
+
# @param base_image Image file to compare against. Common file formats such as PNG, JPEG are supported.
|
487
|
+
# @param comparison_image Image to compare to the base image.
|
488
|
+
# @param [Hash] opts the optional parameters
|
489
|
+
# @option opts [String] :recognition_mode Optional, specify the recognition mode; possible values are Normal, Basic and Advanced. Default is Normal.
|
490
|
+
# @return [Array<(String, Fixnum, Hash)>] String data, response status code and response headers
|
491
|
+
def recognize_similarity_compare_with_http_info(base_image, comparison_image, opts = {})
|
492
|
+
if @api_client.config.debugging
|
493
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_similarity_compare ...'
|
494
|
+
end
|
495
|
+
# verify the required parameter 'base_image' is set
|
496
|
+
if @api_client.config.client_side_validation && base_image.nil?
|
497
|
+
fail ArgumentError, "Missing the required parameter 'base_image' when calling RecognizeApi.recognize_similarity_compare"
|
498
|
+
end
|
499
|
+
# verify the required parameter 'comparison_image' is set
|
500
|
+
if @api_client.config.client_side_validation && comparison_image.nil?
|
501
|
+
fail ArgumentError, "Missing the required parameter 'comparison_image' when calling RecognizeApi.recognize_similarity_compare"
|
502
|
+
end
|
503
|
+
# resource path
|
504
|
+
local_var_path = '/image/recognize/similarity/compare'
|
505
|
+
|
506
|
+
# query parameters
|
507
|
+
query_params = {}
|
508
|
+
|
509
|
+
# header parameters
|
510
|
+
header_params = {}
|
511
|
+
# HTTP header 'Accept' (if needed)
|
512
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'text/json', 'application/xml', 'text/xml'])
|
513
|
+
# HTTP header 'Content-Type'
|
514
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
|
515
|
+
header_params[:'recognitionMode'] = opts[:'recognition_mode'] if !opts[:'recognition_mode'].nil?
|
516
|
+
|
517
|
+
# form parameters
|
518
|
+
form_params = {}
|
519
|
+
form_params['baseImage'] = base_image
|
520
|
+
form_params['comparisonImage'] = comparison_image
|
521
|
+
|
522
|
+
# http body (model)
|
523
|
+
post_body = nil
|
524
|
+
auth_names = ['Apikey']
|
525
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
526
|
+
:header_params => header_params,
|
527
|
+
:query_params => query_params,
|
528
|
+
:form_params => form_params,
|
529
|
+
:body => post_body,
|
530
|
+
:auth_names => auth_names,
|
531
|
+
:return_type => 'String')
|
532
|
+
if @api_client.config.debugging
|
533
|
+
@api_client.config.logger.debug "API called: RecognizeApi#recognize_similarity_compare\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
534
|
+
end
|
535
|
+
return data, status_code, headers
|
536
|
+
end
|
537
|
+
# Generate a perceptual image hash
|
538
|
+
# Generates a hash value for the image; hash values that are closer together in terms of Hamming Distance are more similar.
|
539
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
540
|
+
# @param [Hash] opts the optional parameters
|
541
|
+
# @option opts [String] :recognition_mode Optional, specify the recognition mode; possible values are Normal, Basic and Advanced. Default is Normal.
|
542
|
+
# @return [ImageSimilarityHashResponse]
|
543
|
+
def recognize_similarity_hash(image_file, opts = {})
|
544
|
+
data, _status_code, _headers = recognize_similarity_hash_with_http_info(image_file, opts)
|
545
|
+
data
|
546
|
+
end
|
547
|
+
|
548
|
+
# Generate a perceptual image hash
|
549
|
+
# Generates a hash value for the image; hash values that are closer together in terms of Hamming Distance are more similar.
|
550
|
+
# @param image_file Image file to perform the operation on. Common file formats such as PNG, JPEG are supported.
|
551
|
+
# @param [Hash] opts the optional parameters
|
552
|
+
# @option opts [String] :recognition_mode Optional, specify the recognition mode; possible values are Normal, Basic and Advanced. Default is Normal.
|
553
|
+
# @return [Array<(ImageSimilarityHashResponse, Fixnum, Hash)>] ImageSimilarityHashResponse data, response status code and response headers
|
554
|
+
def recognize_similarity_hash_with_http_info(image_file, opts = {})
|
555
|
+
if @api_client.config.debugging
|
556
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_similarity_hash ...'
|
557
|
+
end
|
558
|
+
# verify the required parameter 'image_file' is set
|
559
|
+
if @api_client.config.client_side_validation && image_file.nil?
|
560
|
+
fail ArgumentError, "Missing the required parameter 'image_file' when calling RecognizeApi.recognize_similarity_hash"
|
561
|
+
end
|
562
|
+
# resource path
|
563
|
+
local_var_path = '/image/recognize/similarity/hash'
|
564
|
+
|
565
|
+
# query parameters
|
566
|
+
query_params = {}
|
567
|
+
|
568
|
+
# header parameters
|
569
|
+
header_params = {}
|
570
|
+
# HTTP header 'Accept' (if needed)
|
571
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'text/json', 'application/xml', 'text/xml'])
|
572
|
+
# HTTP header 'Content-Type'
|
573
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
|
574
|
+
header_params[:'recognitionMode'] = opts[:'recognition_mode'] if !opts[:'recognition_mode'].nil?
|
575
|
+
|
576
|
+
# form parameters
|
577
|
+
form_params = {}
|
578
|
+
form_params['imageFile'] = image_file
|
579
|
+
|
580
|
+
# http body (model)
|
581
|
+
post_body = nil
|
582
|
+
auth_names = ['Apikey']
|
583
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
584
|
+
:header_params => header_params,
|
585
|
+
:query_params => query_params,
|
586
|
+
:form_params => form_params,
|
587
|
+
:body => post_body,
|
588
|
+
:auth_names => auth_names,
|
589
|
+
:return_type => 'ImageSimilarityHashResponse')
|
590
|
+
if @api_client.config.debugging
|
591
|
+
@api_client.config.logger.debug "API called: RecognizeApi#recognize_similarity_hash\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
592
|
+
end
|
593
|
+
return data, status_code, headers
|
594
|
+
end
|
595
|
+
# Calculates the similarity between two perceptual image hashes
|
596
|
+
# Calculates the similarity between two perceptual image hashes by computing the Hamming Distance between them.
|
597
|
+
# @param request
|
598
|
+
# @param [Hash] opts the optional parameters
|
599
|
+
# @return [ImageSimilarityHashDistanceResponse]
|
600
|
+
def recognize_similarity_hash_distance(request, opts = {})
|
601
|
+
data, _status_code, _headers = recognize_similarity_hash_distance_with_http_info(request, opts)
|
602
|
+
data
|
603
|
+
end
|
604
|
+
|
605
|
+
# Calculates the similarity between two perceptual image hashes
|
606
|
+
# Calculates the similarity between two perceptual image hashes by computing the Hamming Distance between them.
|
607
|
+
# @param request
|
608
|
+
# @param [Hash] opts the optional parameters
|
609
|
+
# @return [Array<(ImageSimilarityHashDistanceResponse, Fixnum, Hash)>] ImageSimilarityHashDistanceResponse data, response status code and response headers
|
610
|
+
def recognize_similarity_hash_distance_with_http_info(request, opts = {})
|
611
|
+
if @api_client.config.debugging
|
612
|
+
@api_client.config.logger.debug 'Calling API: RecognizeApi.recognize_similarity_hash_distance ...'
|
613
|
+
end
|
614
|
+
# verify the required parameter 'request' is set
|
615
|
+
if @api_client.config.client_side_validation && request.nil?
|
616
|
+
fail ArgumentError, "Missing the required parameter 'request' when calling RecognizeApi.recognize_similarity_hash_distance"
|
617
|
+
end
|
618
|
+
# resource path
|
619
|
+
local_var_path = '/image/recognize/similarity/hash/distance'
|
620
|
+
|
621
|
+
# query parameters
|
622
|
+
query_params = {}
|
623
|
+
|
624
|
+
# header parameters
|
625
|
+
header_params = {}
|
626
|
+
# HTTP header 'Accept' (if needed)
|
627
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'text/json', 'application/xml', 'text/xml'])
|
628
|
+
# HTTP header 'Content-Type'
|
629
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'text/json', 'application/xml', 'text/xml', 'application/x-www-form-urlencoded'])
|
630
|
+
|
631
|
+
# form parameters
|
632
|
+
form_params = {}
|
633
|
+
|
634
|
+
# http body (model)
|
635
|
+
post_body = @api_client.object_to_http_body(request)
|
636
|
+
auth_names = ['Apikey']
|
637
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
638
|
+
:header_params => header_params,
|
639
|
+
:query_params => query_params,
|
640
|
+
:form_params => form_params,
|
641
|
+
:body => post_body,
|
642
|
+
:auth_names => auth_names,
|
643
|
+
:return_type => 'ImageSimilarityHashDistanceResponse')
|
644
|
+
if @api_client.config.debugging
|
645
|
+
@api_client.config.logger.debug "API called: RecognizeApi#recognize_similarity_hash_distance\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
646
|
+
end
|
647
|
+
return data, status_code, headers
|
648
|
+
end
|
480
649
|
end
|
481
650
|
end
|