1 Star 6 Fork 0

tencentcloud/tencentcloud-sdk-go

Create your Gitee Account
Explore and code with more than 12 million developers,Free private repositories !:)
Sign up
Clone or Download
client.go 105.81 KB
Copy Edit Raw Blame History
tencentcloud authored 2024-08-19 04:22 . release v1.0.986
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404
// Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package v20190529
import (
"context"
"errors"
"github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common"
tchttp "github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/http"
"github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common/profile"
)
const APIVersion = "2019-05-29"
type Client struct {
common.Client
}
// Deprecated
func NewClientWithSecretId(secretId, secretKey, region string) (client *Client, err error) {
cpf := profile.NewClientProfile()
client = &Client{}
client.Init(region).WithSecretId(secretId, secretKey).WithProfile(cpf)
return
}
func NewClient(credential common.CredentialIface, region string, clientProfile *profile.ClientProfile) (client *Client, err error) {
client = &Client{}
client.Init(region).
WithCredential(credential).
WithProfile(clientProfile)
return
}
func NewAssessQualityRequest() (request *AssessQualityRequest) {
request = &AssessQualityRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "AssessQuality")
return
}
func NewAssessQualityResponse() (response *AssessQualityResponse) {
response = &AssessQualityResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// AssessQuality
// 评估输入图片在视觉上的质量,从多个方面评估,并同时给出综合的、客观的清晰度评分,和主观的美观度评分。
//
//
//
// >
//
// - 可前往 [图像处理](https://cloud.tencent.com/document/product/1590) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) AssessQuality(request *AssessQualityRequest) (response *AssessQualityResponse, err error) {
return c.AssessQualityWithContext(context.Background(), request)
}
// AssessQuality
// 评估输入图片在视觉上的质量,从多个方面评估,并同时给出综合的、客观的清晰度评分,和主观的美观度评分。
//
//
//
// >
//
// - 可前往 [图像处理](https://cloud.tencent.com/document/product/1590) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) AssessQualityWithContext(ctx context.Context, request *AssessQualityRequest) (response *AssessQualityResponse, err error) {
if request == nil {
request = NewAssessQualityRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("AssessQuality require credential")
}
request.SetContext(ctx)
response = NewAssessQualityResponse()
err = c.Send(request, response)
return
}
func NewCreateGroupRequest() (request *CreateGroupRequest) {
request = &CreateGroupRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "CreateGroup")
return
}
func NewCreateGroupResponse() (response *CreateGroupResponse) {
response = &CreateGroupResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateGroup
// 本接口用于创建一个空的图片库,图片库主要用于存储在创建图片时提取的图片特征数据,如果图片库已存在则返回错误。不同的图片库类型对应不同的图像搜索服务类型,根据输入参数GroupType区分。
//
//
//
// <table>
//
// <th>服务类型</th><th>GroupType</th><th>功能描述</th>
//
// <tr>
//
// <td>通用图像搜索</td>
//
// <td>4</td>
//
// <td>通用图像搜索1.0版。<br>在自建图片库中搜索相同原图或相似图片集,并给出相似度打分,可支持裁剪、翻转、调色、加水印等二次编辑后的图片搜索。适用于图片版权保护、原图查询等场景。</td>
//
// </tr>
//
// <tr>
//
// <td rowspan="3">商品图像搜索</td>
//
// <td>8</td>
//
// <td>商品图像搜索3.0升级版(推荐)。<br>
//
// 在自建图库中搜索同款或相似商品,并给出相似度打分。对于服饰类商品可支持识别服饰类别、属性等信息。适用于商品分类、检索、推荐等电商场景。</td>
//
// </tr>
//
// <tr>
//
// <td>7</td>
//
// <td>商品图像搜索2.0版。<br>
//
// 功能和3.0升级版类似。</td>
//
// </tr>
//
// <tr>
//
// <td>5</td>
//
// <td>商品图像搜索1.0版。<br>
//
// 功能和3.0升级版类似。</td>
//
// </tr>
//
// <tr>
//
// <td>图案花纹搜索</td><td>6</td><td>图案花纹搜索1.0版。<br>
//
// 在自建图库中搜索相似的图案、logo、纹理等图像元素或主体,并给出相似度打分。</td>
//
// </tr>
//
// </table>
//
//
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_GROUPCOUNTEXCEEDED = "FailedOperation.GroupCountExceeded"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_PARAMETEREMPTY = "FailedOperation.ParameterEmpty"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_BRIEFTOOLONG = "InvalidParameterValue.BriefTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDALREADYEXIST = "InvalidParameterValue.ImageGroupIdAlreadyExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPNAMEEMPTY = "InvalidParameterValue.ImageGroupNameEmpty"
// INVALIDPARAMETERVALUE_IMAGEGROUPNAMETOOLONG = "InvalidParameterValue.ImageGroupNameTooLong"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_LIMITEXCEED = "InvalidParameterValue.LimitExceed"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) CreateGroup(request *CreateGroupRequest) (response *CreateGroupResponse, err error) {
return c.CreateGroupWithContext(context.Background(), request)
}
// CreateGroup
// 本接口用于创建一个空的图片库,图片库主要用于存储在创建图片时提取的图片特征数据,如果图片库已存在则返回错误。不同的图片库类型对应不同的图像搜索服务类型,根据输入参数GroupType区分。
//
//
//
// <table>
//
// <th>服务类型</th><th>GroupType</th><th>功能描述</th>
//
// <tr>
//
// <td>通用图像搜索</td>
//
// <td>4</td>
//
// <td>通用图像搜索1.0版。<br>在自建图片库中搜索相同原图或相似图片集,并给出相似度打分,可支持裁剪、翻转、调色、加水印等二次编辑后的图片搜索。适用于图片版权保护、原图查询等场景。</td>
//
// </tr>
//
// <tr>
//
// <td rowspan="3">商品图像搜索</td>
//
// <td>8</td>
//
// <td>商品图像搜索3.0升级版(推荐)。<br>
//
// 在自建图库中搜索同款或相似商品,并给出相似度打分。对于服饰类商品可支持识别服饰类别、属性等信息。适用于商品分类、检索、推荐等电商场景。</td>
//
// </tr>
//
// <tr>
//
// <td>7</td>
//
// <td>商品图像搜索2.0版。<br>
//
// 功能和3.0升级版类似。</td>
//
// </tr>
//
// <tr>
//
// <td>5</td>
//
// <td>商品图像搜索1.0版。<br>
//
// 功能和3.0升级版类似。</td>
//
// </tr>
//
// <tr>
//
// <td>图案花纹搜索</td><td>6</td><td>图案花纹搜索1.0版。<br>
//
// 在自建图库中搜索相似的图案、logo、纹理等图像元素或主体,并给出相似度打分。</td>
//
// </tr>
//
// </table>
//
//
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_GROUPCOUNTEXCEEDED = "FailedOperation.GroupCountExceeded"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_PARAMETEREMPTY = "FailedOperation.ParameterEmpty"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_BRIEFTOOLONG = "InvalidParameterValue.BriefTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDALREADYEXIST = "InvalidParameterValue.ImageGroupIdAlreadyExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPNAMEEMPTY = "InvalidParameterValue.ImageGroupNameEmpty"
// INVALIDPARAMETERVALUE_IMAGEGROUPNAMETOOLONG = "InvalidParameterValue.ImageGroupNameTooLong"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_LIMITEXCEED = "InvalidParameterValue.LimitExceed"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) CreateGroupWithContext(ctx context.Context, request *CreateGroupRequest) (response *CreateGroupResponse, err error) {
if request == nil {
request = NewCreateGroupRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("CreateGroup require credential")
}
request.SetContext(ctx)
response = NewCreateGroupResponse()
err = c.Send(request, response)
return
}
func NewCreateImageRequest() (request *CreateImageRequest) {
request = &CreateImageRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "CreateImage")
return
}
func NewCreateImageResponse() (response *CreateImageResponse) {
response = &CreateImageResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CreateImage
// 创建图片,并添加对应图片的自定义信息。模型将在创建图片时自动提取图像特征并存储到指定的图片库中,每创建一张图片会对应提取和存储一条图片特征数据。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
//
//
// 可能返回的错误码:
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEDOWNLOADERROR = "FailedOperation.ImageDownloadError"
// FAILEDOPERATION_IMAGEENTITYCOUNTEXCEED = "FailedOperation.ImageEntityCountExceed"
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGENUMEXCEED = "FailedOperation.ImageNumExceed"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_IMAGEFORMATNOTSUPPORT = "InvalidParameter.ImageFormatNotSupport"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETER_PICTURESOLIDCOLORERROR = "InvalidParameter.PictureSolidColorError"
// INVALIDPARAMETERVALUE_CUSTOMCONTENTTOOLONG = "InvalidParameterValue.CustomContentTooLong"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEALREADYEXIST = "InvalidParameterValue.PicNameAlreadyExist"
// INVALIDPARAMETERVALUE_PICNAMEEMPTY = "InvalidParameterValue.PicNameEmpty"
// INVALIDPARAMETERVALUE_PICNAMEINVALID = "InvalidParameterValue.PicNameInvalid"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// INVALIDPARAMETERVALUE_TAGSKEYSEXCEED = "InvalidParameterValue.TagsKeysExceed"
// INVALIDPARAMETERVALUE_TAGSVALUEILLEGAL = "InvalidParameterValue.TagsValueIllegal"
// INVALIDPARAMETERVALUE_TAGSVALUESIZEEXCEED = "InvalidParameterValue.TagsValueSizeExceed"
// MISSINGPARAMETER_ERRORPARAMETEREMPTY = "MissingParameter.ErrorParameterEmpty"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) CreateImage(request *CreateImageRequest) (response *CreateImageResponse, err error) {
return c.CreateImageWithContext(context.Background(), request)
}
// CreateImage
// 创建图片,并添加对应图片的自定义信息。模型将在创建图片时自动提取图像特征并存储到指定的图片库中,每创建一张图片会对应提取和存储一条图片特征数据。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
//
//
// 可能返回的错误码:
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEDOWNLOADERROR = "FailedOperation.ImageDownloadError"
// FAILEDOPERATION_IMAGEENTITYCOUNTEXCEED = "FailedOperation.ImageEntityCountExceed"
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGENUMEXCEED = "FailedOperation.ImageNumExceed"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_IMAGEFORMATNOTSUPPORT = "InvalidParameter.ImageFormatNotSupport"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETER_PICTURESOLIDCOLORERROR = "InvalidParameter.PictureSolidColorError"
// INVALIDPARAMETERVALUE_CUSTOMCONTENTTOOLONG = "InvalidParameterValue.CustomContentTooLong"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEALREADYEXIST = "InvalidParameterValue.PicNameAlreadyExist"
// INVALIDPARAMETERVALUE_PICNAMEEMPTY = "InvalidParameterValue.PicNameEmpty"
// INVALIDPARAMETERVALUE_PICNAMEINVALID = "InvalidParameterValue.PicNameInvalid"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// INVALIDPARAMETERVALUE_TAGSKEYSEXCEED = "InvalidParameterValue.TagsKeysExceed"
// INVALIDPARAMETERVALUE_TAGSVALUEILLEGAL = "InvalidParameterValue.TagsValueIllegal"
// INVALIDPARAMETERVALUE_TAGSVALUESIZEEXCEED = "InvalidParameterValue.TagsValueSizeExceed"
// MISSINGPARAMETER_ERRORPARAMETEREMPTY = "MissingParameter.ErrorParameterEmpty"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) CreateImageWithContext(ctx context.Context, request *CreateImageRequest) (response *CreateImageResponse, err error) {
if request == nil {
request = NewCreateImageRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("CreateImage require credential")
}
request.SetContext(ctx)
response = NewCreateImageResponse()
err = c.Send(request, response)
return
}
func NewCropImageRequest() (request *CropImageRequest) {
request = &CropImageRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "CropImage")
return
}
func NewCropImageResponse() (response *CropImageResponse) {
response = &CropImageResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// CropImage
// 根据输入的裁剪比例,智能判断一张图片的最佳裁剪区域,确保原图的主体区域不受影响,以适应不同平台、设备的展示要求,避免简单拉伸带来的变形。
//
//
//
// >
//
// - 可前往 [图像处理](https://cloud.tencent.com/document/product/1590) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) CropImage(request *CropImageRequest) (response *CropImageResponse, err error) {
return c.CropImageWithContext(context.Background(), request)
}
// CropImage
// 根据输入的裁剪比例,智能判断一张图片的最佳裁剪区域,确保原图的主体区域不受影响,以适应不同平台、设备的展示要求,避免简单拉伸带来的变形。
//
//
//
// >
//
// - 可前往 [图像处理](https://cloud.tencent.com/document/product/1590) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) CropImageWithContext(ctx context.Context, request *CropImageRequest) (response *CropImageResponse, err error) {
if request == nil {
request = NewCropImageRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("CropImage require credential")
}
request.SetContext(ctx)
response = NewCropImageResponse()
err = c.Send(request, response)
return
}
func NewDeleteImagesRequest() (request *DeleteImagesRequest) {
request = &DeleteImagesRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DeleteImages")
return
}
func NewDeleteImagesResponse() (response *DeleteImagesResponse) {
response = &DeleteImagesResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DeleteImages
// 删除图片。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDELETEFAILED = "FailedOperation.ImageDeleteFailed"
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEINVALID = "InvalidParameterValue.PicNameInvalid"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DeleteImages(request *DeleteImagesRequest) (response *DeleteImagesResponse, err error) {
return c.DeleteImagesWithContext(context.Background(), request)
}
// DeleteImages
// 删除图片。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDELETEFAILED = "FailedOperation.ImageDeleteFailed"
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEINVALID = "InvalidParameterValue.PicNameInvalid"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DeleteImagesWithContext(ctx context.Context, request *DeleteImagesRequest) (response *DeleteImagesResponse, err error) {
if request == nil {
request = NewDeleteImagesRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DeleteImages require credential")
}
request.SetContext(ctx)
response = NewDeleteImagesResponse()
err = c.Send(request, response)
return
}
func NewDescribeGroupsRequest() (request *DescribeGroupsRequest) {
request = &DescribeGroupsRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DescribeGroups")
return
}
func NewDescribeGroupsResponse() (response *DescribeGroupsResponse) {
response = &DescribeGroupsResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DescribeGroups
// 查询所有的图库信息。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DescribeGroups(request *DescribeGroupsRequest) (response *DescribeGroupsResponse, err error) {
return c.DescribeGroupsWithContext(context.Background(), request)
}
// DescribeGroups
// 查询所有的图库信息。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DescribeGroupsWithContext(ctx context.Context, request *DescribeGroupsRequest) (response *DescribeGroupsResponse, err error) {
if request == nil {
request = NewDescribeGroupsRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DescribeGroups require credential")
}
request.SetContext(ctx)
response = NewDescribeGroupsResponse()
err = c.Send(request, response)
return
}
func NewDescribeImagesRequest() (request *DescribeImagesRequest) {
request = &DescribeImagesRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DescribeImages")
return
}
func NewDescribeImagesResponse() (response *DescribeImagesResponse) {
response = &DescribeImagesResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DescribeImages
// 获取指定图片库中的图片列表。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEEMPTY = "InvalidParameterValue.PicNameEmpty"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCEUNAVAILABLE_STOPUSING = "ResourceUnavailable.StopUsing"
func (c *Client) DescribeImages(request *DescribeImagesRequest) (response *DescribeImagesResponse, err error) {
return c.DescribeImagesWithContext(context.Background(), request)
}
// DescribeImages
// 获取指定图片库中的图片列表。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEEMPTY = "InvalidParameterValue.PicNameEmpty"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCEUNAVAILABLE_STOPUSING = "ResourceUnavailable.StopUsing"
func (c *Client) DescribeImagesWithContext(ctx context.Context, request *DescribeImagesRequest) (response *DescribeImagesResponse, err error) {
if request == nil {
request = NewDescribeImagesRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DescribeImages require credential")
}
request.SetContext(ctx)
response = NewDescribeImagesResponse()
err = c.Send(request, response)
return
}
func NewDetectChefDressRequest() (request *DetectChefDressRequest) {
request = &DetectChefDressRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectChefDress")
return
}
func NewDetectChefDressResponse() (response *DetectChefDressResponse) {
response = &DetectChefDressResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectChefDress
// 可对图片中厨师穿戴进行识别,支持厨师服识别,厨师帽识别,赤膊识别和口罩识别,可应用于明厨亮灶场景。
//
// "被优选过滤"标签值在人体优选开关开启时才会返回。
//
// 厨师服:厨师服定义为白色上衣
//
// 厨师服识别(酒店版):厨师服定义为红色,白色,黑色上衣
//
//
//
// |序号 | 标签名称 | 标签值 |
//
// | :-----| :---------- |:----------------- |
//
// | 1 | 厨师服识别<div style="width: 70pt"> |无厨师服、有厨师服、被优选过滤|
//
// | 2 | 厨师服识别(酒店版)<div style="width: 70pt"> |无厨师服、有厨师服、被优选过滤|
//
// | 3 | 厨师帽识别<div style="width: 70pt"> |无厨师帽、有厨师帽、被优选过滤 |
//
// | 4 | 赤膊识别<div style="width: 70pt"> |非赤膊、赤膊、被优选过滤|
//
// | 5 | 口罩识别<div style="width: 70pt"> |无口罩、有口罩、口罩不确定、被优选过滤 |
//
// 可能返回的错误码:
// FAILEDOPERATION_DOWNLOADERROR = "FailedOperation.DownLoadError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_NOBODYINPHOTO = "FailedOperation.NoBodyInPhoto"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_IMAGEEMPTY = "InvalidParameterValue.ImageEmpty"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectChefDress(request *DetectChefDressRequest) (response *DetectChefDressResponse, err error) {
return c.DetectChefDressWithContext(context.Background(), request)
}
// DetectChefDress
// 可对图片中厨师穿戴进行识别,支持厨师服识别,厨师帽识别,赤膊识别和口罩识别,可应用于明厨亮灶场景。
//
// "被优选过滤"标签值在人体优选开关开启时才会返回。
//
// 厨师服:厨师服定义为白色上衣
//
// 厨师服识别(酒店版):厨师服定义为红色,白色,黑色上衣
//
//
//
// |序号 | 标签名称 | 标签值 |
//
// | :-----| :---------- |:----------------- |
//
// | 1 | 厨师服识别<div style="width: 70pt"> |无厨师服、有厨师服、被优选过滤|
//
// | 2 | 厨师服识别(酒店版)<div style="width: 70pt"> |无厨师服、有厨师服、被优选过滤|
//
// | 3 | 厨师帽识别<div style="width: 70pt"> |无厨师帽、有厨师帽、被优选过滤 |
//
// | 4 | 赤膊识别<div style="width: 70pt"> |非赤膊、赤膊、被优选过滤|
//
// | 5 | 口罩识别<div style="width: 70pt"> |无口罩、有口罩、口罩不确定、被优选过滤 |
//
// 可能返回的错误码:
// FAILEDOPERATION_DOWNLOADERROR = "FailedOperation.DownLoadError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_NOBODYINPHOTO = "FailedOperation.NoBodyInPhoto"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_IMAGEEMPTY = "InvalidParameterValue.ImageEmpty"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectChefDressWithContext(ctx context.Context, request *DetectChefDressRequest) (response *DetectChefDressResponse, err error) {
if request == nil {
request = NewDetectChefDressRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectChefDress require credential")
}
request.SetContext(ctx)
response = NewDetectChefDressResponse()
err = c.Send(request, response)
return
}
func NewDetectDisgustRequest() (request *DetectDisgustRequest) {
request = &DetectDisgustRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectDisgust")
return
}
func NewDetectDisgustResponse() (response *DetectDisgustResponse) {
response = &DetectDisgustResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectDisgust
// 输入一张图片,返回AI针对一张图片是否是恶心的一系列判断值。
//
//
//
// 通过恶心图片识别, 可以判断一张图片是否令人恶心, 同时给出它属于的潜在类别, 让您能够过滤掉使人不愉快的图片。
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectDisgust(request *DetectDisgustRequest) (response *DetectDisgustResponse, err error) {
return c.DetectDisgustWithContext(context.Background(), request)
}
// DetectDisgust
// 输入一张图片,返回AI针对一张图片是否是恶心的一系列判断值。
//
//
//
// 通过恶心图片识别, 可以判断一张图片是否令人恶心, 同时给出它属于的潜在类别, 让您能够过滤掉使人不愉快的图片。
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectDisgustWithContext(ctx context.Context, request *DetectDisgustRequest) (response *DetectDisgustResponse, err error) {
if request == nil {
request = NewDetectDisgustRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectDisgust require credential")
}
request.SetContext(ctx)
response = NewDetectDisgustResponse()
err = c.Send(request, response)
return
}
func NewDetectEnvelopeRequest() (request *DetectEnvelopeRequest) {
request = &DetectEnvelopeRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectEnvelope")
return
}
func NewDetectEnvelopeResponse() (response *DetectEnvelopeResponse) {
response = &DetectEnvelopeResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectEnvelope
// 文件封识别可检测图片中是否包含符合文件封(即文件、单据、资料等的袋状包装)特征的物品,覆盖顺丰快递文件封、文件袋、档案袋等多种文件封类型,可应用于物流行业对文件快递的包装审核等场景。
//
//
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectEnvelope(request *DetectEnvelopeRequest) (response *DetectEnvelopeResponse, err error) {
return c.DetectEnvelopeWithContext(context.Background(), request)
}
// DetectEnvelope
// 文件封识别可检测图片中是否包含符合文件封(即文件、单据、资料等的袋状包装)特征的物品,覆盖顺丰快递文件封、文件袋、档案袋等多种文件封类型,可应用于物流行业对文件快递的包装审核等场景。
//
//
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectEnvelopeWithContext(ctx context.Context, request *DetectEnvelopeRequest) (response *DetectEnvelopeResponse, err error) {
if request == nil {
request = NewDetectEnvelopeRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectEnvelope require credential")
}
request.SetContext(ctx)
response = NewDetectEnvelopeResponse()
err = c.Send(request, response)
return
}
func NewDetectLabelRequest() (request *DetectLabelRequest) {
request = &DetectLabelRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectLabel")
return
}
func NewDetectLabelResponse() (response *DetectLabelResponse) {
response = &DetectLabelResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectLabel
// 图像标签利用深度学习技术,可以对图片进行智能分类、物体识别等。
//
//
//
// 目前支持八个大类、六十多个子类、数千个标签,涵盖各种日常场景、动植物、物品、美食等。
//
//
//
// 图像标签提供四个版本供选择:
//
//
//
// • 摄像头版:针对搜索、手机摄像头照片进行优化,涵盖大量卡证、日常物品、二维码条形码。
//
//
//
// • 相册版:针对手机相册、网盘进行优化,去除相册和网盘中不常见的标签,针对相册常见图片类型(人像、日常活动、日常物品等)识别效果更好。
//
//
//
// • 网络版:针对网络图片进行优化,涵盖标签更多,满足长尾识别需求。
//
//
//
// • 新闻版:针对新闻、资讯、广电等行业进行优化,增加定制识别,支持万级图像标签。
//
//
//
// 为了方便使用、减少图片传输次数,图像标签将不同版本包装成多合一接口,实际上是多个服务,分别计费。建议在接入初期,对四个版本进行对比评估后选择合适的版本使用。
//
//
//
// >?
//
// - 图像标签已升级服务,建议使用新版接口[通用图像标签](https://cloud.tencent.com/document/product/865/75196)。
//
// - 图像标签摄像头版、相册版、网络版、新闻版分别按照各自的实际使用次数进行收费,例如一张图片同时使用相册版、摄像头版,则按照两次调用计费。建议测试对比后从中选择一个最合适的版本使用即可。
//
//
//
// >
//
// - 可前往 [图像标签](https://cloud.tencent.com/document/product/1588) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEDOWNLOADERROR = "FailedOperation.ImageDownloadError"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectLabel(request *DetectLabelRequest) (response *DetectLabelResponse, err error) {
return c.DetectLabelWithContext(context.Background(), request)
}
// DetectLabel
// 图像标签利用深度学习技术,可以对图片进行智能分类、物体识别等。
//
//
//
// 目前支持八个大类、六十多个子类、数千个标签,涵盖各种日常场景、动植物、物品、美食等。
//
//
//
// 图像标签提供四个版本供选择:
//
//
//
// • 摄像头版:针对搜索、手机摄像头照片进行优化,涵盖大量卡证、日常物品、二维码条形码。
//
//
//
// • 相册版:针对手机相册、网盘进行优化,去除相册和网盘中不常见的标签,针对相册常见图片类型(人像、日常活动、日常物品等)识别效果更好。
//
//
//
// • 网络版:针对网络图片进行优化,涵盖标签更多,满足长尾识别需求。
//
//
//
// • 新闻版:针对新闻、资讯、广电等行业进行优化,增加定制识别,支持万级图像标签。
//
//
//
// 为了方便使用、减少图片传输次数,图像标签将不同版本包装成多合一接口,实际上是多个服务,分别计费。建议在接入初期,对四个版本进行对比评估后选择合适的版本使用。
//
//
//
// >?
//
// - 图像标签已升级服务,建议使用新版接口[通用图像标签](https://cloud.tencent.com/document/product/865/75196)。
//
// - 图像标签摄像头版、相册版、网络版、新闻版分别按照各自的实际使用次数进行收费,例如一张图片同时使用相册版、摄像头版,则按照两次调用计费。建议测试对比后从中选择一个最合适的版本使用即可。
//
//
//
// >
//
// - 可前往 [图像标签](https://cloud.tencent.com/document/product/1588) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEDOWNLOADERROR = "FailedOperation.ImageDownloadError"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectLabelWithContext(ctx context.Context, request *DetectLabelRequest) (response *DetectLabelResponse, err error) {
if request == nil {
request = NewDetectLabelRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectLabel require credential")
}
request.SetContext(ctx)
response = NewDetectLabelResponse()
err = c.Send(request, response)
return
}
func NewDetectLabelBetaRequest() (request *DetectLabelBetaRequest) {
request = &DetectLabelBetaRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectLabelBeta")
return
}
func NewDetectLabelBetaResponse() (response *DetectLabelBetaResponse) {
response = &DetectLabelBetaResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectLabelBeta
// 图像标签测试接口
//
//
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectLabelBeta(request *DetectLabelBetaRequest) (response *DetectLabelBetaResponse, err error) {
return c.DetectLabelBetaWithContext(context.Background(), request)
}
// DetectLabelBeta
// 图像标签测试接口
//
//
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectLabelBetaWithContext(ctx context.Context, request *DetectLabelBetaRequest) (response *DetectLabelBetaResponse, err error) {
if request == nil {
request = NewDetectLabelBetaRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectLabelBeta require credential")
}
request.SetContext(ctx)
response = NewDetectLabelBetaResponse()
err = c.Send(request, response)
return
}
func NewDetectLabelProRequest() (request *DetectLabelProRequest) {
request = &DetectLabelProRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectLabelPro")
return
}
func NewDetectLabelProResponse() (response *DetectLabelProResponse) {
response = &DetectLabelProResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectLabelPro
// 通用图像标签可识别数千种常见物体或场景,覆盖日常物品、场景、动物、植物、食物、饮品、交通工具等多个大类,返回主体的标签名称和所属细分类目等。
//
//
//
// >
//
// - 可前往 [图像标签](https://cloud.tencent.com/document/product/1588) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEDOWNLOADERROR = "FailedOperation.ImageDownloadError"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectLabelPro(request *DetectLabelProRequest) (response *DetectLabelProResponse, err error) {
return c.DetectLabelProWithContext(context.Background(), request)
}
// DetectLabelPro
// 通用图像标签可识别数千种常见物体或场景,覆盖日常物品、场景、动物、植物、食物、饮品、交通工具等多个大类,返回主体的标签名称和所属细分类目等。
//
//
//
// >
//
// - 可前往 [图像标签](https://cloud.tencent.com/document/product/1588) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEDOWNLOADERROR = "FailedOperation.ImageDownloadError"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectLabelProWithContext(ctx context.Context, request *DetectLabelProRequest) (response *DetectLabelProResponse, err error) {
if request == nil {
request = NewDetectLabelProRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectLabelPro require credential")
}
request.SetContext(ctx)
response = NewDetectLabelProResponse()
err = c.Send(request, response)
return
}
func NewDetectMisbehaviorRequest() (request *DetectMisbehaviorRequest) {
request = &DetectMisbehaviorRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectMisbehavior")
return
}
func NewDetectMisbehaviorResponse() (response *DetectMisbehaviorResponse) {
response = &DetectMisbehaviorResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectMisbehavior
// 可以识别输入的图片中是否包含不良行为,例如打架斗殴、赌博、抽烟等,可以应用于广告图、直播截图、短视频截图等审核,减少不良行为对平台内容质量的影响,维护健康向上的互联网环境。
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectMisbehavior(request *DetectMisbehaviorRequest) (response *DetectMisbehaviorResponse, err error) {
return c.DetectMisbehaviorWithContext(context.Background(), request)
}
// DetectMisbehavior
// 可以识别输入的图片中是否包含不良行为,例如打架斗殴、赌博、抽烟等,可以应用于广告图、直播截图、短视频截图等审核,减少不良行为对平台内容质量的影响,维护健康向上的互联网环境。
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// AUTHFAILURE_INVALIDAUTHORIZATION = "AuthFailure.InvalidAuthorization"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectMisbehaviorWithContext(ctx context.Context, request *DetectMisbehaviorRequest) (response *DetectMisbehaviorResponse, err error) {
if request == nil {
request = NewDetectMisbehaviorRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectMisbehavior require credential")
}
request.SetContext(ctx)
response = NewDetectMisbehaviorResponse()
err = c.Send(request, response)
return
}
func NewDetectPetRequest() (request *DetectPetRequest) {
request = &DetectPetRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectPet")
return
}
func NewDetectPetResponse() (response *DetectPetResponse) {
response = &DetectPetResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectPet
// 传入一张图片,识别出图片中是否存在宠物
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_NOOBJECTDETECTED = "FailedOperation.NoObjectDetected"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectPet(request *DetectPetRequest) (response *DetectPetResponse, err error) {
return c.DetectPetWithContext(context.Background(), request)
}
// DetectPet
// 传入一张图片,识别出图片中是否存在宠物
//
// >
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_NOOBJECTDETECTED = "FailedOperation.NoObjectDetected"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectPetWithContext(ctx context.Context, request *DetectPetRequest) (response *DetectPetResponse, err error) {
if request == nil {
request = NewDetectPetRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectPet require credential")
}
request.SetContext(ctx)
response = NewDetectPetResponse()
err = c.Send(request, response)
return
}
func NewDetectProductRequest() (request *DetectProductRequest) {
request = &DetectProductRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectProduct")
return
}
func NewDetectProductResponse() (response *DetectProductResponse) {
response = &DetectProductResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectProduct
// 本接口支持识别图片中包含的商品,能够输出商品的品类名称、类别,还可以输出商品在图片中的位置。支持一张图片多个商品的识别。
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectProduct(request *DetectProductRequest) (response *DetectProductResponse, err error) {
return c.DetectProductWithContext(context.Background(), request)
}
// DetectProduct
// 本接口支持识别图片中包含的商品,能够输出商品的品类名称、类别,还可以输出商品在图片中的位置。支持一张图片多个商品的识别。
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) DetectProductWithContext(ctx context.Context, request *DetectProductRequest) (response *DetectProductResponse, err error) {
if request == nil {
request = NewDetectProductRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectProduct require credential")
}
request.SetContext(ctx)
response = NewDetectProductResponse()
err = c.Send(request, response)
return
}
func NewDetectSecurityRequest() (request *DetectSecurityRequest) {
request = &DetectSecurityRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "DetectSecurity")
return
}
func NewDetectSecurityResponse() (response *DetectSecurityResponse) {
response = &DetectSecurityResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// DetectSecurity
// 安全属性识别可对图片中人体安全防护属性进行识别,支持识别安全帽,反光衣,护目镜,工服,手套,工地安全带,口罩,抽烟,玩手机等多种属性。
//
// "被优选过滤"标签值在人体优选开关开启时才会返回。
//
//
//
// |序号 | 标签名称 | 标签值 |
//
// | :-----| :---------- |:----------------- |
//
// | 1 | 安全帽识别<div style="width: 70pt"> |无安全帽、有安全帽、被优选过滤|
//
// | 2 | 玩手机识别<div style="width: 70pt"> |没有电话、打电话、玩手机、被优选过滤|
//
// | 3 | 抽烟识别<div style="width: 70pt"> |没有抽烟、抽烟、被优选过滤 |
//
// | 4 | 口罩识别<div style="width: 70pt"> |无口罩、有口罩、口罩不确定、被优选过滤|
//
// | 5 | 工地安全带识别<div style="width: 70pt"> |无工地安全带、工地安全带、被优选过滤 |
//
// | 6 | 手套识别<div style="width: 70pt"> |无手套、有手套、手套不确定、被优选过滤 |
//
// | 7 | 工服识别<div style="width: 70pt"> |无工服、有工服、被优选过滤|
//
// | 8 | 护目镜识别<div style="width: 70pt"> |无护目镜、有护目镜、被优选过滤|
//
// | 9 | 反光衣识别<div style="width: 70pt"> |无反光衣、有反光衣、被优选过滤|
//
// 可能返回的错误码:
// FAILEDOPERATION_DOWNLOADERROR = "FailedOperation.DownLoadError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_NOBODYINPHOTO = "FailedOperation.NoBodyInPhoto"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_IMAGEEMPTY = "InvalidParameterValue.ImageEmpty"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectSecurity(request *DetectSecurityRequest) (response *DetectSecurityResponse, err error) {
return c.DetectSecurityWithContext(context.Background(), request)
}
// DetectSecurity
// 安全属性识别可对图片中人体安全防护属性进行识别,支持识别安全帽,反光衣,护目镜,工服,手套,工地安全带,口罩,抽烟,玩手机等多种属性。
//
// "被优选过滤"标签值在人体优选开关开启时才会返回。
//
//
//
// |序号 | 标签名称 | 标签值 |
//
// | :-----| :---------- |:----------------- |
//
// | 1 | 安全帽识别<div style="width: 70pt"> |无安全帽、有安全帽、被优选过滤|
//
// | 2 | 玩手机识别<div style="width: 70pt"> |没有电话、打电话、玩手机、被优选过滤|
//
// | 3 | 抽烟识别<div style="width: 70pt"> |没有抽烟、抽烟、被优选过滤 |
//
// | 4 | 口罩识别<div style="width: 70pt"> |无口罩、有口罩、口罩不确定、被优选过滤|
//
// | 5 | 工地安全带识别<div style="width: 70pt"> |无工地安全带、工地安全带、被优选过滤 |
//
// | 6 | 手套识别<div style="width: 70pt"> |无手套、有手套、手套不确定、被优选过滤 |
//
// | 7 | 工服识别<div style="width: 70pt"> |无工服、有工服、被优选过滤|
//
// | 8 | 护目镜识别<div style="width: 70pt"> |无护目镜、有护目镜、被优选过滤|
//
// | 9 | 反光衣识别<div style="width: 70pt"> |无反光衣、有反光衣、被优选过滤|
//
// 可能返回的错误码:
// FAILEDOPERATION_DOWNLOADERROR = "FailedOperation.DownLoadError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_NOBODYINPHOTO = "FailedOperation.NoBodyInPhoto"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_TOOLARGEFILEERROR = "FailedOperation.TooLargeFileError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_IMAGEEMPTY = "InvalidParameterValue.ImageEmpty"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) DetectSecurityWithContext(ctx context.Context, request *DetectSecurityRequest) (response *DetectSecurityResponse, err error) {
if request == nil {
request = NewDetectSecurityRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("DetectSecurity require credential")
}
request.SetContext(ctx)
response = NewDetectSecurityResponse()
err = c.Send(request, response)
return
}
func NewEnhanceImageRequest() (request *EnhanceImageRequest) {
request = &EnhanceImageRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "EnhanceImage")
return
}
func NewEnhanceImageResponse() (response *EnhanceImageResponse) {
response = &EnhanceImageResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// EnhanceImage
// 传入一张图片,输出清晰度提升后的图片。
//
//
//
// 可以消除图片有损压缩导致的噪声,和使用滤镜、拍摄失焦导致的模糊。让图片的边缘和细节更加清晰自然。
//
//
//
// >
//
// - 可前往 [图像处理](https://cloud.tencent.com/document/product/1590) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) EnhanceImage(request *EnhanceImageRequest) (response *EnhanceImageResponse, err error) {
return c.EnhanceImageWithContext(context.Background(), request)
}
// EnhanceImage
// 传入一张图片,输出清晰度提升后的图片。
//
//
//
// 可以消除图片有损压缩导致的噪声,和使用滤镜、拍摄失焦导致的模糊。让图片的边缘和细节更加清晰自然。
//
//
//
// >
//
// - 可前往 [图像处理](https://cloud.tencent.com/document/product/1590) 产品文档中查看更多产品信息。
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_INVOKECHARGEERROR = "FailedOperation.InvokeChargeError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) EnhanceImageWithContext(ctx context.Context, request *EnhanceImageRequest) (response *EnhanceImageResponse, err error) {
if request == nil {
request = NewEnhanceImageRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("EnhanceImage require credential")
}
request.SetContext(ctx)
response = NewEnhanceImageResponse()
err = c.Send(request, response)
return
}
func NewRecognizeCarRequest() (request *RecognizeCarRequest) {
request = &RecognizeCarRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "RecognizeCar")
return
}
func NewRecognizeCarResponse() (response *RecognizeCarResponse) {
response = &RecognizeCarResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// RecognizeCar
// 车辆识别可对图片中车辆的车型进行识别,输出车辆的品牌(如路虎)、车系(如神行者2)、类型(如中型SUV)、颜色和车辆在图中的坐标等信息,覆盖轿车、SUV、大型客车等市面常见车,支持三千多种车辆型号。如果图片中存在多辆车,会分别输出每辆车的车型和坐标。
//
//
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_RECOGNIZEFAILDED = "FailedOperation.RecognizeFailded"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) RecognizeCar(request *RecognizeCarRequest) (response *RecognizeCarResponse, err error) {
return c.RecognizeCarWithContext(context.Background(), request)
}
// RecognizeCar
// 车辆识别可对图片中车辆的车型进行识别,输出车辆的品牌(如路虎)、车系(如神行者2)、类型(如中型SUV)、颜色和车辆在图中的坐标等信息,覆盖轿车、SUV、大型客车等市面常见车,支持三千多种车辆型号。如果图片中存在多辆车,会分别输出每辆车的车型和坐标。
//
//
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_RECOGNIZEFAILDED = "FailedOperation.RecognizeFailded"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) RecognizeCarWithContext(ctx context.Context, request *RecognizeCarRequest) (response *RecognizeCarResponse, err error) {
if request == nil {
request = NewRecognizeCarRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("RecognizeCar require credential")
}
request.SetContext(ctx)
response = NewRecognizeCarResponse()
err = c.Send(request, response)
return
}
func NewRecognizeCarProRequest() (request *RecognizeCarProRequest) {
request = &RecognizeCarProRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "RecognizeCarPro")
return
}
func NewRecognizeCarProResponse() (response *RecognizeCarProResponse) {
response = &RecognizeCarProResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// RecognizeCarPro
// 车辆识别(增强版)在车辆识别的基础上**增加了车牌识别的功能,并升级了车型识别的效果**。可对图片中车辆的车型和车牌进行同时识别,输出车辆的车牌信息,以及车辆品牌(如路虎)、车系(如神行者2)、类型(如中型SUV)、颜色和车辆在图中的坐标等信息,覆盖轿车、SUV、大型客车等市面常见车,支持三千多种车辆型号。如果图片中存在多辆车,会分别输出每辆车的车型、车牌和坐标。
//
//
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_RECOGNIZEFAILDED = "FailedOperation.RecognizeFailded"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) RecognizeCarPro(request *RecognizeCarProRequest) (response *RecognizeCarProResponse, err error) {
return c.RecognizeCarProWithContext(context.Background(), request)
}
// RecognizeCarPro
// 车辆识别(增强版)在车辆识别的基础上**增加了车牌识别的功能,并升级了车型识别的效果**。可对图片中车辆的车型和车牌进行同时识别,输出车辆的车牌信息,以及车辆品牌(如路虎)、车系(如神行者2)、类型(如中型SUV)、颜色和车辆在图中的坐标等信息,覆盖轿车、SUV、大型客车等市面常见车,支持三千多种车辆型号。如果图片中存在多辆车,会分别输出每辆车的车型、车牌和坐标。
//
//
//
// >?
//
// - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEUNQUALIFIED = "FailedOperation.ImageUnQualified"
// FAILEDOPERATION_RECOGNIZEFAILDED = "FailedOperation.RecognizeFailded"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNOPENERROR = "FailedOperation.UnOpenError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_INVALIDPARAMETERVALUELIMIT = "InvalidParameterValue.InvalidParameterValueLimit"
// INVALIDPARAMETERVALUE_URLILLEGAL = "InvalidParameterValue.UrlIllegal"
// LIMITEXCEEDED_TOOLARGEFILEERROR = "LimitExceeded.TooLargeFileError"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
// RESOURCESSOLDOUT_CHARGESTATUSEXCEPTION = "ResourcesSoldOut.ChargeStatusException"
func (c *Client) RecognizeCarProWithContext(ctx context.Context, request *RecognizeCarProRequest) (response *RecognizeCarProResponse, err error) {
if request == nil {
request = NewRecognizeCarProRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("RecognizeCarPro require credential")
}
request.SetContext(ctx)
response = NewRecognizeCarProResponse()
err = c.Send(request, response)
return
}
func NewSearchImageRequest() (request *SearchImageRequest) {
request = &SearchImageRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "SearchImage")
return
}
func NewSearchImageResponse() (response *SearchImageResponse) {
response = &SearchImageResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// SearchImage
// 本接口用于对一张图片,在指定图片库中检索出与之相似的图片列表。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
//
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEGROUPCHARGESTATUSCLOSE = "FailedOperation.ImageGroupChargeStatusClose"
// FAILEDOPERATION_IMAGEGROUPEMPTY = "FailedOperation.ImageGroupEmpty"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGERESOLUTIONINSUFFICIENT = "FailedOperation.ImageResolutionInsufficient"
// FAILEDOPERATION_IMAGESEARCHINVALID = "FailedOperation.ImageSearchInvalid"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_IMAGEFORMATNOTSUPPORT = "InvalidParameter.ImageFormatNotSupport"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETER_PICTURESOLIDCOLORERROR = "InvalidParameter.PictureSolidColorError"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_FILTERINVALID = "InvalidParameterValue.FilterInvalid"
// INVALIDPARAMETERVALUE_FILTERSIZEEXCEED = "InvalidParameterValue.FilterSizeExceed"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_LIMITEXCEED = "InvalidParameterValue.LimitExceed"
// MISSINGPARAMETER_ERRORPARAMETEREMPTY = "MissingParameter.ErrorParameterEmpty"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) SearchImage(request *SearchImageRequest) (response *SearchImageResponse, err error) {
return c.SearchImageWithContext(context.Background(), request)
}
// SearchImage
// 本接口用于对一张图片,在指定图片库中检索出与之相似的图片列表。
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
//
//
// 可能返回的错误码:
// FAILEDOPERATION_BALANCEINSUFFICIENT = "FailedOperation.BalanceInsufficient"
// FAILEDOPERATION_EMPTYIMAGEERROR = "FailedOperation.EmptyImageError"
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEGROUPCHARGESTATUSCLOSE = "FailedOperation.ImageGroupChargeStatusClose"
// FAILEDOPERATION_IMAGEGROUPEMPTY = "FailedOperation.ImageGroupEmpty"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGERESOLUTIONEXCEED = "FailedOperation.ImageResolutionExceed"
// FAILEDOPERATION_IMAGERESOLUTIONINSUFFICIENT = "FailedOperation.ImageResolutionInsufficient"
// FAILEDOPERATION_IMAGESEARCHINVALID = "FailedOperation.ImageSearchInvalid"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_INNERERROR = "FailedOperation.InnerError"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// FAILEDOPERATION_UNKNOWERROR = "FailedOperation.UnKnowError"
// FAILEDOPERATION_UNKNOWN = "FailedOperation.Unknown"
// INVALIDPARAMETER_IMAGEFORMATNOTSUPPORT = "InvalidParameter.ImageFormatNotSupport"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETER_PICTURESOLIDCOLORERROR = "InvalidParameter.PictureSolidColorError"
// INVALIDPARAMETERVALUE_ENTITYIDTOOLONG = "InvalidParameterValue.EntityIdTooLong"
// INVALIDPARAMETERVALUE_FILTERINVALID = "InvalidParameterValue.FilterInvalid"
// INVALIDPARAMETERVALUE_FILTERSIZEEXCEED = "InvalidParameterValue.FilterSizeExceed"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_LIMITEXCEED = "InvalidParameterValue.LimitExceed"
// MISSINGPARAMETER_ERRORPARAMETEREMPTY = "MissingParameter.ErrorParameterEmpty"
// REQUESTLIMITEXCEEDED = "RequestLimitExceeded"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_ISOPENING = "ResourceUnavailable.IsOpening"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) SearchImageWithContext(ctx context.Context, request *SearchImageRequest) (response *SearchImageResponse, err error) {
if request == nil {
request = NewSearchImageRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("SearchImage require credential")
}
request.SetContext(ctx)
response = NewSearchImageResponse()
err = c.Send(request, response)
return
}
func NewUpdateImageRequest() (request *UpdateImageRequest) {
request = &UpdateImageRequest{
BaseRequest: &tchttp.BaseRequest{},
}
request.Init().WithApiInfo("tiia", APIVersion, "UpdateImage")
return
}
func NewUpdateImageResponse() (response *UpdateImageResponse) {
response = &UpdateImageResponse{
BaseResponse: &tchttp.BaseResponse{},
}
return
}
// UpdateImage
// 本接口支持根据图库ID、物品ID、图片名称来修改图片信息(暂仅支持修改Tags)
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
//
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEGROUPEMPTY = "FailedOperation.ImageGroupEmpty"
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// INVALIDPARAMETER_IMAGEFORMATNOTSUPPORT = "InvalidParameter.ImageFormatNotSupport"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEEMPTY = "InvalidParameterValue.PicNameEmpty"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// INVALIDPARAMETERVALUE_TAGSKEYSEXCEED = "InvalidParameterValue.TagsKeysExceed"
// INVALIDPARAMETERVALUE_TAGSVALUEILLEGAL = "InvalidParameterValue.TagsValueIllegal"
// INVALIDPARAMETERVALUE_TAGSVALUESIZEEXCEED = "InvalidParameterValue.TagsValueSizeExceed"
// MISSINGPARAMETER_ERRORPARAMETEREMPTY = "MissingParameter.ErrorParameterEmpty"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) UpdateImage(request *UpdateImageRequest) (response *UpdateImageResponse, err error) {
return c.UpdateImageWithContext(context.Background(), request)
}
// UpdateImage
// 本接口支持根据图库ID、物品ID、图片名称来修改图片信息(暂仅支持修改Tags)
//
//
//
// >
//
// - 可前往 [图像搜索](https://cloud.tencent.com/document/product/1589) 产品文档中查看更多产品信息。
//
//
//
// 可能返回的错误码:
// FAILEDOPERATION_IMAGEDECODEFAILED = "FailedOperation.ImageDecodeFailed"
// FAILEDOPERATION_IMAGEGROUPEMPTY = "FailedOperation.ImageGroupEmpty"
// FAILEDOPERATION_IMAGENOTFOUNDINFO = "FailedOperation.ImageNotFoundInfo"
// FAILEDOPERATION_IMAGENOTSUPPORTED = "FailedOperation.ImageNotSupported"
// FAILEDOPERATION_IMAGESIZEEXCEED = "FailedOperation.ImageSizeExceed"
// FAILEDOPERATION_IMAGEURLINVALID = "FailedOperation.ImageUrlInvalid"
// FAILEDOPERATION_REQUESTERROR = "FailedOperation.RequestError"
// FAILEDOPERATION_REQUESTTIMEOUT = "FailedOperation.RequestTimeout"
// FAILEDOPERATION_RPCFAIL = "FailedOperation.RpcFail"
// FAILEDOPERATION_SERVERERROR = "FailedOperation.ServerError"
// INVALIDPARAMETER_IMAGEFORMATNOTSUPPORT = "InvalidParameter.ImageFormatNotSupport"
// INVALIDPARAMETER_INVALIDPARAMETER = "InvalidParameter.InvalidParameter"
// INVALIDPARAMETERVALUE_ENTITYIDEMPTY = "InvalidParameterValue.EntityIdEmpty"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDILLEGAL = "InvalidParameterValue.ImageGroupIdIllegal"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDNOTEXIST = "InvalidParameterValue.ImageGroupIdNotExist"
// INVALIDPARAMETERVALUE_IMAGEGROUPIDTOOLONG = "InvalidParameterValue.ImageGroupIdTooLong"
// INVALIDPARAMETERVALUE_PICNAMEEMPTY = "InvalidParameterValue.PicNameEmpty"
// INVALIDPARAMETERVALUE_PICNAMETOOLONG = "InvalidParameterValue.PicNameTooLong"
// INVALIDPARAMETERVALUE_TAGSKEYSEXCEED = "InvalidParameterValue.TagsKeysExceed"
// INVALIDPARAMETERVALUE_TAGSVALUEILLEGAL = "InvalidParameterValue.TagsValueIllegal"
// INVALIDPARAMETERVALUE_TAGSVALUESIZEEXCEED = "InvalidParameterValue.TagsValueSizeExceed"
// MISSINGPARAMETER_ERRORPARAMETEREMPTY = "MissingParameter.ErrorParameterEmpty"
// RESOURCEUNAVAILABLE_INARREARS = "ResourceUnavailable.InArrears"
// RESOURCEUNAVAILABLE_NOTEXIST = "ResourceUnavailable.NotExist"
func (c *Client) UpdateImageWithContext(ctx context.Context, request *UpdateImageRequest) (response *UpdateImageResponse, err error) {
if request == nil {
request = NewUpdateImageRequest()
}
if c.GetCredential() == nil {
return nil, errors.New("UpdateImage require credential")
}
request.SetContext(ctx)
response = NewUpdateImageResponse()
err = c.Send(request, response)
return
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/tencentcloud/tencentcloud-sdk-go.git
git@gitee.com:tencentcloud/tencentcloud-sdk-go.git
tencentcloud
tencentcloud-sdk-go
tencentcloud-sdk-go
master

Search