tencentcloud-sdk-tiia 3.0.455 → 3.0.456
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/lib/VERSION +1 -1
- data/lib/v20190529/client.rb +72 -0
- data/lib/v20190529/models.rb +203 -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: b53e403abe7a76332ed49ee124eac79c21a1b3d9
|
4
|
+
data.tar.gz: 89b2ad03a4ec4e87256f42f9f1387d3006f163b0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d4f980a2692bcb3374c285e6bf140a99426b476e335e21c7b81304c07377ed93fed7cc718c3a0d8170d43367e875f6227ff25e9f80cbc25156a2574a224f546c
|
7
|
+
data.tar.gz: 1d26ef30e005671ddeb00fc30d050a192eda66484e058d7529d8b4abf6a09d51d9c6f0853ffa5239c411f406dee779a9768463a9aafe55a44dfb6ce16f767dc4
|
data/lib/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.0.
|
1
|
+
3.0.456
|
data/lib/v20190529/client.rb
CHANGED
@@ -211,6 +211,41 @@ module TencentCloud
|
|
211
211
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
212
212
|
end
|
213
213
|
|
214
|
+
# 可对图片中厨师穿戴进行识别,支持厨师服识别,厨师帽识别,赤膊识别和口罩识别,可应用于明厨亮灶场景。
|
215
|
+
# "被优选过滤"标签值在人体优选开关开启时才会返回。
|
216
|
+
# 厨师服:厨师服定义为白色上衣
|
217
|
+
# 厨师服识别(酒店版):厨师服定义为红色,白色,黑色上衣
|
218
|
+
|
219
|
+
# |序号 | 标签名称 | 标签值 |
|
220
|
+
# | :-----| :---------- |:----------------- |
|
221
|
+
# | 1 | 厨师服识别<div style="width: 70pt"> |无厨师服、有厨师服、被优选过滤|
|
222
|
+
# | 2 | 厨师服识别(酒店版)<div style="width: 70pt"> |无厨师服、有厨师服、被优选过滤|
|
223
|
+
# | 3 | 厨师帽识别<div style="width: 70pt"> |无厨师帽、有厨师帽、被优选过滤 |
|
224
|
+
# | 4 | 赤膊识别<div style="width: 70pt"> |非赤膊、赤膊、被优选过滤|
|
225
|
+
# | 5 | 口罩识别<div style="width: 70pt"> |无口罩、有口罩、口罩不确定、被优选过滤 |
|
226
|
+
|
227
|
+
# @param request: Request instance for DetectChefDress.
|
228
|
+
# @type request: :class:`Tencentcloud::tiia::V20190529::DetectChefDressRequest`
|
229
|
+
# @rtype: :class:`Tencentcloud::tiia::V20190529::DetectChefDressResponse`
|
230
|
+
def DetectChefDress(request)
|
231
|
+
body = send_request('DetectChefDress', request.serialize)
|
232
|
+
response = JSON.parse(body)
|
233
|
+
if response['Response'].key?('Error') == false
|
234
|
+
model = DetectChefDressResponse.new
|
235
|
+
model.deserialize(response['Response'])
|
236
|
+
model
|
237
|
+
else
|
238
|
+
code = response['Response']['Error']['Code']
|
239
|
+
message = response['Response']['Error']['Message']
|
240
|
+
reqid = response['Response']['RequestId']
|
241
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
242
|
+
end
|
243
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
244
|
+
raise e
|
245
|
+
rescue StandardError => e
|
246
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
247
|
+
end
|
248
|
+
|
214
249
|
# 输入一张图片,返回AI针对一张图片是否是恶心的一系列判断值。
|
215
250
|
|
216
251
|
# 通过恶心图片识别, 可以判断一张图片是否令人恶心, 同时给出它属于的潜在类别, 让您能够过滤掉使人不愉快的图片。
|
@@ -473,6 +508,43 @@ module TencentCloud
|
|
473
508
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
474
509
|
end
|
475
510
|
|
511
|
+
# 识别常安全属性识别可对图片中人体安全防护属性进行识别,支持识别安全帽,反光衣,护目镜,工服,手套,工地安全带,口罩,抽烟,玩手机等多种属性。
|
512
|
+
# "被优选过滤"标签值在人体优选开关开启时才会返回。
|
513
|
+
|
514
|
+
# |序号 | 标签名称 | 标签值 |
|
515
|
+
# | :-----| :---------- |:----------------- |
|
516
|
+
# | 1 | 安全帽识别<div style="width: 70pt"> |无安全帽、有安全帽、被优选过滤|
|
517
|
+
# | 2 | 玩手机识别<div style="width: 70pt"> |没有电话、打电话、玩手机、被优选过滤|
|
518
|
+
# | 3 | 抽烟识别<div style="width: 70pt"> |没有抽烟、抽烟、被优选过滤 |
|
519
|
+
# | 4 | 口罩识别<div style="width: 70pt"> |无口罩、有口罩、口罩不确定、被优选过滤|
|
520
|
+
# | 5 | 工地安全带识别<div style="width: 70pt"> |无工地安全带、工地安全带、被优选过滤 |
|
521
|
+
# | 6 | 手套识别<div style="width: 70pt"> |无手套、有手套、手套不确定、被优选过滤 |
|
522
|
+
# | 7 | 工服识别<div style="width: 70pt"> |无工服、有工服、被优选过滤|
|
523
|
+
# | 8 | 护目镜识别<div style="width: 70pt"> |无护目镜、有护目镜、被优选过滤|
|
524
|
+
# | 9 | 反光衣识别<div style="width: 70pt"> |无反光衣、有反光衣、被优选过滤|
|
525
|
+
|
526
|
+
# @param request: Request instance for DetectSecurity.
|
527
|
+
# @type request: :class:`Tencentcloud::tiia::V20190529::DetectSecurityRequest`
|
528
|
+
# @rtype: :class:`Tencentcloud::tiia::V20190529::DetectSecurityResponse`
|
529
|
+
def DetectSecurity(request)
|
530
|
+
body = send_request('DetectSecurity', request.serialize)
|
531
|
+
response = JSON.parse(body)
|
532
|
+
if response['Response'].key?('Error') == false
|
533
|
+
model = DetectSecurityResponse.new
|
534
|
+
model.deserialize(response['Response'])
|
535
|
+
model
|
536
|
+
else
|
537
|
+
code = response['Response']['Error']['Code']
|
538
|
+
message = response['Response']['Error']['Message']
|
539
|
+
reqid = response['Response']['RequestId']
|
540
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
541
|
+
end
|
542
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
543
|
+
raise e
|
544
|
+
rescue StandardError => e
|
545
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
546
|
+
end
|
547
|
+
|
476
548
|
# 传入一张图片,输出清晰度提升后的图片。
|
477
549
|
|
478
550
|
# 可以消除图片有损压缩导致的噪声,和使用滤镜、拍摄失焦导致的模糊。让图片的边缘和细节更加清晰自然。
|
data/lib/v20190529/models.rb
CHANGED
@@ -109,6 +109,70 @@ module TencentCloud
|
|
109
109
|
end
|
110
110
|
end
|
111
111
|
|
112
|
+
# 属性检测到的人体
|
113
|
+
class AttributesForBody < TencentCloud::Common::AbstractModel
|
114
|
+
# @param Rect: 人体框。当不开启人体检测时,内部参数默认为0。
|
115
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
116
|
+
# @type Rect: :class:`Tencentcloud::Tiia.v20190529.models.ImageRect`
|
117
|
+
# @param DetectConfidence: 人体检测置信度。取值0-1之间,当不开启人体检测开关时默认为0。
|
118
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
119
|
+
# @type DetectConfidence: Float
|
120
|
+
# @param Attributes: 属性信息。
|
121
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
122
|
+
# @type Attributes: Array
|
123
|
+
|
124
|
+
attr_accessor :Rect, :DetectConfidence, :Attributes
|
125
|
+
|
126
|
+
def initialize(rect=nil, detectconfidence=nil, attributes=nil)
|
127
|
+
@Rect = rect
|
128
|
+
@DetectConfidence = detectconfidence
|
129
|
+
@Attributes = attributes
|
130
|
+
end
|
131
|
+
|
132
|
+
def deserialize(params)
|
133
|
+
unless params['Rect'].nil?
|
134
|
+
@Rect = ImageRect.new
|
135
|
+
@Rect.deserialize(params['Rect'])
|
136
|
+
end
|
137
|
+
@DetectConfidence = params['DetectConfidence']
|
138
|
+
unless params['Attributes'].nil?
|
139
|
+
@Attributes = []
|
140
|
+
params['Attributes'].each do |i|
|
141
|
+
bodyattributes_tmp = BodyAttributes.new
|
142
|
+
bodyattributes_tmp.deserialize(i)
|
143
|
+
@Attributes << bodyattributes_tmp
|
144
|
+
end
|
145
|
+
end
|
146
|
+
end
|
147
|
+
end
|
148
|
+
|
149
|
+
# 属性列表。
|
150
|
+
class BodyAttributes < TencentCloud::Common::AbstractModel
|
151
|
+
# @param Label: 属性值。
|
152
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
153
|
+
# @type Label: String
|
154
|
+
# @param Confidence: 置信度,取值0-1之间。
|
155
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
156
|
+
# @type Confidence: Float
|
157
|
+
# @param Name: 属性名称。
|
158
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
159
|
+
# @type Name: String
|
160
|
+
|
161
|
+
attr_accessor :Label, :Confidence, :Name
|
162
|
+
|
163
|
+
def initialize(label=nil, confidence=nil, name=nil)
|
164
|
+
@Label = label
|
165
|
+
@Confidence = confidence
|
166
|
+
@Name = name
|
167
|
+
end
|
168
|
+
|
169
|
+
def deserialize(params)
|
170
|
+
@Label = params['Label']
|
171
|
+
@Confidence = params['Confidence']
|
172
|
+
@Name = params['Name']
|
173
|
+
end
|
174
|
+
end
|
175
|
+
|
112
176
|
# 图像主体区域。
|
113
177
|
class Box < TencentCloud::Common::AbstractModel
|
114
178
|
# @param Rect: 图像主体区域。
|
@@ -723,6 +787,75 @@ module TencentCloud
|
|
723
787
|
end
|
724
788
|
end
|
725
789
|
|
790
|
+
# DetectChefDress请求参数结构体
|
791
|
+
class DetectChefDressRequest < TencentCloud::Common::AbstractModel
|
792
|
+
# @param ImageUrl: 图片的 Url 。
|
793
|
+
# ImageUrl和ImageBase64必须提供一个,同时存在时优先使用ImageUrl字段。
|
794
|
+
# 图片限制:
|
795
|
+
# • 图片格式:支持PNG、JPG、JPEG、不支持 GIF 图片。
|
796
|
+
# • 图片大小:对应图片 base64 编码后大小不可超过5M。图片分辨率不超过 3840 x 2160pixel。
|
797
|
+
# 建议:
|
798
|
+
# • 接口响应时间会受到图片下载时间的影响,建议使用更可靠的存储服务,推荐将图片存储在腾讯云COS。
|
799
|
+
# @type ImageUrl: String
|
800
|
+
# @param ImageBase64: 图片经过base64编码的内容。与ImageUrl同时存在时优先使用ImageUrl字段。
|
801
|
+
# 注意:图片需要base64编码,并且要去掉编码头部。
|
802
|
+
# 支持的图片格式:PNG、JPG、JPEG、暂不支持GIF格式。
|
803
|
+
# 支持的图片大小:所下载图片经Base64编码后不超过5M。
|
804
|
+
# @type ImageBase64: String
|
805
|
+
# @param EnableDetect: 人体检测模型开关,“true”为开启,“false”为关闭
|
806
|
+
# 默认为开启,开启后可先对图片中的人体进行检测之后再进行属性识别
|
807
|
+
# @type EnableDetect: Boolean
|
808
|
+
# @param EnablePreferred: 人体优选开关,“true”为开启,“false”为关闭
|
809
|
+
# 开启后自动对检测质量低的人体进行优选过滤,有助于提高属性识别的准确率。
|
810
|
+
# 默认为开启,仅在人体检测开关开启时可配置,人体检测模型关闭时人体优选也关闭
|
811
|
+
# 人体优选开启时,检测到的人体分辨率不超过1920*1080 pixel
|
812
|
+
# @type EnablePreferred: Boolean
|
813
|
+
|
814
|
+
attr_accessor :ImageUrl, :ImageBase64, :EnableDetect, :EnablePreferred
|
815
|
+
|
816
|
+
def initialize(imageurl=nil, imagebase64=nil, enabledetect=nil, enablepreferred=nil)
|
817
|
+
@ImageUrl = imageurl
|
818
|
+
@ImageBase64 = imagebase64
|
819
|
+
@EnableDetect = enabledetect
|
820
|
+
@EnablePreferred = enablepreferred
|
821
|
+
end
|
822
|
+
|
823
|
+
def deserialize(params)
|
824
|
+
@ImageUrl = params['ImageUrl']
|
825
|
+
@ImageBase64 = params['ImageBase64']
|
826
|
+
@EnableDetect = params['EnableDetect']
|
827
|
+
@EnablePreferred = params['EnablePreferred']
|
828
|
+
end
|
829
|
+
end
|
830
|
+
|
831
|
+
# DetectChefDress返回参数结构体
|
832
|
+
class DetectChefDressResponse < TencentCloud::Common::AbstractModel
|
833
|
+
# @param Bodies: 识别到的人体属性信息。单个人体属性信息包括人体检测置信度,属性信息,人体检测框。
|
834
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
835
|
+
# @type Bodies: Array
|
836
|
+
# @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
837
|
+
# @type RequestId: String
|
838
|
+
|
839
|
+
attr_accessor :Bodies, :RequestId
|
840
|
+
|
841
|
+
def initialize(bodies=nil, requestid=nil)
|
842
|
+
@Bodies = bodies
|
843
|
+
@RequestId = requestid
|
844
|
+
end
|
845
|
+
|
846
|
+
def deserialize(params)
|
847
|
+
unless params['Bodies'].nil?
|
848
|
+
@Bodies = []
|
849
|
+
params['Bodies'].each do |i|
|
850
|
+
attributesforbody_tmp = AttributesForBody.new
|
851
|
+
attributesforbody_tmp.deserialize(i)
|
852
|
+
@Bodies << attributesforbody_tmp
|
853
|
+
end
|
854
|
+
end
|
855
|
+
@RequestId = params['RequestId']
|
856
|
+
end
|
857
|
+
end
|
858
|
+
|
726
859
|
# DetectDisgust请求参数结构体
|
727
860
|
class DetectDisgustRequest < TencentCloud::Common::AbstractModel
|
728
861
|
# @param ImageUrl: 图片URL地址。
|
@@ -1398,6 +1531,76 @@ module TencentCloud
|
|
1398
1531
|
end
|
1399
1532
|
end
|
1400
1533
|
|
1534
|
+
# DetectSecurity请求参数结构体
|
1535
|
+
class DetectSecurityRequest < TencentCloud::Common::AbstractModel
|
1536
|
+
# @param ImageUrl: 图片的 Url 。
|
1537
|
+
# ImageUrl和ImageBase64必须提供一个,同时存在时优先使用ImageUrl字段。
|
1538
|
+
# 图片限制:
|
1539
|
+
# • 图片格式:支持PNG、JPG、JPEG、不支持 GIF 图片。
|
1540
|
+
# • 图片大小:对应图片 base64 编码后大小不可超过5M。图片分辨率不超过3840 x 2160 pixel。
|
1541
|
+
# 建议:
|
1542
|
+
# • 接口响应时间会受到图片下载时间的影响,建议使用更可靠的存储服务,推荐将图片存储在腾讯云COS。
|
1543
|
+
# @type ImageUrl: String
|
1544
|
+
# @param ImageBase64: 图片经过base64编码的内容。
|
1545
|
+
# 最大不超过4M。与ImageUrl同时存在时优先使用ImageUrl字段。
|
1546
|
+
# 注意:图片需要base64编码,并且要去掉编码头部。
|
1547
|
+
# 支持的图片格式:PNG、JPG、JPEG、暂不支持GIF格式。
|
1548
|
+
# 支持的图片大小:所下载图片经Base64编码后不超过5M。
|
1549
|
+
# @type ImageBase64: String
|
1550
|
+
# @param EnableDetect: 人体检测模型开关,“true”为开启,“false”为关闭
|
1551
|
+
# 开启后可先对图片中的人体进行检测之后再进行属性识别,默认为开启
|
1552
|
+
# @type EnableDetect: Boolean
|
1553
|
+
# @param EnablePreferred: 人体优选开关,“true”为开启,“false”为关闭
|
1554
|
+
# 开启后自动对检测质量低的人体进行优选过滤,有助于提高属性识别的准确率。
|
1555
|
+
# 默认为开启,仅在人体检测开关开启时可配置,人体检测模型关闭时人体优选也关闭
|
1556
|
+
# 如开启人体优选,检测到的人体分辨率需不大于1920*1080 pixel
|
1557
|
+
# @type EnablePreferred: Boolean
|
1558
|
+
|
1559
|
+
attr_accessor :ImageUrl, :ImageBase64, :EnableDetect, :EnablePreferred
|
1560
|
+
|
1561
|
+
def initialize(imageurl=nil, imagebase64=nil, enabledetect=nil, enablepreferred=nil)
|
1562
|
+
@ImageUrl = imageurl
|
1563
|
+
@ImageBase64 = imagebase64
|
1564
|
+
@EnableDetect = enabledetect
|
1565
|
+
@EnablePreferred = enablepreferred
|
1566
|
+
end
|
1567
|
+
|
1568
|
+
def deserialize(params)
|
1569
|
+
@ImageUrl = params['ImageUrl']
|
1570
|
+
@ImageBase64 = params['ImageBase64']
|
1571
|
+
@EnableDetect = params['EnableDetect']
|
1572
|
+
@EnablePreferred = params['EnablePreferred']
|
1573
|
+
end
|
1574
|
+
end
|
1575
|
+
|
1576
|
+
# DetectSecurity返回参数结构体
|
1577
|
+
class DetectSecurityResponse < TencentCloud::Common::AbstractModel
|
1578
|
+
# @param Bodies: 识别到的人体属性信息。单个人体属性信息包括人体检测置信度,属性信息,人体检测框。
|
1579
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
1580
|
+
# @type Bodies: Array
|
1581
|
+
# @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
1582
|
+
# @type RequestId: String
|
1583
|
+
|
1584
|
+
attr_accessor :Bodies, :RequestId
|
1585
|
+
|
1586
|
+
def initialize(bodies=nil, requestid=nil)
|
1587
|
+
@Bodies = bodies
|
1588
|
+
@RequestId = requestid
|
1589
|
+
end
|
1590
|
+
|
1591
|
+
def deserialize(params)
|
1592
|
+
unless params['Bodies'].nil?
|
1593
|
+
@Bodies = []
|
1594
|
+
params['Bodies'].each do |i|
|
1595
|
+
attributesforbody_tmp = AttributesForBody.new
|
1596
|
+
attributesforbody_tmp.deserialize(i)
|
1597
|
+
@Bodies << attributesforbody_tmp
|
1598
|
+
end
|
1599
|
+
end
|
1600
|
+
@RequestId = params['RequestId']
|
1601
|
+
end
|
1602
|
+
end
|
1603
|
+
|
1401
1604
|
# EnhanceImage请求参数结构体
|
1402
1605
|
class EnhanceImageRequest < TencentCloud::Common::AbstractModel
|
1403
1606
|
# @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: 3.0.
|
4
|
+
version: 3.0.456
|
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-11-
|
11
|
+
date: 2022-11-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: tencentcloud-sdk-common
|