tencentcloud-sdk-python-vcg 3.0.1149__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.
@@ -0,0 +1,17 @@
1
+ # -*- coding: utf-8 -*-
2
+ # Copyright 1999-2018 Tencent Ltd.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+
17
+ __version__ = '3.0.1149'
File without changes
File without changes
@@ -0,0 +1,66 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2021 THL A29 Limited, a Tencent company. All Rights Reserved.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+
17
+ # 下载视频出错。
18
+ FAILEDOPERATION_DOWNLOADERROR = 'FailedOperation.DownloadError'
19
+
20
+ # 任务不存在。
21
+ FAILEDOPERATION_TASKNOTEXIST = 'FailedOperation.TaskNotExist'
22
+
23
+ # 任务状态异常。
24
+ FAILEDOPERATION_TASKSTATUSERROR = 'FailedOperation.TaskStatusError'
25
+
26
+ # 视频解码失败。
27
+ FAILEDOPERATION_VIDEODECODEFAILED = 'FailedOperation.VideoDecodeFailed'
28
+
29
+ # 参数取值错误。
30
+ INVALIDPARAMETERVALUE = 'InvalidParameterValue'
31
+
32
+ # 视频时长超过限制。
33
+ INVALIDPARAMETERVALUE_INVALIDVIDEODURATION = 'InvalidParameterValue.InvalidVideoDuration'
34
+
35
+ # 不支持的视频FPS。
36
+ INVALIDPARAMETERVALUE_INVALIDVIDEOFPS = 'InvalidParameterValue.InvalidVideoFPS'
37
+
38
+ # 不支持的视频格式。
39
+ INVALIDPARAMETERVALUE_INVALIDVIDEOFORMAT = 'InvalidParameterValue.InvalidVideoFormat'
40
+
41
+ # 不支持的分辨率。
42
+ INVALIDPARAMETERVALUE_INVALIDVIDEORESOLUTION = 'InvalidParameterValue.InvalidVideoResolution'
43
+
44
+ # 参数字段或者值有误。
45
+ INVALIDPARAMETERVALUE_PARAMETERVALUEERROR = 'InvalidParameterValue.ParameterValueError'
46
+
47
+ # 风格不存在。
48
+ INVALIDPARAMETERVALUE_STYLENOTEXIST = 'InvalidParameterValue.StyleNotExist'
49
+
50
+ # 视频URL格式不合法。
51
+ INVALIDPARAMETERVALUE_URLILLEGAL = 'InvalidParameterValue.UrlIllegal'
52
+
53
+ # 视频大小超过限制。
54
+ INVALIDPARAMETERVALUE_VIDEOSIZEEXCEED = 'InvalidParameterValue.VideoSizeExceed'
55
+
56
+ # 请求的次数超过了频率限制。
57
+ REQUESTLIMITEXCEEDED = 'RequestLimitExceeded'
58
+
59
+ # 提交任务数超过最大并发。
60
+ REQUESTLIMITEXCEEDED_JOBNUMEXCEED = 'RequestLimitExceeded.JobNumExceed'
61
+
62
+ # 资源不足。
63
+ RESOURCEINSUFFICIENT = 'ResourceInsufficient'
64
+
65
+ # 计费状态未知。
66
+ RESOURCEUNAVAILABLE_NOTEXIST = 'ResourceUnavailable.NotExist'
@@ -0,0 +1,216 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2021 THL A29 Limited, a Tencent company. All Rights Reserved.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+ import warnings
17
+
18
+ from tencentcloud.common.abstract_model import AbstractModel
19
+
20
+
21
+ class DescribeVideoStylizationJobRequest(AbstractModel):
22
+ """DescribeVideoStylizationJob请求参数结构体
23
+
24
+ """
25
+
26
+ def __init__(self):
27
+ r"""
28
+ :param _JobId: 任务ID
29
+ :type JobId: str
30
+ """
31
+ self._JobId = None
32
+
33
+ @property
34
+ def JobId(self):
35
+ return self._JobId
36
+
37
+ @JobId.setter
38
+ def JobId(self, JobId):
39
+ self._JobId = JobId
40
+
41
+
42
+ def _deserialize(self, params):
43
+ self._JobId = params.get("JobId")
44
+ memeber_set = set(params.keys())
45
+ for name, value in vars(self).items():
46
+ property_name = name[1:]
47
+ if property_name in memeber_set:
48
+ memeber_set.remove(property_name)
49
+ if len(memeber_set) > 0:
50
+ warnings.warn("%s fileds are useless." % ",".join(memeber_set))
51
+
52
+
53
+
54
+ class DescribeVideoStylizationJobResponse(AbstractModel):
55
+ """DescribeVideoStylizationJob返回参数结构体
56
+
57
+ """
58
+
59
+ def __init__(self):
60
+ r"""
61
+ :param _JobId: 任务ID。
62
+ :type JobId: str
63
+ :param _StatusCode: 任务状态码:
64
+ JobInit: "初始化中"
65
+ JobModerationFailed: "审核失败",
66
+ JobRunning: "处理中",
67
+ JobFailed: "处理完成",
68
+ JobSuccess: "处理失败"。
69
+ :type StatusCode: str
70
+ :param _StatusMsg: 任务状态描述。
71
+ :type StatusMsg: str
72
+ :param _ResultVideoUrl: 处理结果视频Url。URL有效期为24小时。
73
+ :type ResultVideoUrl: str
74
+ :param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
75
+ :type RequestId: str
76
+ """
77
+ self._JobId = None
78
+ self._StatusCode = None
79
+ self._StatusMsg = None
80
+ self._ResultVideoUrl = None
81
+ self._RequestId = None
82
+
83
+ @property
84
+ def JobId(self):
85
+ return self._JobId
86
+
87
+ @JobId.setter
88
+ def JobId(self, JobId):
89
+ self._JobId = JobId
90
+
91
+ @property
92
+ def StatusCode(self):
93
+ return self._StatusCode
94
+
95
+ @StatusCode.setter
96
+ def StatusCode(self, StatusCode):
97
+ self._StatusCode = StatusCode
98
+
99
+ @property
100
+ def StatusMsg(self):
101
+ return self._StatusMsg
102
+
103
+ @StatusMsg.setter
104
+ def StatusMsg(self, StatusMsg):
105
+ self._StatusMsg = StatusMsg
106
+
107
+ @property
108
+ def ResultVideoUrl(self):
109
+ return self._ResultVideoUrl
110
+
111
+ @ResultVideoUrl.setter
112
+ def ResultVideoUrl(self, ResultVideoUrl):
113
+ self._ResultVideoUrl = ResultVideoUrl
114
+
115
+ @property
116
+ def RequestId(self):
117
+ return self._RequestId
118
+
119
+ @RequestId.setter
120
+ def RequestId(self, RequestId):
121
+ self._RequestId = RequestId
122
+
123
+
124
+ def _deserialize(self, params):
125
+ self._JobId = params.get("JobId")
126
+ self._StatusCode = params.get("StatusCode")
127
+ self._StatusMsg = params.get("StatusMsg")
128
+ self._ResultVideoUrl = params.get("ResultVideoUrl")
129
+ self._RequestId = params.get("RequestId")
130
+
131
+
132
+ class SubmitVideoStylizationJobRequest(AbstractModel):
133
+ """SubmitVideoStylizationJob请求参数结构体
134
+
135
+ """
136
+
137
+ def __init__(self):
138
+ r"""
139
+ :param _StyleId: 风格ID,取值说明:2d_anime 2D动漫;3d_cartoon 3D卡通;3d_china 3D国潮;pixel_art 像素风。
140
+ :type StyleId: str
141
+ :param _VideoUrl: 输入视频URL。视频要求:
142
+ - 视频格式:mp4、mov;
143
+ - 视频时长:1~60秒;
144
+ - 视频分辨率:540P~2056P,即长宽像素数均在540px~2056px范围内;
145
+ - 视频大小:不超过200M;
146
+ - 视频FPS:15~60fps。
147
+ :type VideoUrl: str
148
+ """
149
+ self._StyleId = None
150
+ self._VideoUrl = None
151
+
152
+ @property
153
+ def StyleId(self):
154
+ return self._StyleId
155
+
156
+ @StyleId.setter
157
+ def StyleId(self, StyleId):
158
+ self._StyleId = StyleId
159
+
160
+ @property
161
+ def VideoUrl(self):
162
+ return self._VideoUrl
163
+
164
+ @VideoUrl.setter
165
+ def VideoUrl(self, VideoUrl):
166
+ self._VideoUrl = VideoUrl
167
+
168
+
169
+ def _deserialize(self, params):
170
+ self._StyleId = params.get("StyleId")
171
+ self._VideoUrl = params.get("VideoUrl")
172
+ memeber_set = set(params.keys())
173
+ for name, value in vars(self).items():
174
+ property_name = name[1:]
175
+ if property_name in memeber_set:
176
+ memeber_set.remove(property_name)
177
+ if len(memeber_set) > 0:
178
+ warnings.warn("%s fileds are useless." % ",".join(memeber_set))
179
+
180
+
181
+
182
+ class SubmitVideoStylizationJobResponse(AbstractModel):
183
+ """SubmitVideoStylizationJob返回参数结构体
184
+
185
+ """
186
+
187
+ def __init__(self):
188
+ r"""
189
+ :param _JobId: 任务ID
190
+ :type JobId: str
191
+ :param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
192
+ :type RequestId: str
193
+ """
194
+ self._JobId = None
195
+ self._RequestId = None
196
+
197
+ @property
198
+ def JobId(self):
199
+ return self._JobId
200
+
201
+ @JobId.setter
202
+ def JobId(self, JobId):
203
+ self._JobId = JobId
204
+
205
+ @property
206
+ def RequestId(self):
207
+ return self._RequestId
208
+
209
+ @RequestId.setter
210
+ def RequestId(self, RequestId):
211
+ self._RequestId = RequestId
212
+
213
+
214
+ def _deserialize(self, params):
215
+ self._JobId = params.get("JobId")
216
+ self._RequestId = params.get("RequestId")
@@ -0,0 +1,72 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2021 THL A29 Limited, a Tencent company. All Rights Reserved.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+ import json
17
+
18
+ from tencentcloud.common.exception.tencent_cloud_sdk_exception import TencentCloudSDKException
19
+ from tencentcloud.common.abstract_client import AbstractClient
20
+ from tencentcloud.vcg.v20240404 import models
21
+
22
+
23
+ class VcgClient(AbstractClient):
24
+ _apiVersion = '2024-04-04'
25
+ _endpoint = 'vcg.tencentcloudapi.com'
26
+ _service = 'vcg'
27
+
28
+
29
+ def DescribeVideoStylizationJob(self, request):
30
+ """用于查询视频风格化任务。视频风格化支持将输入视频生成特定风格的视频。生成后的视频画面风格多样、流畅自然,能够满足社交娱乐、互动营销、视频素材制作等场景的需求。
31
+
32
+ :param request: Request instance for DescribeVideoStylizationJob.
33
+ :type request: :class:`tencentcloud.vcg.v20240404.models.DescribeVideoStylizationJobRequest`
34
+ :rtype: :class:`tencentcloud.vcg.v20240404.models.DescribeVideoStylizationJobResponse`
35
+
36
+ """
37
+ try:
38
+ params = request._serialize()
39
+ headers = request.headers
40
+ body = self.call("DescribeVideoStylizationJob", params, headers=headers)
41
+ response = json.loads(body)
42
+ model = models.DescribeVideoStylizationJobResponse()
43
+ model._deserialize(response["Response"])
44
+ return model
45
+ except Exception as e:
46
+ if isinstance(e, TencentCloudSDKException):
47
+ raise
48
+ else:
49
+ raise TencentCloudSDKException(type(e).__name__, str(e))
50
+
51
+
52
+ def SubmitVideoStylizationJob(self, request):
53
+ """用于提交视频风格化任务。支持将输入视频生成特定风格的视频。生成后的视频画面风格多样、流畅自然,能够满足社交娱乐、互动营销、视频素材制作等场景的需求。
54
+
55
+ :param request: Request instance for SubmitVideoStylizationJob.
56
+ :type request: :class:`tencentcloud.vcg.v20240404.models.SubmitVideoStylizationJobRequest`
57
+ :rtype: :class:`tencentcloud.vcg.v20240404.models.SubmitVideoStylizationJobResponse`
58
+
59
+ """
60
+ try:
61
+ params = request._serialize()
62
+ headers = request.headers
63
+ body = self.call("SubmitVideoStylizationJob", params, headers=headers)
64
+ response = json.loads(body)
65
+ model = models.SubmitVideoStylizationJobResponse()
66
+ model._deserialize(response["Response"])
67
+ return model
68
+ except Exception as e:
69
+ if isinstance(e, TencentCloudSDKException):
70
+ raise
71
+ else:
72
+ raise TencentCloudSDKException(type(e).__name__, str(e))
@@ -0,0 +1,48 @@
1
+ Metadata-Version: 2.1
2
+ Name: tencentcloud-sdk-python-vcg
3
+ Version: 3.0.1149
4
+ Summary: Tencent Cloud Vcg SDK for Python
5
+ Home-page: https://github.com/TencentCloud/tencentcloud-sdk-python
6
+ Author: Tencent Cloud
7
+ Author-email: tencentcloudapi@tencent.com
8
+ License: Apache License 2.0
9
+ Platform: any
10
+ Classifier: Development Status :: 5 - Production/Stable
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: Apache Software License
13
+ Classifier: Programming Language :: Python
14
+ Classifier: Programming Language :: Python :: 2.7
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.6
17
+ Classifier: Programming Language :: Python :: 3.7
18
+ Requires-Dist: tencentcloud-sdk-python-common (==3.0.1149)
19
+
20
+ ============================
21
+ Tencent Cloud SDK for Python
22
+ ============================
23
+
24
+ Tencent Cloud Python Vcg SDK is the official software development kit, which allows Python developers to write software that makes use of Tencent Cloud services like CVM and CBS.
25
+ The SDK works on Python versions:
26
+
27
+ * 2.7 and greater, including 3.x
28
+
29
+ Quick Start
30
+ -----------
31
+
32
+ First, install the library:
33
+
34
+ .. code-block:: sh
35
+
36
+ $ pip install tencentcloud-sdk-python-common
37
+ $ pip install tencentcloud-sdk-python-vcg
38
+
39
+ or download source code from github and install:
40
+
41
+ .. code-block:: sh
42
+
43
+ $ git clone https://github.com/tencentcloud/tencentcloud-sdk-python.git
44
+ $ cd tencentcloud-sdk-python
45
+ $ python package.py --components common vcg
46
+
47
+
48
+
@@ -0,0 +1,10 @@
1
+ tencentcloud/__init__.py,sha256=HiMK8HMN73YfEzwlNqw41yzz4U82a-srgYNRwKGk2GA,631
2
+ tencentcloud/vcg/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
+ tencentcloud/vcg/v20240404/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
+ tencentcloud/vcg/v20240404/errorcodes.py,sha256=LvFbwcyYR-JRm50ZChe3HKV2fe_Kg_Kv8Z4zF679o44,2341
5
+ tencentcloud/vcg/v20240404/models.py,sha256=-znnQ-ybh6qsN5IdGmE7cBfZo_TwfkEYUG2RbsvnPSo,6212
6
+ tencentcloud/vcg/v20240404/vcg_client.py,sha256=HDj1lg4spV51IWy_QEF1EMTu19ILlXuEA4lyvaZXA4g,3266
7
+ tencentcloud_sdk_python_vcg-3.0.1149.dist-info/METADATA,sha256=Alxx4RzMS4GNuI9oC05Ya55KLL_RvwwrE49uTXvxeyo,1492
8
+ tencentcloud_sdk_python_vcg-3.0.1149.dist-info/WHEEL,sha256=z9j0xAa_JmUKMpmz72K0ZGALSM_n-wQVmGbleXx2VHg,110
9
+ tencentcloud_sdk_python_vcg-3.0.1149.dist-info/top_level.txt,sha256=g-8OyzoqI6O6LiS85zkeNzhB-osEnRIPZMdyRd_0eL0,13
10
+ tencentcloud_sdk_python_vcg-3.0.1149.dist-info/RECORD,,
@@ -0,0 +1,6 @@
1
+ Wheel-Version: 1.0
2
+ Generator: bdist_wheel (0.37.1)
3
+ Root-Is-Purelib: true
4
+ Tag: py2-none-any
5
+ Tag: py3-none-any
6
+
@@ -0,0 +1 @@
1
+ tencentcloud