tencentcloud-sdk-tiia 1.0.328 → 1.0.329
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/VERSION +1 -1
- data/lib/v20190529/client.rb +27 -0
- data/lib/v20190529/models.rb +56 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: acdb03ec3d878216213e009c892cf8a7fa0d1c37
|
4
|
+
data.tar.gz: 55474d55e4c89997eeb71d4240b829fc5b52cee5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8ef5075e1860eeda2fd38702b1c3553d83bb96bd18275d32841685a900224544532805fa501e2793720025b5dabb02a617d4557746fce5b04f7f6412817b08f0
|
7
|
+
data.tar.gz: 4646fdb5112ade27cceae2f1f41f94888ddd6f8ce4309304ceac88e23d540ad6d762f09c4f7857e165c70cdabb00a894f4bf2fb7fbb5f67681a882d159656793
|
data/lib/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.329
|
data/lib/v20190529/client.rb
CHANGED
@@ -336,6 +336,33 @@ module TencentCloud
|
|
336
336
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
337
337
|
end
|
338
338
|
|
339
|
+
# 通用图像标签可识别数千种常见物体或场景,覆盖日常物品、场景、动物、植物、食物、饮品、交通工具等多个大类,返回主体的标签名称和所属细分类目等,广泛应用于拍照识物、场景分析、图像内容审核与推荐、智能相册分类等场景。
|
340
|
+
|
341
|
+
# >
|
342
|
+
# - 通用图像标签在原图像标签接口的基础上进行了升级,识别精度和标签覆盖范围相比原图像标签接口更优,推荐使用。
|
343
|
+
|
344
|
+
# @param request: Request instance for DetectLabelPro.
|
345
|
+
# @type request: :class:`Tencentcloud::tiia::V20190529::DetectLabelProRequest`
|
346
|
+
# @rtype: :class:`Tencentcloud::tiia::V20190529::DetectLabelProResponse`
|
347
|
+
def DetectLabelPro(request)
|
348
|
+
body = send_request('DetectLabelPro', request.serialize)
|
349
|
+
response = JSON.parse(body)
|
350
|
+
if response['Response'].key?('Error') == false
|
351
|
+
model = DetectLabelProResponse.new
|
352
|
+
model.deserialize(response['Response'])
|
353
|
+
model
|
354
|
+
else
|
355
|
+
code = response['Response']['Error']['Code']
|
356
|
+
message = response['Response']['Error']['Message']
|
357
|
+
reqid = response['Response']['RequestId']
|
358
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
359
|
+
end
|
360
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
361
|
+
raise e
|
362
|
+
rescue StandardError => e
|
363
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
364
|
+
end
|
365
|
+
|
339
366
|
# 可以识别输入的图片中是否包含不良行为,例如打架斗殴、赌博、抽烟等,可以应用于广告图、直播截图、短视频截图等审核,减少不良行为对平台内容质量的影响,维护健康向上的互联网环境。
|
340
367
|
# >
|
341
368
|
# - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
|
data/lib/v20190529/models.rb
CHANGED
@@ -950,6 +950,62 @@ module TencentCloud
|
|
950
950
|
end
|
951
951
|
end
|
952
952
|
|
953
|
+
# DetectLabelPro请求参数结构体
|
954
|
+
class DetectLabelProRequest < TencentCloud::Common::AbstractModel
|
955
|
+
# @param ImageUrl: 图片URL地址。
|
956
|
+
# 图片限制:
|
957
|
+
# • 图片格式:PNG、JPG、JPEG、BMP。
|
958
|
+
# • 图片大小:所下载图片经Base64编码后不超过4M。图片下载时间不超过3秒。
|
959
|
+
# 建议:
|
960
|
+
# • 图片像素:大于50*50像素,否则影响识别效果;
|
961
|
+
# • 长宽比:长边:短边<5;
|
962
|
+
# 接口响应时间会受到图片下载时间的影响,建议使用更可靠的存储服务,推荐将图片存储在腾讯云COS。
|
963
|
+
# @type ImageUrl: String
|
964
|
+
# @param ImageBase64: 图片经过base64编码的内容。最大不超过4M。与ImageUrl同时存在时优先使用ImageUrl字段。
|
965
|
+
# **注意:图片需要base64编码,并且要去掉编码头部。**
|
966
|
+
# @type ImageBase64: String
|
967
|
+
|
968
|
+
attr_accessor :ImageUrl, :ImageBase64
|
969
|
+
|
970
|
+
def initialize(imageurl=nil, imagebase64=nil)
|
971
|
+
@ImageUrl = imageurl
|
972
|
+
@ImageBase64 = imagebase64
|
973
|
+
end
|
974
|
+
|
975
|
+
def deserialize(params)
|
976
|
+
@ImageUrl = params['ImageUrl']
|
977
|
+
@ImageBase64 = params['ImageBase64']
|
978
|
+
end
|
979
|
+
end
|
980
|
+
|
981
|
+
# DetectLabelPro返回参数结构体
|
982
|
+
class DetectLabelProResponse < TencentCloud::Common::AbstractModel
|
983
|
+
# @param Labels: 返回标签数组。
|
984
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
985
|
+
# @type Labels: Array
|
986
|
+
# @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
987
|
+
# @type RequestId: String
|
988
|
+
|
989
|
+
attr_accessor :Labels, :RequestId
|
990
|
+
|
991
|
+
def initialize(labels=nil, requestid=nil)
|
992
|
+
@Labels = labels
|
993
|
+
@RequestId = requestid
|
994
|
+
end
|
995
|
+
|
996
|
+
def deserialize(params)
|
997
|
+
unless params['Labels'].nil?
|
998
|
+
@Labels = []
|
999
|
+
params['Labels'].each do |i|
|
1000
|
+
detectlabelitem_tmp = DetectLabelItem.new
|
1001
|
+
detectlabelitem_tmp.deserialize(i)
|
1002
|
+
@Labels << detectlabelitem_tmp
|
1003
|
+
end
|
1004
|
+
end
|
1005
|
+
@RequestId = params['RequestId']
|
1006
|
+
end
|
1007
|
+
end
|
1008
|
+
|
953
1009
|
# DetectLabel请求参数结构体
|
954
1010
|
class DetectLabelRequest < TencentCloud::Common::AbstractModel
|
955
1011
|
# @param ImageUrl: 图片URL地址。
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tencentcloud-sdk-tiia
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.329
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tencent Cloud
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-06-
|
11
|
+
date: 2022-06-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: tencentcloud-sdk-common
|