tencentcloud-sdk-python 3.0.1322__py2.py3-none-any.whl → 3.0.1323__py2.py3-none-any.whl
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.
- tencentcloud/__init__.py +1 -1
- tencentcloud/aiart/v20221229/aiart_client.py +54 -0
- tencentcloud/aiart/v20221229/models.py +523 -0
- tencentcloud/ckafka/v20190819/models.py +15 -0
- tencentcloud/cwp/v20180228/cwp_client.py +0 -25
- tencentcloud/cwp/v20180228/models.py +0 -274
- tencentcloud/dcdb/v20180411/dcdb_client.py +46 -0
- tencentcloud/dcdb/v20180411/models.py +379 -0
- tencentcloud/dlc/v20210125/models.py +205 -10
- tencentcloud/ess/v20201111/models.py +2 -2
- tencentcloud/essbasic/v20210526/models.py +2 -2
- tencentcloud/faceid/v20180301/models.py +8 -6
- tencentcloud/lcic/v20220817/models.py +0 -156
- tencentcloud/lke/v20231130/models.py +15 -0
- tencentcloud/lkeap/v20240522/lkeap_client.py +1 -1
- tencentcloud/mqtt/v20240516/models.py +339 -0
- tencentcloud/mqtt/v20240516/mqtt_client.py +23 -0
- tencentcloud/ocr/v20181119/models.py +92 -2
- tencentcloud/taf/v20200210/errorcodes.py +0 -156
- tencentcloud/taf/v20200210/models.py +80 -1291
- tencentcloud/taf/v20200210/taf_client.py +0 -69
- tencentcloud/tcb/v20180608/errorcodes.py +3 -0
- tencentcloud/teo/v20220901/models.py +6 -0
- tencentcloud/tione/v20211111/models.py +19 -0
- tencentcloud/trabbit/v20230418/models.py +15 -304
- tencentcloud/wedata/v20210820/models.py +264 -0
- {tencentcloud_sdk_python-3.0.1322.dist-info → tencentcloud_sdk_python-3.0.1323.dist-info}/METADATA +1 -1
- {tencentcloud_sdk_python-3.0.1322.dist-info → tencentcloud_sdk_python-3.0.1323.dist-info}/RECORD +31 -31
- {tencentcloud_sdk_python-3.0.1322.dist-info → tencentcloud_sdk_python-3.0.1323.dist-info}/LICENSE +0 -0
- {tencentcloud_sdk_python-3.0.1322.dist-info → tencentcloud_sdk_python-3.0.1323.dist-info}/WHEEL +0 -0
- {tencentcloud_sdk_python-3.0.1322.dist-info → tencentcloud_sdk_python-3.0.1323.dist-info}/top_level.txt +0 -0
tencentcloud/__init__.py
CHANGED
@@ -176,6 +176,33 @@ class AiartClient(AbstractClient):
|
|
176
176
|
raise TencentCloudSDKException(type(e).__name__, str(e))
|
177
177
|
|
178
178
|
|
179
|
+
def QueryGlamPicJob(self, request):
|
180
|
+
"""AI 美照接口将根据模板为用户生成精美照片。分为提交任务和查询任务2个接口。
|
181
|
+
- 提交任务:提交一个美照生成异步任务,获得任务 ID。
|
182
|
+
- 查询任务:根据任务 ID 查询任务的处理状态、处理结果,任务处理完成后可获得生成图像结果。
|
183
|
+
|
184
|
+
AI 美照默认提供1个并发,代表最多能同时处理1个已提交的任务,上一个任务处理完毕后才能开始处理下一个任务。
|
185
|
+
|
186
|
+
:param request: Request instance for QueryGlamPicJob.
|
187
|
+
:type request: :class:`tencentcloud.aiart.v20221229.models.QueryGlamPicJobRequest`
|
188
|
+
:rtype: :class:`tencentcloud.aiart.v20221229.models.QueryGlamPicJobResponse`
|
189
|
+
|
190
|
+
"""
|
191
|
+
try:
|
192
|
+
params = request._serialize()
|
193
|
+
headers = request.headers
|
194
|
+
body = self.call("QueryGlamPicJob", params, headers=headers)
|
195
|
+
response = json.loads(body)
|
196
|
+
model = models.QueryGlamPicJobResponse()
|
197
|
+
model._deserialize(response["Response"])
|
198
|
+
return model
|
199
|
+
except Exception as e:
|
200
|
+
if isinstance(e, TencentCloudSDKException):
|
201
|
+
raise
|
202
|
+
else:
|
203
|
+
raise TencentCloudSDKException(type(e).__name__, str(e))
|
204
|
+
|
205
|
+
|
179
206
|
def QueryMemeJob(self, request):
|
180
207
|
"""表情动图生成接口将静态照片制作成动态的表情包。分为提交任务和查询任务2个接口。
|
181
208
|
- 提交任务:提交一个表情动图生成异步任务,获得任务 ID。
|
@@ -339,6 +366,33 @@ class AiartClient(AbstractClient):
|
|
339
366
|
raise TencentCloudSDKException(type(e).__name__, str(e))
|
340
367
|
|
341
368
|
|
369
|
+
def SubmitGlamPicJob(self, request):
|
370
|
+
"""AI 美照接口将根据模板为用户生成精美照片。分为提交任务和查询任务2个接口。
|
371
|
+
- 提交任务:提交一个美照生成异步任务,获得任务 ID。
|
372
|
+
- 查询任务:根据任务 ID 查询任务的处理状态、处理结果,任务处理完成后可获得生成图像结果。
|
373
|
+
|
374
|
+
AI 美照默认提供1个并发,代表最多能同时处理1个已提交的任务,上一个任务处理完毕后才能开始处理下一个任务。
|
375
|
+
|
376
|
+
:param request: Request instance for SubmitGlamPicJob.
|
377
|
+
:type request: :class:`tencentcloud.aiart.v20221229.models.SubmitGlamPicJobRequest`
|
378
|
+
:rtype: :class:`tencentcloud.aiart.v20221229.models.SubmitGlamPicJobResponse`
|
379
|
+
|
380
|
+
"""
|
381
|
+
try:
|
382
|
+
params = request._serialize()
|
383
|
+
headers = request.headers
|
384
|
+
body = self.call("SubmitGlamPicJob", params, headers=headers)
|
385
|
+
response = json.loads(body)
|
386
|
+
model = models.SubmitGlamPicJobResponse()
|
387
|
+
model._deserialize(response["Response"])
|
388
|
+
return model
|
389
|
+
except Exception as e:
|
390
|
+
if isinstance(e, TencentCloudSDKException):
|
391
|
+
raise
|
392
|
+
else:
|
393
|
+
raise TencentCloudSDKException(type(e).__name__, str(e))
|
394
|
+
|
395
|
+
|
342
396
|
def SubmitMemeJob(self, request):
|
343
397
|
"""表情动图生成接口将静态照片制作成动态的表情包。分为提交任务和查询任务2个接口。
|
344
398
|
|
@@ -216,6 +216,59 @@ class ChangeClothesResponse(AbstractModel):
|
|
216
216
|
self._RequestId = params.get("RequestId")
|
217
217
|
|
218
218
|
|
219
|
+
class FaceInfo(AbstractModel):
|
220
|
+
"""融合信息
|
221
|
+
|
222
|
+
"""
|
223
|
+
|
224
|
+
def __init__(self):
|
225
|
+
r"""
|
226
|
+
:param _ImageUrls: 用户图 URL 列表
|
227
|
+
:type ImageUrls: list of str
|
228
|
+
:param _TemplateFaceRect: 模版图人脸坐标。
|
229
|
+
:type TemplateFaceRect: :class:`tencentcloud.aiart.v20221229.models.Rect`
|
230
|
+
"""
|
231
|
+
self._ImageUrls = None
|
232
|
+
self._TemplateFaceRect = None
|
233
|
+
|
234
|
+
@property
|
235
|
+
def ImageUrls(self):
|
236
|
+
"""用户图 URL 列表
|
237
|
+
:rtype: list of str
|
238
|
+
"""
|
239
|
+
return self._ImageUrls
|
240
|
+
|
241
|
+
@ImageUrls.setter
|
242
|
+
def ImageUrls(self, ImageUrls):
|
243
|
+
self._ImageUrls = ImageUrls
|
244
|
+
|
245
|
+
@property
|
246
|
+
def TemplateFaceRect(self):
|
247
|
+
"""模版图人脸坐标。
|
248
|
+
:rtype: :class:`tencentcloud.aiart.v20221229.models.Rect`
|
249
|
+
"""
|
250
|
+
return self._TemplateFaceRect
|
251
|
+
|
252
|
+
@TemplateFaceRect.setter
|
253
|
+
def TemplateFaceRect(self, TemplateFaceRect):
|
254
|
+
self._TemplateFaceRect = TemplateFaceRect
|
255
|
+
|
256
|
+
|
257
|
+
def _deserialize(self, params):
|
258
|
+
self._ImageUrls = params.get("ImageUrls")
|
259
|
+
if params.get("TemplateFaceRect") is not None:
|
260
|
+
self._TemplateFaceRect = Rect()
|
261
|
+
self._TemplateFaceRect._deserialize(params.get("TemplateFaceRect"))
|
262
|
+
memeber_set = set(params.keys())
|
263
|
+
for name, value in vars(self).items():
|
264
|
+
property_name = name[1:]
|
265
|
+
if property_name in memeber_set:
|
266
|
+
memeber_set.remove(property_name)
|
267
|
+
if len(memeber_set) > 0:
|
268
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
269
|
+
|
270
|
+
|
271
|
+
|
219
272
|
class Filter(AbstractModel):
|
220
273
|
"""训练图像质量过滤开关配置。
|
221
274
|
支持开启或关闭对训练图像分辨率下限、脸部区域大小、脸部遮挡、脸部角度的过滤,默认开启以上过滤。
|
@@ -1521,6 +1574,172 @@ URL 有效期1小时,请及时保存。
|
|
1521
1574
|
self._RequestId = params.get("RequestId")
|
1522
1575
|
|
1523
1576
|
|
1577
|
+
class QueryGlamPicJobRequest(AbstractModel):
|
1578
|
+
"""QueryGlamPicJob请求参数结构体
|
1579
|
+
|
1580
|
+
"""
|
1581
|
+
|
1582
|
+
def __init__(self):
|
1583
|
+
r"""
|
1584
|
+
:param _JobId: 任务ID。
|
1585
|
+
:type JobId: str
|
1586
|
+
"""
|
1587
|
+
self._JobId = None
|
1588
|
+
|
1589
|
+
@property
|
1590
|
+
def JobId(self):
|
1591
|
+
"""任务ID。
|
1592
|
+
:rtype: str
|
1593
|
+
"""
|
1594
|
+
return self._JobId
|
1595
|
+
|
1596
|
+
@JobId.setter
|
1597
|
+
def JobId(self, JobId):
|
1598
|
+
self._JobId = JobId
|
1599
|
+
|
1600
|
+
|
1601
|
+
def _deserialize(self, params):
|
1602
|
+
self._JobId = params.get("JobId")
|
1603
|
+
memeber_set = set(params.keys())
|
1604
|
+
for name, value in vars(self).items():
|
1605
|
+
property_name = name[1:]
|
1606
|
+
if property_name in memeber_set:
|
1607
|
+
memeber_set.remove(property_name)
|
1608
|
+
if len(memeber_set) > 0:
|
1609
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
1610
|
+
|
1611
|
+
|
1612
|
+
|
1613
|
+
class QueryGlamPicJobResponse(AbstractModel):
|
1614
|
+
"""QueryGlamPicJob返回参数结构体
|
1615
|
+
|
1616
|
+
"""
|
1617
|
+
|
1618
|
+
def __init__(self):
|
1619
|
+
r"""
|
1620
|
+
:param _JobStatusCode: 当前任务状态码:
|
1621
|
+
1:等待中、2:运行中、4:处理失败、5:处理完成。
|
1622
|
+
:type JobStatusCode: str
|
1623
|
+
:param _JobStatusMsg: 当前任务状态:排队中、处理中、处理失败或者处理完成。
|
1624
|
+
|
1625
|
+
:type JobStatusMsg: str
|
1626
|
+
:param _JobErrorCode: 任务处理失败错误码。
|
1627
|
+
|
1628
|
+
:type JobErrorCode: str
|
1629
|
+
:param _JobErrorMsg: 任务处理失败错误信息。
|
1630
|
+
|
1631
|
+
:type JobErrorMsg: str
|
1632
|
+
:param _ResultImage: 生成图 URL 列表,有效期1小时,请及时保存。
|
1633
|
+
|
1634
|
+
:type ResultImage: list of str
|
1635
|
+
:param _ResultDetails: 结果 detail 数组,Success 代表成功。
|
1636
|
+
|
1637
|
+
:type ResultDetails: list of str
|
1638
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
1639
|
+
:type RequestId: str
|
1640
|
+
"""
|
1641
|
+
self._JobStatusCode = None
|
1642
|
+
self._JobStatusMsg = None
|
1643
|
+
self._JobErrorCode = None
|
1644
|
+
self._JobErrorMsg = None
|
1645
|
+
self._ResultImage = None
|
1646
|
+
self._ResultDetails = None
|
1647
|
+
self._RequestId = None
|
1648
|
+
|
1649
|
+
@property
|
1650
|
+
def JobStatusCode(self):
|
1651
|
+
"""当前任务状态码:
|
1652
|
+
1:等待中、2:运行中、4:处理失败、5:处理完成。
|
1653
|
+
:rtype: str
|
1654
|
+
"""
|
1655
|
+
return self._JobStatusCode
|
1656
|
+
|
1657
|
+
@JobStatusCode.setter
|
1658
|
+
def JobStatusCode(self, JobStatusCode):
|
1659
|
+
self._JobStatusCode = JobStatusCode
|
1660
|
+
|
1661
|
+
@property
|
1662
|
+
def JobStatusMsg(self):
|
1663
|
+
"""当前任务状态:排队中、处理中、处理失败或者处理完成。
|
1664
|
+
|
1665
|
+
:rtype: str
|
1666
|
+
"""
|
1667
|
+
return self._JobStatusMsg
|
1668
|
+
|
1669
|
+
@JobStatusMsg.setter
|
1670
|
+
def JobStatusMsg(self, JobStatusMsg):
|
1671
|
+
self._JobStatusMsg = JobStatusMsg
|
1672
|
+
|
1673
|
+
@property
|
1674
|
+
def JobErrorCode(self):
|
1675
|
+
"""任务处理失败错误码。
|
1676
|
+
|
1677
|
+
:rtype: str
|
1678
|
+
"""
|
1679
|
+
return self._JobErrorCode
|
1680
|
+
|
1681
|
+
@JobErrorCode.setter
|
1682
|
+
def JobErrorCode(self, JobErrorCode):
|
1683
|
+
self._JobErrorCode = JobErrorCode
|
1684
|
+
|
1685
|
+
@property
|
1686
|
+
def JobErrorMsg(self):
|
1687
|
+
"""任务处理失败错误信息。
|
1688
|
+
|
1689
|
+
:rtype: str
|
1690
|
+
"""
|
1691
|
+
return self._JobErrorMsg
|
1692
|
+
|
1693
|
+
@JobErrorMsg.setter
|
1694
|
+
def JobErrorMsg(self, JobErrorMsg):
|
1695
|
+
self._JobErrorMsg = JobErrorMsg
|
1696
|
+
|
1697
|
+
@property
|
1698
|
+
def ResultImage(self):
|
1699
|
+
"""生成图 URL 列表,有效期1小时,请及时保存。
|
1700
|
+
|
1701
|
+
:rtype: list of str
|
1702
|
+
"""
|
1703
|
+
return self._ResultImage
|
1704
|
+
|
1705
|
+
@ResultImage.setter
|
1706
|
+
def ResultImage(self, ResultImage):
|
1707
|
+
self._ResultImage = ResultImage
|
1708
|
+
|
1709
|
+
@property
|
1710
|
+
def ResultDetails(self):
|
1711
|
+
"""结果 detail 数组,Success 代表成功。
|
1712
|
+
|
1713
|
+
:rtype: list of str
|
1714
|
+
"""
|
1715
|
+
return self._ResultDetails
|
1716
|
+
|
1717
|
+
@ResultDetails.setter
|
1718
|
+
def ResultDetails(self, ResultDetails):
|
1719
|
+
self._ResultDetails = ResultDetails
|
1720
|
+
|
1721
|
+
@property
|
1722
|
+
def RequestId(self):
|
1723
|
+
"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
1724
|
+
:rtype: str
|
1725
|
+
"""
|
1726
|
+
return self._RequestId
|
1727
|
+
|
1728
|
+
@RequestId.setter
|
1729
|
+
def RequestId(self, RequestId):
|
1730
|
+
self._RequestId = RequestId
|
1731
|
+
|
1732
|
+
|
1733
|
+
def _deserialize(self, params):
|
1734
|
+
self._JobStatusCode = params.get("JobStatusCode")
|
1735
|
+
self._JobStatusMsg = params.get("JobStatusMsg")
|
1736
|
+
self._JobErrorCode = params.get("JobErrorCode")
|
1737
|
+
self._JobErrorMsg = params.get("JobErrorMsg")
|
1738
|
+
self._ResultImage = params.get("ResultImage")
|
1739
|
+
self._ResultDetails = params.get("ResultDetails")
|
1740
|
+
self._RequestId = params.get("RequestId")
|
1741
|
+
|
1742
|
+
|
1524
1743
|
class QueryMemeJobRequest(AbstractModel):
|
1525
1744
|
"""QueryMemeJob请求参数结构体
|
1526
1745
|
|
@@ -1975,6 +2194,87 @@ INIT: 初始化、WAIT:等待中、RUN:运行中、FAIL:处理失败、DON
|
|
1975
2194
|
self._RequestId = params.get("RequestId")
|
1976
2195
|
|
1977
2196
|
|
2197
|
+
class Rect(AbstractModel):
|
2198
|
+
"""人脸框坐标
|
2199
|
+
|
2200
|
+
"""
|
2201
|
+
|
2202
|
+
def __init__(self):
|
2203
|
+
r"""
|
2204
|
+
:param _X: 人脸框左上角横坐标。
|
2205
|
+
:type X: int
|
2206
|
+
:param _Y: 人脸框左上角纵坐标。
|
2207
|
+
:type Y: int
|
2208
|
+
:param _Width: 人脸框宽度。
|
2209
|
+
:type Width: int
|
2210
|
+
:param _Height: 人脸框高度。
|
2211
|
+
:type Height: int
|
2212
|
+
"""
|
2213
|
+
self._X = None
|
2214
|
+
self._Y = None
|
2215
|
+
self._Width = None
|
2216
|
+
self._Height = None
|
2217
|
+
|
2218
|
+
@property
|
2219
|
+
def X(self):
|
2220
|
+
"""人脸框左上角横坐标。
|
2221
|
+
:rtype: int
|
2222
|
+
"""
|
2223
|
+
return self._X
|
2224
|
+
|
2225
|
+
@X.setter
|
2226
|
+
def X(self, X):
|
2227
|
+
self._X = X
|
2228
|
+
|
2229
|
+
@property
|
2230
|
+
def Y(self):
|
2231
|
+
"""人脸框左上角纵坐标。
|
2232
|
+
:rtype: int
|
2233
|
+
"""
|
2234
|
+
return self._Y
|
2235
|
+
|
2236
|
+
@Y.setter
|
2237
|
+
def Y(self, Y):
|
2238
|
+
self._Y = Y
|
2239
|
+
|
2240
|
+
@property
|
2241
|
+
def Width(self):
|
2242
|
+
"""人脸框宽度。
|
2243
|
+
:rtype: int
|
2244
|
+
"""
|
2245
|
+
return self._Width
|
2246
|
+
|
2247
|
+
@Width.setter
|
2248
|
+
def Width(self, Width):
|
2249
|
+
self._Width = Width
|
2250
|
+
|
2251
|
+
@property
|
2252
|
+
def Height(self):
|
2253
|
+
"""人脸框高度。
|
2254
|
+
:rtype: int
|
2255
|
+
"""
|
2256
|
+
return self._Height
|
2257
|
+
|
2258
|
+
@Height.setter
|
2259
|
+
def Height(self, Height):
|
2260
|
+
self._Height = Height
|
2261
|
+
|
2262
|
+
|
2263
|
+
def _deserialize(self, params):
|
2264
|
+
self._X = params.get("X")
|
2265
|
+
self._Y = params.get("Y")
|
2266
|
+
self._Width = params.get("Width")
|
2267
|
+
self._Height = params.get("Height")
|
2268
|
+
memeber_set = set(params.keys())
|
2269
|
+
for name, value in vars(self).items():
|
2270
|
+
property_name = name[1:]
|
2271
|
+
if property_name in memeber_set:
|
2272
|
+
memeber_set.remove(property_name)
|
2273
|
+
if len(memeber_set) > 0:
|
2274
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
2275
|
+
|
2276
|
+
|
2277
|
+
|
1978
2278
|
class ReplaceBackgroundRequest(AbstractModel):
|
1979
2279
|
"""ReplaceBackground请求参数结构体
|
1980
2280
|
|
@@ -2650,6 +2950,229 @@ class SubmitDrawPortraitJobResponse(AbstractModel):
|
|
2650
2950
|
self._RequestId = params.get("RequestId")
|
2651
2951
|
|
2652
2952
|
|
2953
|
+
class SubmitGlamPicJobRequest(AbstractModel):
|
2954
|
+
"""SubmitGlamPicJob请求参数结构体
|
2955
|
+
|
2956
|
+
"""
|
2957
|
+
|
2958
|
+
def __init__(self):
|
2959
|
+
r"""
|
2960
|
+
:param _TemplateUrl: 美照模板图 URL。
|
2961
|
+
图片限制:模板图中最多出现5张人脸,单边分辨率大于300,转成 Base64 字符串后小于 10MB,格式支持 jpg、jpeg、png、bmp、tiff、webp。
|
2962
|
+
:type TemplateUrl: str
|
2963
|
+
:param _FaceInfos: 用户图 URL 列表,以及模板图中需要替换成用户的人脸框信息。
|
2964
|
+
一张美照中可包含1 ~ 5个用户形象。每个用户需上传1 ~ 6张照片,如果图中存在多个人脸将取最大人脸。
|
2965
|
+
模板图中的人脸数量需要大于等于用户个数。如果不传每个用户在模板图中的人脸框位置,默认按照模板图人脸框从大到小的顺序进行替换。如需自定义顺序,需要依次上传每个用户在模板图中的人脸框位置。
|
2966
|
+
图片限制:每张图片转成 Base64 字符串后小于 10MB,格式支持 jpg、jpeg、png、bmp、tiff、webp。建议使用单人、正脸、脸部区域占比较大、脸部清晰无遮挡、无大角度偏转、无夸张表情的用户图。
|
2967
|
+
:type FaceInfos: list of FaceInfo
|
2968
|
+
:param _Num: 美照生成数量。
|
2969
|
+
支持1 ~ 4张,默认生成4张。
|
2970
|
+
:type Num: int
|
2971
|
+
:param _Style: 美照生成风格。
|
2972
|
+
仅对单人美照生效,单人可支持选择不同风格。需按照美照生成数量,在数组中逐一填入每张美照的风格名称。如果不传,默认取不重复的随机风格顺序。
|
2973
|
+
多人美照只支持 balanced 一种风格,该参数不生效。
|
2974
|
+
可选风格:<ul><li>real:面部相似度更高。</li><li>balanced:平衡面部真实感和美观度。</li><li>extured:脸部皮肤更具真实感。</li><li>beautiful:脸部美观度更高。</li></ul>
|
2975
|
+
:type Style: list of str
|
2976
|
+
:param _Similarity: 相似度系数,越高越像用户图。
|
2977
|
+
取值范围[0, 1],默认为0.6。
|
2978
|
+
:type Similarity: float
|
2979
|
+
:param _Clarity: 超分选项,默认不做超分,可选开启。
|
2980
|
+
x2:2倍超分
|
2981
|
+
x4:4倍超分
|
2982
|
+
:type Clarity: str
|
2983
|
+
:param _LogoAdd: 为生成结果图添加标识的开关,默认为1。
|
2984
|
+
1:添加标识。
|
2985
|
+
0:不添加标识。
|
2986
|
+
其他数值:默认按1处理。
|
2987
|
+
建议您使用显著标识来提示结果图是 AI 生成的图片。
|
2988
|
+
:type LogoAdd: int
|
2989
|
+
:param _LogoParam: 标识内容设置。
|
2990
|
+
默认在生成结果图右下角添加“图片由 AI 生成”字样,您可根据自身需要替换为其他的标识图片。
|
2991
|
+
:type LogoParam: :class:`tencentcloud.aiart.v20221229.models.LogoParam`
|
2992
|
+
"""
|
2993
|
+
self._TemplateUrl = None
|
2994
|
+
self._FaceInfos = None
|
2995
|
+
self._Num = None
|
2996
|
+
self._Style = None
|
2997
|
+
self._Similarity = None
|
2998
|
+
self._Clarity = None
|
2999
|
+
self._LogoAdd = None
|
3000
|
+
self._LogoParam = None
|
3001
|
+
|
3002
|
+
@property
|
3003
|
+
def TemplateUrl(self):
|
3004
|
+
"""美照模板图 URL。
|
3005
|
+
图片限制:模板图中最多出现5张人脸,单边分辨率大于300,转成 Base64 字符串后小于 10MB,格式支持 jpg、jpeg、png、bmp、tiff、webp。
|
3006
|
+
:rtype: str
|
3007
|
+
"""
|
3008
|
+
return self._TemplateUrl
|
3009
|
+
|
3010
|
+
@TemplateUrl.setter
|
3011
|
+
def TemplateUrl(self, TemplateUrl):
|
3012
|
+
self._TemplateUrl = TemplateUrl
|
3013
|
+
|
3014
|
+
@property
|
3015
|
+
def FaceInfos(self):
|
3016
|
+
"""用户图 URL 列表,以及模板图中需要替换成用户的人脸框信息。
|
3017
|
+
一张美照中可包含1 ~ 5个用户形象。每个用户需上传1 ~ 6张照片,如果图中存在多个人脸将取最大人脸。
|
3018
|
+
模板图中的人脸数量需要大于等于用户个数。如果不传每个用户在模板图中的人脸框位置,默认按照模板图人脸框从大到小的顺序进行替换。如需自定义顺序,需要依次上传每个用户在模板图中的人脸框位置。
|
3019
|
+
图片限制:每张图片转成 Base64 字符串后小于 10MB,格式支持 jpg、jpeg、png、bmp、tiff、webp。建议使用单人、正脸、脸部区域占比较大、脸部清晰无遮挡、无大角度偏转、无夸张表情的用户图。
|
3020
|
+
:rtype: list of FaceInfo
|
3021
|
+
"""
|
3022
|
+
return self._FaceInfos
|
3023
|
+
|
3024
|
+
@FaceInfos.setter
|
3025
|
+
def FaceInfos(self, FaceInfos):
|
3026
|
+
self._FaceInfos = FaceInfos
|
3027
|
+
|
3028
|
+
@property
|
3029
|
+
def Num(self):
|
3030
|
+
"""美照生成数量。
|
3031
|
+
支持1 ~ 4张,默认生成4张。
|
3032
|
+
:rtype: int
|
3033
|
+
"""
|
3034
|
+
return self._Num
|
3035
|
+
|
3036
|
+
@Num.setter
|
3037
|
+
def Num(self, Num):
|
3038
|
+
self._Num = Num
|
3039
|
+
|
3040
|
+
@property
|
3041
|
+
def Style(self):
|
3042
|
+
"""美照生成风格。
|
3043
|
+
仅对单人美照生效,单人可支持选择不同风格。需按照美照生成数量,在数组中逐一填入每张美照的风格名称。如果不传,默认取不重复的随机风格顺序。
|
3044
|
+
多人美照只支持 balanced 一种风格,该参数不生效。
|
3045
|
+
可选风格:<ul><li>real:面部相似度更高。</li><li>balanced:平衡面部真实感和美观度。</li><li>extured:脸部皮肤更具真实感。</li><li>beautiful:脸部美观度更高。</li></ul>
|
3046
|
+
:rtype: list of str
|
3047
|
+
"""
|
3048
|
+
return self._Style
|
3049
|
+
|
3050
|
+
@Style.setter
|
3051
|
+
def Style(self, Style):
|
3052
|
+
self._Style = Style
|
3053
|
+
|
3054
|
+
@property
|
3055
|
+
def Similarity(self):
|
3056
|
+
"""相似度系数,越高越像用户图。
|
3057
|
+
取值范围[0, 1],默认为0.6。
|
3058
|
+
:rtype: float
|
3059
|
+
"""
|
3060
|
+
return self._Similarity
|
3061
|
+
|
3062
|
+
@Similarity.setter
|
3063
|
+
def Similarity(self, Similarity):
|
3064
|
+
self._Similarity = Similarity
|
3065
|
+
|
3066
|
+
@property
|
3067
|
+
def Clarity(self):
|
3068
|
+
"""超分选项,默认不做超分,可选开启。
|
3069
|
+
x2:2倍超分
|
3070
|
+
x4:4倍超分
|
3071
|
+
:rtype: str
|
3072
|
+
"""
|
3073
|
+
return self._Clarity
|
3074
|
+
|
3075
|
+
@Clarity.setter
|
3076
|
+
def Clarity(self, Clarity):
|
3077
|
+
self._Clarity = Clarity
|
3078
|
+
|
3079
|
+
@property
|
3080
|
+
def LogoAdd(self):
|
3081
|
+
"""为生成结果图添加标识的开关,默认为1。
|
3082
|
+
1:添加标识。
|
3083
|
+
0:不添加标识。
|
3084
|
+
其他数值:默认按1处理。
|
3085
|
+
建议您使用显著标识来提示结果图是 AI 生成的图片。
|
3086
|
+
:rtype: int
|
3087
|
+
"""
|
3088
|
+
return self._LogoAdd
|
3089
|
+
|
3090
|
+
@LogoAdd.setter
|
3091
|
+
def LogoAdd(self, LogoAdd):
|
3092
|
+
self._LogoAdd = LogoAdd
|
3093
|
+
|
3094
|
+
@property
|
3095
|
+
def LogoParam(self):
|
3096
|
+
"""标识内容设置。
|
3097
|
+
默认在生成结果图右下角添加“图片由 AI 生成”字样,您可根据自身需要替换为其他的标识图片。
|
3098
|
+
:rtype: :class:`tencentcloud.aiart.v20221229.models.LogoParam`
|
3099
|
+
"""
|
3100
|
+
return self._LogoParam
|
3101
|
+
|
3102
|
+
@LogoParam.setter
|
3103
|
+
def LogoParam(self, LogoParam):
|
3104
|
+
self._LogoParam = LogoParam
|
3105
|
+
|
3106
|
+
|
3107
|
+
def _deserialize(self, params):
|
3108
|
+
self._TemplateUrl = params.get("TemplateUrl")
|
3109
|
+
if params.get("FaceInfos") is not None:
|
3110
|
+
self._FaceInfos = []
|
3111
|
+
for item in params.get("FaceInfos"):
|
3112
|
+
obj = FaceInfo()
|
3113
|
+
obj._deserialize(item)
|
3114
|
+
self._FaceInfos.append(obj)
|
3115
|
+
self._Num = params.get("Num")
|
3116
|
+
self._Style = params.get("Style")
|
3117
|
+
self._Similarity = params.get("Similarity")
|
3118
|
+
self._Clarity = params.get("Clarity")
|
3119
|
+
self._LogoAdd = params.get("LogoAdd")
|
3120
|
+
if params.get("LogoParam") is not None:
|
3121
|
+
self._LogoParam = LogoParam()
|
3122
|
+
self._LogoParam._deserialize(params.get("LogoParam"))
|
3123
|
+
memeber_set = set(params.keys())
|
3124
|
+
for name, value in vars(self).items():
|
3125
|
+
property_name = name[1:]
|
3126
|
+
if property_name in memeber_set:
|
3127
|
+
memeber_set.remove(property_name)
|
3128
|
+
if len(memeber_set) > 0:
|
3129
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
3130
|
+
|
3131
|
+
|
3132
|
+
|
3133
|
+
class SubmitGlamPicJobResponse(AbstractModel):
|
3134
|
+
"""SubmitGlamPicJob返回参数结构体
|
3135
|
+
|
3136
|
+
"""
|
3137
|
+
|
3138
|
+
def __init__(self):
|
3139
|
+
r"""
|
3140
|
+
:param _JobId: 任务ID。
|
3141
|
+
:type JobId: str
|
3142
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
3143
|
+
:type RequestId: str
|
3144
|
+
"""
|
3145
|
+
self._JobId = None
|
3146
|
+
self._RequestId = None
|
3147
|
+
|
3148
|
+
@property
|
3149
|
+
def JobId(self):
|
3150
|
+
"""任务ID。
|
3151
|
+
:rtype: str
|
3152
|
+
"""
|
3153
|
+
return self._JobId
|
3154
|
+
|
3155
|
+
@JobId.setter
|
3156
|
+
def JobId(self, JobId):
|
3157
|
+
self._JobId = JobId
|
3158
|
+
|
3159
|
+
@property
|
3160
|
+
def RequestId(self):
|
3161
|
+
"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
3162
|
+
:rtype: str
|
3163
|
+
"""
|
3164
|
+
return self._RequestId
|
3165
|
+
|
3166
|
+
@RequestId.setter
|
3167
|
+
def RequestId(self, RequestId):
|
3168
|
+
self._RequestId = RequestId
|
3169
|
+
|
3170
|
+
|
3171
|
+
def _deserialize(self, params):
|
3172
|
+
self._JobId = params.get("JobId")
|
3173
|
+
self._RequestId = params.get("RequestId")
|
3174
|
+
|
3175
|
+
|
2653
3176
|
class SubmitMemeJobRequest(AbstractModel):
|
2654
3177
|
"""SubmitMemeJob请求参数结构体
|
2655
3178
|
|
@@ -20565,6 +20565,8 @@ class InstanceAttributesResponse(AbstractModel):
|
|
20565
20565
|
:type ElasticFloatBandwidth: int
|
20566
20566
|
:param _CustomCertId: ssl自定义证书id
|
20567
20567
|
:type CustomCertId: str
|
20568
|
+
:param _UncleanLeaderElectionEnable: 集群topic默认 unclean.leader.election.enable配置: 1 开启 0 关闭
|
20569
|
+
:type UncleanLeaderElectionEnable: int
|
20568
20570
|
"""
|
20569
20571
|
self._InstanceId = None
|
20570
20572
|
self._InstanceName = None
|
@@ -20606,6 +20608,7 @@ class InstanceAttributesResponse(AbstractModel):
|
|
20606
20608
|
self._FreePartitionNumber = None
|
20607
20609
|
self._ElasticFloatBandwidth = None
|
20608
20610
|
self._CustomCertId = None
|
20611
|
+
self._UncleanLeaderElectionEnable = None
|
20609
20612
|
|
20610
20613
|
@property
|
20611
20614
|
def InstanceId(self):
|
@@ -21065,6 +21068,17 @@ class InstanceAttributesResponse(AbstractModel):
|
|
21065
21068
|
def CustomCertId(self, CustomCertId):
|
21066
21069
|
self._CustomCertId = CustomCertId
|
21067
21070
|
|
21071
|
+
@property
|
21072
|
+
def UncleanLeaderElectionEnable(self):
|
21073
|
+
"""集群topic默认 unclean.leader.election.enable配置: 1 开启 0 关闭
|
21074
|
+
:rtype: int
|
21075
|
+
"""
|
21076
|
+
return self._UncleanLeaderElectionEnable
|
21077
|
+
|
21078
|
+
@UncleanLeaderElectionEnable.setter
|
21079
|
+
def UncleanLeaderElectionEnable(self, UncleanLeaderElectionEnable):
|
21080
|
+
self._UncleanLeaderElectionEnable = UncleanLeaderElectionEnable
|
21081
|
+
|
21068
21082
|
|
21069
21083
|
def _deserialize(self, params):
|
21070
21084
|
self._InstanceId = params.get("InstanceId")
|
@@ -21123,6 +21137,7 @@ class InstanceAttributesResponse(AbstractModel):
|
|
21123
21137
|
self._FreePartitionNumber = params.get("FreePartitionNumber")
|
21124
21138
|
self._ElasticFloatBandwidth = params.get("ElasticFloatBandwidth")
|
21125
21139
|
self._CustomCertId = params.get("CustomCertId")
|
21140
|
+
self._UncleanLeaderElectionEnable = params.get("UncleanLeaderElectionEnable")
|
21126
21141
|
memeber_set = set(params.keys())
|
21127
21142
|
for name, value in vars(self).items():
|
21128
21143
|
property_name = name[1:]
|
@@ -7090,31 +7090,6 @@ class CwpClient(AbstractClient):
|
|
7090
7090
|
raise TencentCloudSDKException(type(e).__name__, str(e))
|
7091
7091
|
|
7092
7092
|
|
7093
|
-
def DescribeSecurityProtectionStat(self, request):
|
7094
|
-
"""接口已无效
|
7095
|
-
|
7096
|
-
获取安全防护状态汇总
|
7097
|
-
|
7098
|
-
:param request: Request instance for DescribeSecurityProtectionStat.
|
7099
|
-
:type request: :class:`tencentcloud.cwp.v20180228.models.DescribeSecurityProtectionStatRequest`
|
7100
|
-
:rtype: :class:`tencentcloud.cwp.v20180228.models.DescribeSecurityProtectionStatResponse`
|
7101
|
-
|
7102
|
-
"""
|
7103
|
-
try:
|
7104
|
-
params = request._serialize()
|
7105
|
-
headers = request.headers
|
7106
|
-
body = self.call("DescribeSecurityProtectionStat", params, headers=headers)
|
7107
|
-
response = json.loads(body)
|
7108
|
-
model = models.DescribeSecurityProtectionStatResponse()
|
7109
|
-
model._deserialize(response["Response"])
|
7110
|
-
return model
|
7111
|
-
except Exception as e:
|
7112
|
-
if isinstance(e, TencentCloudSDKException):
|
7113
|
-
raise
|
7114
|
-
else:
|
7115
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
7116
|
-
|
7117
|
-
|
7118
7093
|
def DescribeSecurityTrends(self, request):
|
7119
7094
|
"""本接口 (DescribeSecurityTrends) 用于获取安全事件统计数据。
|
7120
7095
|
|