Documentation
¶
Index ¶
- Constants
- type AnalyzeFaceRequest
- type AnalyzeFaceResponse
- type Candidate
- type Client
- func (c *Client) AnalyzeFace(request *AnalyzeFaceRequest) (response *AnalyzeFaceResponse, err error)
- func (c *Client) CompareFace(request *CompareFaceRequest) (response *CompareFaceResponse, err error)
- func (c *Client) CopyPerson(request *CopyPersonRequest) (response *CopyPersonResponse, err error)
- func (c *Client) CreateFace(request *CreateFaceRequest) (response *CreateFaceResponse, err error)
- func (c *Client) CreateGroup(request *CreateGroupRequest) (response *CreateGroupResponse, err error)
- func (c *Client) CreatePerson(request *CreatePersonRequest) (response *CreatePersonResponse, err error)
- func (c *Client) DeleteFace(request *DeleteFaceRequest) (response *DeleteFaceResponse, err error)
- func (c *Client) DeleteGroup(request *DeleteGroupRequest) (response *DeleteGroupResponse, err error)
- func (c *Client) DeletePerson(request *DeletePersonRequest) (response *DeletePersonResponse, err error)
- func (c *Client) DeletePersonFromGroup(request *DeletePersonFromGroupRequest) (response *DeletePersonFromGroupResponse, err error)
- func (c *Client) DetectFace(request *DetectFaceRequest) (response *DetectFaceResponse, err error)
- func (c *Client) DetectLiveFace(request *DetectLiveFaceRequest) (response *DetectLiveFaceResponse, err error)
- func (c *Client) GetGroupList(request *GetGroupListRequest) (response *GetGroupListResponse, err error)
- func (c *Client) GetPersonBaseInfo(request *GetPersonBaseInfoRequest) (response *GetPersonBaseInfoResponse, err error)
- func (c *Client) GetPersonGroupInfo(request *GetPersonGroupInfoRequest) (response *GetPersonGroupInfoResponse, err error)
- func (c *Client) GetPersonList(request *GetPersonListRequest) (response *GetPersonListResponse, err error)
- func (c *Client) GetPersonListNum(request *GetPersonListNumRequest) (response *GetPersonListNumResponse, err error)
- func (c *Client) ModifyGroup(request *ModifyGroupRequest) (response *ModifyGroupResponse, err error)
- func (c *Client) ModifyPersonBaseInfo(request *ModifyPersonBaseInfoRequest) (response *ModifyPersonBaseInfoResponse, err error)
- func (c *Client) ModifyPersonGroupInfo(request *ModifyPersonGroupInfoRequest) (response *ModifyPersonGroupInfoResponse, err error)
- func (c *Client) SearchFaces(request *SearchFacesRequest) (response *SearchFacesResponse, err error)
- func (c *Client) SearchFacesReturnsByGroup(request *SearchFacesReturnsByGroupRequest) (response *SearchFacesReturnsByGroupResponse, err error)
- func (c *Client) SearchPersons(request *SearchPersonsRequest) (response *SearchPersonsResponse, err error)
- func (c *Client) SearchPersonsReturnsByGroup(request *SearchPersonsReturnsByGroupRequest) (response *SearchPersonsReturnsByGroupResponse, err error)
- func (c *Client) VerifyFace(request *VerifyFaceRequest) (response *VerifyFaceResponse, err error)
- func (c *Client) VerifyPerson(request *VerifyPersonRequest) (response *VerifyPersonResponse, err error)
- type CompareFaceRequest
- type CompareFaceResponse
- type CopyPersonRequest
- type CopyPersonResponse
- type CreateFaceRequest
- type CreateFaceResponse
- type CreateGroupRequest
- type CreateGroupResponse
- type CreatePersonRequest
- type CreatePersonResponse
- type DeleteFaceRequest
- type DeleteFaceResponse
- type DeleteGroupRequest
- type DeleteGroupResponse
- type DeletePersonFromGroupRequest
- type DeletePersonFromGroupResponse
- type DeletePersonRequest
- type DeletePersonResponse
- type DetectFaceRequest
- type DetectFaceResponse
- type DetectLiveFaceRequest
- type DetectLiveFaceResponse
- type FaceAttributesInfo
- type FaceHairAttributesInfo
- type FaceInfo
- type FaceQualityCompleteness
- type FaceQualityInfo
- type FaceRect
- type FaceShape
- type GetGroupListRequest
- type GetGroupListResponse
- type GetPersonBaseInfoRequest
- type GetPersonBaseInfoResponse
- type GetPersonGroupInfoRequest
- type GetPersonGroupInfoResponse
- type GetPersonListNumRequest
- type GetPersonListNumResponse
- type GetPersonListRequest
- type GetPersonListResponse
- type GroupCandidate
- type GroupExDescriptionInfo
- type GroupInfo
- type ModifyGroupRequest
- type ModifyGroupResponse
- type ModifyPersonBaseInfoRequest
- type ModifyPersonBaseInfoResponse
- type ModifyPersonGroupInfoRequest
- type ModifyPersonGroupInfoResponse
- type PersonExDescriptionInfo
- type PersonGroupInfo
- type PersonInfo
- type Point
- type Result
- type ResultsReturnsByGroup
- type SearchFacesRequest
- type SearchFacesResponse
- type SearchFacesReturnsByGroupRequest
- type SearchFacesReturnsByGroupResponse
- type SearchPersonsRequest
- type SearchPersonsResponse
- type SearchPersonsReturnsByGroupRequest
- type SearchPersonsReturnsByGroupResponse
- type VerifyFaceRequest
- type VerifyFaceResponse
- type VerifyPersonRequest
- type VerifyPersonResponse
Constants ¶
const APIVersion = "2018-03-01"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnalyzeFaceRequest ¶
type AnalyzeFaceRequest struct {
*tchttp.BaseRequest
// 检测模式。0 为检测所有出现的人脸, 1 为检测面积最大的人脸。默认为 0。最多返回 10 张人脸的五官定位(人脸关键点)具体信息。
Mode *uint64 `json:"Mode,omitempty" name:"Mode"`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 人脸识别服务所用的算法模型版本。目前入参支持 “2.0”和“3.0“ 两个输入。
// 默认为"2.0"。
// 不同算法模型版本对应的人脸识别算法不同,新版本的整体效果会优于旧版本,建议使用最新版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
}
func NewAnalyzeFaceRequest ¶
func NewAnalyzeFaceRequest() (request *AnalyzeFaceRequest)
func (*AnalyzeFaceRequest) FromJsonString ¶
func (r *AnalyzeFaceRequest) FromJsonString(s string) error
func (*AnalyzeFaceRequest) ToJsonString ¶
func (r *AnalyzeFaceRequest) ToJsonString() string
type AnalyzeFaceResponse ¶
type AnalyzeFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 请求的图片宽度。
ImageWidth *uint64 `json:"ImageWidth,omitempty" name:"ImageWidth"`
// 请求的图片高度。
ImageHeight *uint64 `json:"ImageHeight,omitempty" name:"ImageHeight"`
// 五官定位(人脸关键点)具体信息。
FaceShapeSet []*FaceShape `json:"FaceShapeSet,omitempty" name:"FaceShapeSet" list`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewAnalyzeFaceResponse ¶
func NewAnalyzeFaceResponse() (response *AnalyzeFaceResponse)
func (*AnalyzeFaceResponse) FromJsonString ¶
func (r *AnalyzeFaceResponse) FromJsonString(s string) error
func (*AnalyzeFaceResponse) ToJsonString ¶
func (r *AnalyzeFaceResponse) ToJsonString() string
type Candidate ¶
type Candidate struct {
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 人脸ID
FaceId *string `json:"FaceId,omitempty" name:"FaceId"`
// 候选者的匹配得分。
//
// 1万大小人脸底库下,误识率百分之一对应分数为70分,误识率千分之一对应分数为80分,误识率万分之一对应分数为90分;
// 10万大小人脸底库下,误识率百分之一对应分数为80分,误识率千分之一对应分数为90分,误识率万分之一对应分数为100分;
// 30万大小人脸底库下,误识率百分之一对应分数为85分,误识率千分之一对应分数为95分。
//
// 一般80分左右可适用大部分场景,建议分数不要超过90分。您可以根据实际情况选择合适的分数。
Score *float64 `json:"Score,omitempty" name:"Score"`
// 人员名称
// 注意:此字段可能返回 null,表示取不到有效值。
PersonName *string `json:"PersonName,omitempty" name:"PersonName"`
// 人员性别
// 注意:此字段可能返回 null,表示取不到有效值。
Gender *int64 `json:"Gender,omitempty" name:"Gender"`
// 包含此人员的人员库及描述字段内容列表
// 注意:此字段可能返回 null,表示取不到有效值。
PersonGroupInfos []*PersonGroupInfo `json:"PersonGroupInfos,omitempty" name:"PersonGroupInfos" list`
}
type Client ¶
func NewClient ¶
func NewClient(credential *common.Credential, region string, clientProfile *profile.ClientProfile) (client *Client, err error)
func NewClientWithSecretId ¶
Deprecated
func (*Client) AnalyzeFace ¶
func (c *Client) AnalyzeFace(request *AnalyzeFaceRequest) (response *AnalyzeFaceResponse, err error)
对请求图片进行五官定位(也称人脸关键点定位),计算构成人脸轮廓的 90 个点,包括眉毛(左右各 8 点)、眼睛(左右各 8 点)、鼻子(13 点)、嘴巴(22 点)、脸型轮廓(21 点)、眼珠[或瞳孔](2点)。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) CompareFace ¶
func (c *Client) CompareFace(request *CompareFaceRequest) (response *CompareFaceResponse, err error)
对两张图片中的人脸进行相似度比对,返回人脸相似度分数。
若您需要判断 “此人是否是某人”,即验证某张图片中的人是否是已知身份的某人,如常见的人脸登录场景,建议使用[人脸验证](https://cloud.tencent.com/document/product/867/32806)接口。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) CopyPerson ¶
func (c *Client) CopyPerson(request *CopyPersonRequest) (response *CopyPersonResponse, err error)
将已存在于某人员库的人员复制到其他人员库,该人员的描述信息不会被复制。单个人员最多只能同时存在100个人员库中。 > - 注:若该人员创建时算法模型版本为2.0,复制到非2.0算法模型版本的Group中时,复制操作将会失败。
func (*Client) CreateFace ¶
func (c *Client) CreateFace(request *CreateFaceRequest) (response *CreateFaceResponse, err error)
将一组人脸图片添加到一个人员中。一个人员最多允许包含 5 张图片。若该人员存在多个人员库中,所有人员库中该人员图片均会增加。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) CreateGroup ¶
func (c *Client) CreateGroup(request *CreateGroupRequest) (response *CreateGroupResponse, err error)
用于创建一个空的人员库,如果人员库已存在返回错误。可根据需要创建自定义描述字段,用于辅助描述该人员库下的人员信息。1个APPID下最多创建2万个人员库(Group)、最多包含1000万张人脸(Face),单个人员库(Group)最多包含100万张人脸(Face)。
func (*Client) CreatePerson ¶
func (c *Client) CreatePerson(request *CreatePersonRequest) (response *CreatePersonResponse, err error)
创建人员,添加人脸、姓名、性别及其他相关信息。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) DeleteFace ¶
func (c *Client) DeleteFace(request *DeleteFaceRequest) (response *DeleteFaceResponse, err error)
删除一个人员下的人脸图片。如果该人员只有一张人脸图片,则返回错误。
func (*Client) DeleteGroup ¶
func (c *Client) DeleteGroup(request *DeleteGroupRequest) (response *DeleteGroupResponse, err error)
删除该人员库及包含的所有的人员。同时,人员对应的所有人脸信息将被删除。若某人员同时存在多个人员库中,该人员不会被删除,但属于该人员库中的自定义描述字段信息会被删除,属于其他人员库的自定义描述字段信息不受影响。
> - 删除人员库的操作为异步执行,删除单张人脸时间约为10ms,即一小时内可以删除36万张。删除期间,无法向该人员库添加人员。
func (*Client) DeletePerson ¶
func (c *Client) DeletePerson(request *DeletePersonRequest) (response *DeletePersonResponse, err error)
删除该人员信息,此操作会导致所有人员库均删除此人员。同时,该人员的所有人脸信息将被删除。
func (*Client) DeletePersonFromGroup ¶
func (c *Client) DeletePersonFromGroup(request *DeletePersonFromGroupRequest) (response *DeletePersonFromGroupResponse, err error)
从某人员库中删除人员,此操作仅影响该人员库。若该人员仅存在于指定的人员库中,该人员将被删除,其所有的人脸信息也将被删除。
func (*Client) DetectFace ¶
func (c *Client) DetectFace(request *DetectFaceRequest) (response *DetectFaceResponse, err error)
检测给定图片中的人脸(Face)的位置、相应的面部属性和人脸质量信息,位置包括 (x,y,w,h),面部属性包括性别(gender)、年龄(age)、表情(expression)、魅力(beauty)、眼镜(glass)、发型(hair)、口罩(mask)和姿态 (pitch,roll,yaw),人脸质量信息包括整体质量分(score)、模糊分(sharpness)、光照分(brightness)和五官遮挡分(completeness)。
其中,人脸质量信息主要用于评价输入的人脸图片的质量。在使用人脸识别服务时,建议您对输入的人脸图片进行质量检测,提升后续业务处理的效果。该功能的应用场景包括:
1) 人员库[创建人员](https://cloud.tencent.com/document/product/867/32793)/[增加人脸](https://cloud.tencent.com/document/product/867/32795):保证人员人脸信息的质量,便于后续的业务处理。
2) [人脸搜索](https://cloud.tencent.com/document/product/867/32798):保证输入的图片质量,快速准确匹配到对应的人员。
3) [人脸验证](https://cloud.tencent.com/document/product/867/32806):保证人脸信息的质量,避免明明是本人却认证不通过的情况。
4) [人脸融合](https://cloud.tencent.com/product/facefusion):保证上传的人脸质量,人脸融合的效果更好。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) DetectLiveFace ¶
func (c *Client) DetectLiveFace(request *DetectLiveFaceRequest) (response *DetectLiveFaceResponse, err error)
用于对用户上传的静态图片进行人脸活体检测。与动态活体检测的区别是:静态活体检测中,用户不需要通过唇语或摇头眨眼等动作来识别。
静态活体检测适用于手机自拍的场景,或对防攻击要求不高的场景。如果对活体检测有更高安全性要求,请使用[人脸核身·云智慧眼](https://cloud.tencent.com/product/faceid)产品。
> - 图片的宽高比请接近3:4,不符合宽高比的图片返回的分值不具备参考意义。本接口适用于类手机自拍场景,非类手机自拍照返回的分值不具备参考意义。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) GetGroupList ¶
func (c *Client) GetGroupList(request *GetGroupListRequest) (response *GetGroupListResponse, err error)
获取人员库列表。
func (*Client) GetPersonBaseInfo ¶
func (c *Client) GetPersonBaseInfo(request *GetPersonBaseInfoRequest) (response *GetPersonBaseInfoResponse, err error)
获取指定人员的信息,包括姓名、性别、人脸等。
func (*Client) GetPersonGroupInfo ¶
func (c *Client) GetPersonGroupInfo(request *GetPersonGroupInfoRequest) (response *GetPersonGroupInfoResponse, err error)
获取指定人员的信息,包括加入的人员库、描述内容等。
func (*Client) GetPersonList ¶
func (c *Client) GetPersonList(request *GetPersonListRequest) (response *GetPersonListResponse, err error)
获取指定人员库中的人员列表。
func (*Client) GetPersonListNum ¶
func (c *Client) GetPersonListNum(request *GetPersonListNumRequest) (response *GetPersonListNumResponse, err error)
获取指定人员库中人员数量。
func (*Client) ModifyGroup ¶
func (c *Client) ModifyGroup(request *ModifyGroupRequest) (response *ModifyGroupResponse, err error)
修改人员库名称、备注、自定义描述字段名称。
func (*Client) ModifyPersonBaseInfo ¶
func (c *Client) ModifyPersonBaseInfo(request *ModifyPersonBaseInfoRequest) (response *ModifyPersonBaseInfoResponse, err error)
修改人员信息,包括名称、性别等。人员名称和性别修改会同步到包含该人员的所有人员库。
func (*Client) ModifyPersonGroupInfo ¶
func (c *Client) ModifyPersonGroupInfo(request *ModifyPersonGroupInfoRequest) (response *ModifyPersonGroupInfoResponse, err error)
修改指定人员库人员描述内容。
func (*Client) SearchFaces ¶
func (c *Client) SearchFaces(request *SearchFacesRequest) (response *SearchFacesResponse, err error)
用于对一张待识别的人脸图片,在一个或多个人员库中识别出最相似的 TopN 人员,识别结果按照相似度从大到小排序。单次搜索的人员库人脸总数量不得超过 100 万张。 此接口需与[人员库管理相关接口](https://cloud.tencent.com/document/product/867/32794)结合使用。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) SearchFacesReturnsByGroup ¶
func (c *Client) SearchFacesReturnsByGroup(request *SearchFacesReturnsByGroupRequest) (response *SearchFacesReturnsByGroupResponse, err error)
用于对一张待识别的人脸图片,在一个或多个人员库中识别出最相似的 TopN 人员,按照人员库的维度以人员相似度从大到小顺序排列。 此接口需与[人员库管理相关接口](https://cloud.tencent.com/document/product/867/32794)结合使用。
func (*Client) SearchPersons ¶
func (c *Client) SearchPersons(request *SearchPersonsRequest) (response *SearchPersonsResponse, err error)
用于对一张待识别的人脸图片,在一个或多个人员库中识别出最相似的 TopN 人员,按照相似度从大到小排列。
本接口会将该人员(Person)下的所有人脸(Face)进行融合特征处理,即若某个 Person 下有4张 Face ,本接口会将4张 Face 的特征进行融合处理,生成对应这个 Person 的特征,使人员搜索(确定待识别的人脸图片是某人)更加准确。
人员搜索接口和人脸搜索接口的区别是:人脸搜索会比对该 Person 下所有 Face ,而人员搜索比对的是该 Person 的 Person 特征。 > - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) SearchPersonsReturnsByGroup ¶
func (c *Client) SearchPersonsReturnsByGroup(request *SearchPersonsReturnsByGroupRequest) (response *SearchPersonsReturnsByGroupResponse, err error)
用于对一张待识别的人脸图片,在一个或多个人员库中识别出最相似的 TopN 人员,按照人员库的维度以人员相似度从大到小顺序排列。
本接口会将该人员(Person)下的所有人脸(Face)进行融合特征处理,即若某个Person下有4张 Face,本接口会将4张 Face 的特征进行融合处理,生成对应这个 Person 的特征,使人员搜索(确定待识别的人脸图片是某人员)更加准确。
人员搜索和人脸搜索的区别是:人脸搜索比对该 Person 下所有 Face ,而人员搜索比对的是该 Person 的 Person 特征。
func (*Client) VerifyFace ¶
func (c *Client) VerifyFace(request *VerifyFaceRequest) (response *VerifyFaceResponse, err error)
给定一张人脸图片和一个 PersonId,判断图片中的人和 PersonId 对应的人是否为同一人。PersonId 请参考[人员库管理相关接口](https://cloud.tencent.com/document/product/867/32794)。 和[人脸比对](https://cloud.tencent.com/document/product/867/32802)接口不同的是,[人脸验证](https://cloud.tencent.com/document/product/867/32806)用于判断 “此人是否是此人”,“此人”的信息已存于人员库中,“此人”可能存在多张人脸图片;而[人脸比对](https://cloud.tencent.com/document/product/867/32802)用于判断两张人脸的相似度。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
func (*Client) VerifyPerson ¶
func (c *Client) VerifyPerson(request *VerifyPersonRequest) (response *VerifyPersonResponse, err error)
给定一张人脸图片和一个 PersonId,判断图片中的人和 PersonId 对应的人是否为同一人。PersonId 请参考[人员库管理相关接口](https://cloud.tencent.com/document/product/867/32794)。 本接口会将该人员(Person)下的所有人脸(Face)进行融合特征处理,即若某个Person下有4张 Face,本接口会将4张 Face 的特征进行融合处理,生成对应这个 Person 的特征,使人员验证(确定待识别的人脸图片是某人员)更加准确。
和人脸比对相关接口不同的是,人脸验证相关接口用于判断 “此人是否是此人”,“此人”的信息已存于人员库中,“此人”可能存在多张人脸图片;而人脸比对相关接口用于判断两张人脸的相似度。
> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
type CompareFaceRequest ¶
type CompareFaceRequest struct {
*tchttp.BaseRequest
// A 图片 base64 数据,base64 编码后大小不可超过5M。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
ImageA *string `json:"ImageA,omitempty" name:"ImageA"`
// B 图片 base64 数据,base64 编码后大小不可超过5M。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
ImageB *string `json:"ImageB,omitempty" name:"ImageB"`
// A 图片的 Url ,对应图片 base64 编码后大小不可超过5M。
// A 图片的 Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
UrlA *string `json:"UrlA,omitempty" name:"UrlA"`
// B 图片的 Url ,对应图片 base64 编码后大小不可超过5M。
// B 图片的 Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
UrlB *string `json:"UrlB,omitempty" name:"UrlB"`
// 人脸识别服务所用的算法模型版本。目前入参支持 “2.0”和“3.0“ 两个输入。
// 默认为"2.0"。
// 不同算法模型版本对应的人脸识别算法不同,新版本的整体效果会优于旧版本,建议使用“3.0”版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
}
func NewCompareFaceRequest ¶
func NewCompareFaceRequest() (request *CompareFaceRequest)
func (*CompareFaceRequest) FromJsonString ¶
func (r *CompareFaceRequest) FromJsonString(s string) error
func (*CompareFaceRequest) ToJsonString ¶
func (r *CompareFaceRequest) ToJsonString() string
type CompareFaceResponse ¶
type CompareFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 两张图片中人脸的相似度分数。
// 不同算法版本返回的相似度分数不同。
// 若需要验证两张图片中人脸是否为同一人,3.0版本误识率千分之一对应分数为40分,误识率万分之一对应分数为50分,误识率十万分之一对应分数为60分。 一般超过50分则可认定为同一人。
// 2.0版本误识率千分之一对应分数为70分,误识率万分之一对应分数为80分,误识率十万分之一对应分数为90分。 一般超过80分则可认定为同一人。
// 若需要验证两张图片中的人脸是否为同一人,建议使用人脸验证接口。
Score *float64 `json:"Score,omitempty" name:"Score"`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewCompareFaceResponse ¶
func NewCompareFaceResponse() (response *CompareFaceResponse)
func (*CompareFaceResponse) FromJsonString ¶
func (r *CompareFaceResponse) FromJsonString(s string) error
func (*CompareFaceResponse) ToJsonString ¶
func (r *CompareFaceResponse) ToJsonString() string
type CopyPersonRequest ¶
type CopyPersonRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 待加入的人员库列表
GroupIds []*string `json:"GroupIds,omitempty" name:"GroupIds" list`
}
func NewCopyPersonRequest ¶
func NewCopyPersonRequest() (request *CopyPersonRequest)
func (*CopyPersonRequest) FromJsonString ¶
func (r *CopyPersonRequest) FromJsonString(s string) error
func (*CopyPersonRequest) ToJsonString ¶
func (r *CopyPersonRequest) ToJsonString() string
type CopyPersonResponse ¶
type CopyPersonResponse struct {
*tchttp.BaseResponse
Response *struct {
// 成功加入的人员库数量
SucGroupNum *uint64 `json:"SucGroupNum,omitempty" name:"SucGroupNum"`
// 成功加入的人员库列表
SucGroupIds []*string `json:"SucGroupIds,omitempty" name:"SucGroupIds" list`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewCopyPersonResponse ¶
func NewCopyPersonResponse() (response *CopyPersonResponse)
func (*CopyPersonResponse) FromJsonString ¶
func (r *CopyPersonResponse) FromJsonString(s string) error
func (*CopyPersonResponse) ToJsonString ¶
func (r *CopyPersonResponse) ToJsonString() string
type CreateFaceRequest ¶
type CreateFaceRequest struct {
*tchttp.BaseRequest
// 人员ID。
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 人员人脸总数量不可超过5张。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Images []*string `json:"Images,omitempty" name:"Images" list`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
// 人员人脸总数量不可超过5张。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
Urls []*string `json:"Urls,omitempty" name:"Urls" list`
// 只有和该人员已有的人脸相似度超过FaceMatchThreshold值的人脸,才能增加人脸成功。
// 默认值60分。取值范围[0,100] 。
FaceMatchThreshold *float64 `json:"FaceMatchThreshold,omitempty" name:"FaceMatchThreshold"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
}
func NewCreateFaceRequest ¶
func NewCreateFaceRequest() (request *CreateFaceRequest)
func (*CreateFaceRequest) FromJsonString ¶
func (r *CreateFaceRequest) FromJsonString(s string) error
func (*CreateFaceRequest) ToJsonString ¶
func (r *CreateFaceRequest) ToJsonString() string
type CreateFaceResponse ¶
type CreateFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 加入成功的人脸数量
SucFaceNum *uint64 `json:"SucFaceNum,omitempty" name:"SucFaceNum"`
// 加入成功的人脸ID列表
SucFaceIds []*string `json:"SucFaceIds,omitempty" name:"SucFaceIds" list`
// 每张人脸图片添加结果,-1101 代表未检测到人脸,-1102 代表图片解码失败,
// -1601代表不符合图片质量控制要求,
// -1603 代表已有相似度超过99%的人脸存在,-1604 代表人脸相似度没有超过FaceMatchThreshold。
// 其他非 0 值代表算法服务异常。
// RetCode的顺序和入参中 Images 或 Urls 的顺序一致。
RetCode []*int64 `json:"RetCode,omitempty" name:"RetCode" list`
// 加入成功的人脸索引。索引顺序和入参中 Images 或 Urls 的顺序一致。
// 例, Urls 中 有 3 个 url,第二个 url 失败,则 SucIndexes 值为 [0,2] 。
SucIndexes []*uint64 `json:"SucIndexes,omitempty" name:"SucIndexes" list`
// 加入成功的人脸框位置。顺序和入参中 Images 或 Urls 的顺序一致。
SucFaceRects []*FaceRect `json:"SucFaceRects,omitempty" name:"SucFaceRects" list`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewCreateFaceResponse ¶
func NewCreateFaceResponse() (response *CreateFaceResponse)
func (*CreateFaceResponse) FromJsonString ¶
func (r *CreateFaceResponse) FromJsonString(s string) error
func (*CreateFaceResponse) ToJsonString ¶
func (r *CreateFaceResponse) ToJsonString() string
type CreateGroupRequest ¶
type CreateGroupRequest struct {
*tchttp.BaseRequest
// 人员库名称,[1,60]个字符,可修改,不可重复。
GroupName *string `json:"GroupName,omitempty" name:"GroupName"`
// 人员库 ID,不可修改,不可重复。支持英文、数字、-%@#&_,长度限制64B。
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
// 人员库自定义描述字段,用于描述人员库中人员属性,该人员库下所有人员将拥有此描述字段。
// 最多可以创建5个。
// 每个自定义描述字段支持[1,30]个字符。
// 在同一人员库中自定义描述字段不可重复。
// 例: 设置某人员库“自定义描述字段”为["学号","工号","手机号"],
// 则该人员库下所有人员将拥有名为“学号”、“工号”、“手机号”的描述字段,
// 可在对应人员描述字段中填写内容,登记该人员的学号、工号、手机号等信息。
GroupExDescriptions []*string `json:"GroupExDescriptions,omitempty" name:"GroupExDescriptions" list`
// 人员库信息备注,[0,40]个字符。
Tag *string `json:"Tag,omitempty" name:"Tag"`
// 人脸识别服务所用的算法模型版本。目前入参支持 “2.0”和“3.0“ 两个输入。
// 默认为"2.0"。
// 不同算法模型版本对应的人脸识别算法不同,新版本的整体效果会优于旧版本,建议使用“3.0”版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
}
func NewCreateGroupRequest ¶
func NewCreateGroupRequest() (request *CreateGroupRequest)
func (*CreateGroupRequest) FromJsonString ¶
func (r *CreateGroupRequest) FromJsonString(s string) error
func (*CreateGroupRequest) ToJsonString ¶
func (r *CreateGroupRequest) ToJsonString() string
type CreateGroupResponse ¶
type CreateGroupResponse struct {
*tchttp.BaseResponse
Response *struct {
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewCreateGroupResponse ¶
func NewCreateGroupResponse() (response *CreateGroupResponse)
func (*CreateGroupResponse) FromJsonString ¶
func (r *CreateGroupResponse) FromJsonString(s string) error
func (*CreateGroupResponse) ToJsonString ¶
func (r *CreateGroupResponse) ToJsonString() string
type CreatePersonRequest ¶
type CreatePersonRequest struct {
*tchttp.BaseRequest
// 待加入的人员库ID。
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
// 人员名称。[1,60]个字符,可修改,可重复。
PersonName *string `json:"PersonName,omitempty" name:"PersonName"`
// 人员ID,单个腾讯云账号下不可修改,不可重复。支持英文、数字、-%@#&_,长度限制64B。
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 0代表未填写,1代表男性,2代表女性。
Gender *int64 `json:"Gender,omitempty" name:"Gender"`
// 人员描述字段内容,key-value。[0,60]个字符,可修改,可重复。
PersonExDescriptionInfos []*PersonExDescriptionInfo `json:"PersonExDescriptionInfos,omitempty" name:"PersonExDescriptionInfos" list`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 此参数用于控制判断 Image 或 Url 中图片包含的人脸,是否在人员库中已有疑似的同一人。
// 如果判断为已有相同人在人员库中,则不会创建新的人员,返回疑似同一人的人员信息。
// 如果判断没有,则完成创建人员。
// 0: 不进行判断,无论是否有疑似同一人在库中均完成入库;
// 1:较低的同一人判断要求(百一误识别率);
// 2: 一般的同一人判断要求(千一误识别率);
// 3: 较高的同一人判断要求(万一误识别率);
// 4: 很高的同一人判断要求(十万一误识别率)。
// 默认 0。
// 注: 要求越高,则疑似同一人的概率越小。不同要求对应的误识别率仅为参考值,您可以根据实际情况调整。
UniquePersonControl *uint64 `json:"UniquePersonControl,omitempty" name:"UniquePersonControl"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
}
func NewCreatePersonRequest ¶
func NewCreatePersonRequest() (request *CreatePersonRequest)
func (*CreatePersonRequest) FromJsonString ¶
func (r *CreatePersonRequest) FromJsonString(s string) error
func (*CreatePersonRequest) ToJsonString ¶
func (r *CreatePersonRequest) ToJsonString() string
type CreatePersonResponse ¶
type CreatePersonResponse struct {
*tchttp.BaseResponse
Response *struct {
// 人脸图片唯一标识。
FaceId *string `json:"FaceId,omitempty" name:"FaceId"`
// 检测出的人脸框的位置。
// 注意:此字段可能返回 null,表示取不到有效值。
FaceRect *FaceRect `json:"FaceRect,omitempty" name:"FaceRect"`
// 疑似同一人的PersonId。
// 当 UniquePersonControl 参数不为0且人员库中有疑似的同一人,此参数才有意义。
SimilarPersonId *string `json:"SimilarPersonId,omitempty" name:"SimilarPersonId"`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewCreatePersonResponse ¶
func NewCreatePersonResponse() (response *CreatePersonResponse)
func (*CreatePersonResponse) FromJsonString ¶
func (r *CreatePersonResponse) FromJsonString(s string) error
func (*CreatePersonResponse) ToJsonString ¶
func (r *CreatePersonResponse) ToJsonString() string
type DeleteFaceRequest ¶
type DeleteFaceRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 待删除的人脸ID列表
FaceIds []*string `json:"FaceIds,omitempty" name:"FaceIds" list`
}
func NewDeleteFaceRequest ¶
func NewDeleteFaceRequest() (request *DeleteFaceRequest)
func (*DeleteFaceRequest) FromJsonString ¶
func (r *DeleteFaceRequest) FromJsonString(s string) error
func (*DeleteFaceRequest) ToJsonString ¶
func (r *DeleteFaceRequest) ToJsonString() string
type DeleteFaceResponse ¶
type DeleteFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 删除成功的人脸数量
SucDeletedNum *uint64 `json:"SucDeletedNum,omitempty" name:"SucDeletedNum"`
// 删除成功的人脸ID列表
SucFaceIds []*string `json:"SucFaceIds,omitempty" name:"SucFaceIds" list`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewDeleteFaceResponse ¶
func NewDeleteFaceResponse() (response *DeleteFaceResponse)
func (*DeleteFaceResponse) FromJsonString ¶
func (r *DeleteFaceResponse) FromJsonString(s string) error
func (*DeleteFaceResponse) ToJsonString ¶
func (r *DeleteFaceResponse) ToJsonString() string
type DeleteGroupRequest ¶
type DeleteGroupRequest struct {
*tchttp.BaseRequest
// 人员库ID。
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
}
func NewDeleteGroupRequest ¶
func NewDeleteGroupRequest() (request *DeleteGroupRequest)
func (*DeleteGroupRequest) FromJsonString ¶
func (r *DeleteGroupRequest) FromJsonString(s string) error
func (*DeleteGroupRequest) ToJsonString ¶
func (r *DeleteGroupRequest) ToJsonString() string
type DeleteGroupResponse ¶
type DeleteGroupResponse struct {
*tchttp.BaseResponse
Response *struct {
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewDeleteGroupResponse ¶
func NewDeleteGroupResponse() (response *DeleteGroupResponse)
func (*DeleteGroupResponse) FromJsonString ¶
func (r *DeleteGroupResponse) FromJsonString(s string) error
func (*DeleteGroupResponse) ToJsonString ¶
func (r *DeleteGroupResponse) ToJsonString() string
type DeletePersonFromGroupRequest ¶
type DeletePersonFromGroupRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 人员库ID
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
}
func NewDeletePersonFromGroupRequest ¶
func NewDeletePersonFromGroupRequest() (request *DeletePersonFromGroupRequest)
func (*DeletePersonFromGroupRequest) FromJsonString ¶
func (r *DeletePersonFromGroupRequest) FromJsonString(s string) error
func (*DeletePersonFromGroupRequest) ToJsonString ¶
func (r *DeletePersonFromGroupRequest) ToJsonString() string
type DeletePersonFromGroupResponse ¶
type DeletePersonFromGroupResponse struct {
*tchttp.BaseResponse
Response *struct {
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewDeletePersonFromGroupResponse ¶
func NewDeletePersonFromGroupResponse() (response *DeletePersonFromGroupResponse)
func (*DeletePersonFromGroupResponse) FromJsonString ¶
func (r *DeletePersonFromGroupResponse) FromJsonString(s string) error
func (*DeletePersonFromGroupResponse) ToJsonString ¶
func (r *DeletePersonFromGroupResponse) ToJsonString() string
type DeletePersonRequest ¶
type DeletePersonRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
}
func NewDeletePersonRequest ¶
func NewDeletePersonRequest() (request *DeletePersonRequest)
func (*DeletePersonRequest) FromJsonString ¶
func (r *DeletePersonRequest) FromJsonString(s string) error
func (*DeletePersonRequest) ToJsonString ¶
func (r *DeletePersonRequest) ToJsonString() string
type DeletePersonResponse ¶
type DeletePersonResponse struct {
*tchttp.BaseResponse
Response *struct {
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewDeletePersonResponse ¶
func NewDeletePersonResponse() (response *DeletePersonResponse)
func (*DeletePersonResponse) FromJsonString ¶
func (r *DeletePersonResponse) FromJsonString(s string) error
func (*DeletePersonResponse) ToJsonString ¶
func (r *DeletePersonResponse) ToJsonString() string
type DetectFaceRequest ¶
type DetectFaceRequest struct {
*tchttp.BaseRequest
// 最多处理的人脸数目。默认值为1(仅检测图片中面积最大的那张人脸),最大值为120。
// 此参数用于控制处理待检测图片中的人脸个数,值越小,处理速度越快。
MaxFaceNum *uint64 `json:"MaxFaceNum,omitempty" name:"MaxFaceNum"`
// 人脸长和宽的最小尺寸,单位为像素。
// 默认为40。建议不低于34。
// 低于MinFaceSize值的人脸不会被检测。
MinFaceSize *uint64 `json:"MinFaceSize,omitempty" name:"MinFaceSize"`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 是否需要返回人脸属性信息(FaceAttributesInfo)。0 为不需要返回,1 为需要返回。默认为 0。
// 非 1 值均视为不需要返回,此时 FaceAttributesInfo 不具备参考意义。
// 最多返回面积最大的 5 张人脸属性信息,超过 5 张人脸(第 6 张及以后的人脸)的 FaceAttributesInfo 不具备参考意义。
// 提取人脸属性信息较为耗时,如不需要人脸属性信息,建议关闭此项功能,加快人脸检测速度。
NeedFaceAttributes *uint64 `json:"NeedFaceAttributes,omitempty" name:"NeedFaceAttributes"`
// 是否开启质量检测。0 为关闭,1 为开启。默认为 0。
// 非 1 值均视为不进行质量检测。
// 最多返回面积最大的 30 张人脸质量分信息,超过 30 张人脸(第 31 张及以后的人脸)的 FaceQualityInfo不具备参考意义。
// 建议:人脸入库操作建议开启此功能。
NeedQualityDetection *uint64 `json:"NeedQualityDetection,omitempty" name:"NeedQualityDetection"`
// 人脸识别服务所用的算法模型版本。目前入参支持 “2.0”和“3.0“ 两个输入。
// 默认为"2.0"。
// 不同算法模型版本对应的人脸识别算法不同,新版本的整体效果会优于旧版本,建议使用“3.0”版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
}
func NewDetectFaceRequest ¶
func NewDetectFaceRequest() (request *DetectFaceRequest)
func (*DetectFaceRequest) FromJsonString ¶
func (r *DetectFaceRequest) FromJsonString(s string) error
func (*DetectFaceRequest) ToJsonString ¶
func (r *DetectFaceRequest) ToJsonString() string
type DetectFaceResponse ¶
type DetectFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 请求的图片宽度。
ImageWidth *int64 `json:"ImageWidth,omitempty" name:"ImageWidth"`
// 请求的图片高度。
ImageHeight *int64 `json:"ImageHeight,omitempty" name:"ImageHeight"`
// 人脸信息列表。
FaceInfos []*FaceInfo `json:"FaceInfos,omitempty" name:"FaceInfos" list`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewDetectFaceResponse ¶
func NewDetectFaceResponse() (response *DetectFaceResponse)
func (*DetectFaceResponse) FromJsonString ¶
func (r *DetectFaceResponse) FromJsonString(s string) error
func (*DetectFaceResponse) ToJsonString ¶
func (r *DetectFaceResponse) ToJsonString() string
type DetectLiveFaceRequest ¶
type DetectLiveFaceRequest struct {
*tchttp.BaseRequest
// 图片 base64 数据,base64 编码后大小不可超过5M(图片的宽高比请接近3:4,不符合宽高比的图片返回的分值不具备参考意义)。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// (图片的宽高比请接近 3:4,不符合宽高比的图片返回的分值不具备参考意义)
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 人脸识别服务所用的算法模型版本。目前入参支持 “2.0”和“3.0“ 两个输入。
// 默认为"2.0"。
// 不同算法模型版本对应的人脸识别算法不同,新版本的整体效果会优于旧版本,建议使用“3.0”版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
}
func NewDetectLiveFaceRequest ¶
func NewDetectLiveFaceRequest() (request *DetectLiveFaceRequest)
func (*DetectLiveFaceRequest) FromJsonString ¶
func (r *DetectLiveFaceRequest) FromJsonString(s string) error
func (*DetectLiveFaceRequest) ToJsonString ¶
func (r *DetectLiveFaceRequest) ToJsonString() string
type DetectLiveFaceResponse ¶
type DetectLiveFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 活体打分,取值范围 [0,100],分数一般落于[80, 100]区间内,0分也为常见值。推荐相大于 87 时可判断为活体。可根据具体场景自行调整阈值。
// 本字段当且仅当FaceModelVersion为2.0时才具备参考意义。
Score *float64 `json:"Score,omitempty" name:"Score"`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 活体检测是否通过。
// 本字段只有FaceModelVersion为3.0时才具备参考意义。
IsLiveness *bool `json:"IsLiveness,omitempty" name:"IsLiveness"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewDetectLiveFaceResponse ¶
func NewDetectLiveFaceResponse() (response *DetectLiveFaceResponse)
func (*DetectLiveFaceResponse) FromJsonString ¶
func (r *DetectLiveFaceResponse) FromJsonString(s string) error
func (*DetectLiveFaceResponse) ToJsonString ¶
func (r *DetectLiveFaceResponse) ToJsonString() string
type FaceAttributesInfo ¶
type FaceAttributesInfo struct {
// 性别[0~49]为女性,[50,100]为男性,越接近0和100表示置信度越高。NeedFaceAttributes 不为 1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
Gender *int64 `json:"Gender,omitempty" name:"Gender"`
// 年龄 [0~100]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
Age *int64 `json:"Age,omitempty" name:"Age"`
// 微笑[0(normal,正常)~50(smile,微笑)~100(laugh,大笑)]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
Expression *int64 `json:"Expression,omitempty" name:"Expression"`
// 是否有眼镜 [true,false]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
Glass *bool `json:"Glass,omitempty" name:"Glass"`
// 上下偏移[-30,30]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 建议:人脸入库选择[-10,10]的图片。
Pitch *int64 `json:"Pitch,omitempty" name:"Pitch"`
// 左右偏移[-30,30]。 NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 建议:人脸入库选择[-10,10]的图片。
Yaw *int64 `json:"Yaw,omitempty" name:"Yaw"`
// 平面旋转[-180,180]。 NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 建议:人脸入库选择[-20,20]的图片。
Roll *int64 `json:"Roll,omitempty" name:"Roll"`
// 魅力[0~100]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
Beauty *int64 `json:"Beauty,omitempty" name:"Beauty"`
// 是否有帽子 [true,false]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 注意:此字段可能返回 null,表示取不到有效值。
Hat *bool `json:"Hat,omitempty" name:"Hat"`
// 是否有口罩 [true,false]。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 注意:此字段可能返回 null,表示取不到有效值。
Mask *bool `json:"Mask,omitempty" name:"Mask"`
// 头发信息,包含头发长度(length)、有无刘海(bang)、头发颜色(color)。NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 注意:此字段可能返回 null,表示取不到有效值。
Hair *FaceHairAttributesInfo `json:"Hair,omitempty" name:"Hair"`
// 双眼是否睁开 [true,false]。只要有超过一只眼睛闭眼,就返回false。 NeedFaceAttributes 不为1 或检测超过 5 张人脸时,此参数仍返回,但不具备参考意义。
// 注意:此字段可能返回 null,表示取不到有效值。
EyeOpen *bool `json:"EyeOpen,omitempty" name:"EyeOpen"`
}
type FaceHairAttributesInfo ¶
type FaceHairAttributesInfo struct {
// 0:光头,1:短发,2:中发,3:长发,4:绑发
// 注意:此字段可能返回 null,表示取不到有效值。
Length *int64 `json:"Length,omitempty" name:"Length"`
// 0:有刘海,1:无刘海
// 注意:此字段可能返回 null,表示取不到有效值。
Bang *int64 `json:"Bang,omitempty" name:"Bang"`
// 0:黑色,1:金色,2:棕色,3:灰白色
// 注意:此字段可能返回 null,表示取不到有效值。
Color *int64 `json:"Color,omitempty" name:"Color"`
}
type FaceInfo ¶
type FaceInfo struct {
// 人脸框左上角横坐标。
// 人脸框包含人脸五官位置并在此基础上进行一定的扩展,若人脸框超出图片范围,会导致坐标负值。
// 若需截取完整人脸,可以在完整分completess满足需求的情况下,将负值坐标取0。
X *int64 `json:"X,omitempty" name:"X"`
// 人脸框左上角纵坐标。
// 人脸框包含人脸五官位置并在此基础上进行一定的扩展,若人脸框超出图片范围,会导致坐标负值。
// 若需截取完整人脸,可以在完整分completess满足需求的情况下,将负值坐标取0。
Y *int64 `json:"Y,omitempty" name:"Y"`
// 人脸框宽度。
Width *int64 `json:"Width,omitempty" name:"Width"`
// 人脸框高度。
Height *int64 `json:"Height,omitempty" name:"Height"`
// 人脸属性信息,包含性别( gender )、年龄( age )、表情( expression )、
// 魅力( beauty )、眼镜( glass )、口罩(mask)、头发(hair)和姿态 (pitch,roll,yaw )。只有当 NeedFaceAttributes 设为 1 时才返回有效信息。
FaceAttributesInfo *FaceAttributesInfo `json:"FaceAttributesInfo,omitempty" name:"FaceAttributesInfo"`
// 人脸质量信息,包含质量分(score)、模糊分(sharpness)、光照分(brightness)、遮挡分(completeness)。只有当NeedFaceDetection设为1时才返回有效信息。
// 注意:此字段可能返回 null,表示取不到有效值。
FaceQualityInfo *FaceQualityInfo `json:"FaceQualityInfo,omitempty" name:"FaceQualityInfo"`
}
type FaceQualityCompleteness ¶
type FaceQualityCompleteness struct {
// 眉毛的遮挡分数[0,100],分数越高遮挡越少。
// 参考范围:[0,80]表示发生遮挡。
// 注意:此字段可能返回 null,表示取不到有效值。
Eyebrow *int64 `json:"Eyebrow,omitempty" name:"Eyebrow"`
// 眼睛的遮挡分数[0,100],分数越高遮挡越少。
// 参考范围:[0,80]表示发生遮挡。
// 注意:此字段可能返回 null,表示取不到有效值。
Eye *int64 `json:"Eye,omitempty" name:"Eye"`
// 鼻子的遮挡分数[0,100],分数越高遮挡越少。
// 参考范围:[0,60]表示发生遮挡。
// 注意:此字段可能返回 null,表示取不到有效值。
Nose *int64 `json:"Nose,omitempty" name:"Nose"`
// 脸颊的遮挡分数[0,100],分数越高遮挡越少。
// 参考范围:[0,70]表示发生遮挡。
// 注意:此字段可能返回 null,表示取不到有效值。
Cheek *int64 `json:"Cheek,omitempty" name:"Cheek"`
// 嘴巴的遮挡分数[0,100],分数越高遮挡越少。
// 参考范围:[0,50]表示发生遮挡。
// 注意:此字段可能返回 null,表示取不到有效值。
Mouth *int64 `json:"Mouth,omitempty" name:"Mouth"`
// 下巴的遮挡分数[0,100],分数越高遮挡越少。
// 参考范围:[0,70]表示发生遮挡。
// 注意:此字段可能返回 null,表示取不到有效值。
Chin *int64 `json:"Chin,omitempty" name:"Chin"`
}
type FaceQualityInfo ¶
type FaceQualityInfo struct {
// 质量分: [0,100],综合评价图像质量是否适合人脸识别,分数越高质量越好。
// 正常情况,只需要使用Score作为质量分总体的判断标准即可。Sharpness、Brightness、Completeness等细项分仅供参考。
// 参考范围:[0,40]较差,[40,60] 一般,[60,80]较好,[80,100]很好。
// 建议:人脸入库选取70以上的图片。
// 注意:此字段可能返回 null,表示取不到有效值。
Score *int64 `json:"Score,omitempty" name:"Score"`
// 清晰分:[0,100],评价图片清晰程度,分数越高越清晰。
// 参考范围:[0,40]特别模糊,[40,60]模糊,[60,80]一般,[80,100]清晰。
// 建议:人脸入库选取80以上的图片。
// 注意:此字段可能返回 null,表示取不到有效值。
Sharpness *int64 `json:"Sharpness,omitempty" name:"Sharpness"`
// 光照分:[0,100],评价图片光照程度,分数越高越亮。
// 参考范围: [0,30]偏暗,[30,70]光照正常,[70,100]偏亮。
// 建议:人脸入库选取[30,70]的图片。
// 注意:此字段可能返回 null,表示取不到有效值。
Brightness *int64 `json:"Brightness,omitempty" name:"Brightness"`
// 五官遮挡分,评价眉毛(Eyebrow)、眼睛(Eye)、鼻子(Nose)、脸颊(Cheek)、嘴巴(Mouth)、下巴(Chin)的被遮挡程度。
// 注意:此字段可能返回 null,表示取不到有效值。
Completeness *FaceQualityCompleteness `json:"Completeness,omitempty" name:"Completeness"`
}
type FaceRect ¶
type FaceRect struct {
// 人脸框左上角横坐标。
// 人脸框包含人脸五官位置并在此基础上进行一定的扩展,若人脸框超出图片范围,会导致坐标负值。
// 若需截取完整人脸,可以在完整分completess满足需求的情况下,将负值坐标取0。
X *int64 `json:"X,omitempty" name:"X"`
// 人脸框左上角纵坐标。
// 人脸框包含人脸五官位置并在此基础上进行一定的扩展,若人脸框超出图片范围,会导致坐标负值。
// 若需截取完整人脸,可以在完整分completess满足需求的情况下,将负值坐标取0。
Y *int64 `json:"Y,omitempty" name:"Y"`
// 人脸宽度
Width *uint64 `json:"Width,omitempty" name:"Width"`
// 人脸高度
Height *uint64 `json:"Height,omitempty" name:"Height"`
}
type FaceShape ¶
type FaceShape struct {
// 描述脸型轮廓的 21 点。
FaceProfile []*Point `json:"FaceProfile,omitempty" name:"FaceProfile" list`
// 描述左侧眼睛轮廓的 8 点。
LeftEye []*Point `json:"LeftEye,omitempty" name:"LeftEye" list`
// 描述右侧眼睛轮廓的 8 点。
RightEye []*Point `json:"RightEye,omitempty" name:"RightEye" list`
// 描述左侧眉毛轮廓的 8 点。
LeftEyeBrow []*Point `json:"LeftEyeBrow,omitempty" name:"LeftEyeBrow" list`
// 描述右侧眉毛轮廓的 8 点。
RightEyeBrow []*Point `json:"RightEyeBrow,omitempty" name:"RightEyeBrow" list`
// 描述嘴巴轮廓的 22 点。
Mouth []*Point `json:"Mouth,omitempty" name:"Mouth" list`
// 描述鼻子轮廓的 13 点。
Nose []*Point `json:"Nose,omitempty" name:"Nose" list`
// 左瞳孔轮廓的 1 个点。
LeftPupil []*Point `json:"LeftPupil,omitempty" name:"LeftPupil" list`
// 右瞳孔轮廓的 1 个点。
RightPupil []*Point `json:"RightPupil,omitempty" name:"RightPupil" list`
}
type GetGroupListRequest ¶
type GetGroupListRequest struct {
*tchttp.BaseRequest
// 起始序号,默认值为0
Offset *uint64 `json:"Offset,omitempty" name:"Offset"`
// 返回数量,默认值为10,最大值为1000
Limit *uint64 `json:"Limit,omitempty" name:"Limit"`
}
func NewGetGroupListRequest ¶
func NewGetGroupListRequest() (request *GetGroupListRequest)
func (*GetGroupListRequest) FromJsonString ¶
func (r *GetGroupListRequest) FromJsonString(s string) error
func (*GetGroupListRequest) ToJsonString ¶
func (r *GetGroupListRequest) ToJsonString() string
type GetGroupListResponse ¶
type GetGroupListResponse struct {
*tchttp.BaseResponse
Response *struct {
// 返回的人员库信息
GroupInfos []*GroupInfo `json:"GroupInfos,omitempty" name:"GroupInfos" list`
// 人员库总数量
// 注意:此字段可能返回 null,表示取不到有效值。
GroupNum *uint64 `json:"GroupNum,omitempty" name:"GroupNum"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewGetGroupListResponse ¶
func NewGetGroupListResponse() (response *GetGroupListResponse)
func (*GetGroupListResponse) FromJsonString ¶
func (r *GetGroupListResponse) FromJsonString(s string) error
func (*GetGroupListResponse) ToJsonString ¶
func (r *GetGroupListResponse) ToJsonString() string
type GetPersonBaseInfoRequest ¶
type GetPersonBaseInfoRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
}
func NewGetPersonBaseInfoRequest ¶
func NewGetPersonBaseInfoRequest() (request *GetPersonBaseInfoRequest)
func (*GetPersonBaseInfoRequest) FromJsonString ¶
func (r *GetPersonBaseInfoRequest) FromJsonString(s string) error
func (*GetPersonBaseInfoRequest) ToJsonString ¶
func (r *GetPersonBaseInfoRequest) ToJsonString() string
type GetPersonBaseInfoResponse ¶
type GetPersonBaseInfoResponse struct {
*tchttp.BaseResponse
Response *struct {
// 人员名称
PersonName *string `json:"PersonName,omitempty" name:"PersonName"`
// 人员性别
Gender *int64 `json:"Gender,omitempty" name:"Gender"`
// 包含的人脸 ID 列表
FaceIds []*string `json:"FaceIds,omitempty" name:"FaceIds" list`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewGetPersonBaseInfoResponse ¶
func NewGetPersonBaseInfoResponse() (response *GetPersonBaseInfoResponse)
func (*GetPersonBaseInfoResponse) FromJsonString ¶
func (r *GetPersonBaseInfoResponse) FromJsonString(s string) error
func (*GetPersonBaseInfoResponse) ToJsonString ¶
func (r *GetPersonBaseInfoResponse) ToJsonString() string
type GetPersonGroupInfoRequest ¶
type GetPersonGroupInfoRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 起始序号,默认值为0
Offset *uint64 `json:"Offset,omitempty" name:"Offset"`
// 返回数量,默认值为10,最大值为100
Limit *uint64 `json:"Limit,omitempty" name:"Limit"`
}
func NewGetPersonGroupInfoRequest ¶
func NewGetPersonGroupInfoRequest() (request *GetPersonGroupInfoRequest)
func (*GetPersonGroupInfoRequest) FromJsonString ¶
func (r *GetPersonGroupInfoRequest) FromJsonString(s string) error
func (*GetPersonGroupInfoRequest) ToJsonString ¶
func (r *GetPersonGroupInfoRequest) ToJsonString() string
type GetPersonGroupInfoResponse ¶
type GetPersonGroupInfoResponse struct {
*tchttp.BaseResponse
Response *struct {
// 包含此人员的人员库及描述字段内容列表
PersonGroupInfos []*PersonGroupInfo `json:"PersonGroupInfos,omitempty" name:"PersonGroupInfos" list`
// 人员库总数量
// 注意:此字段可能返回 null,表示取不到有效值。
GroupNum *uint64 `json:"GroupNum,omitempty" name:"GroupNum"`
// 人脸识别服务所用的算法模型版本。
// 注意:此字段可能返回 null,表示取不到有效值。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewGetPersonGroupInfoResponse ¶
func NewGetPersonGroupInfoResponse() (response *GetPersonGroupInfoResponse)
func (*GetPersonGroupInfoResponse) FromJsonString ¶
func (r *GetPersonGroupInfoResponse) FromJsonString(s string) error
func (*GetPersonGroupInfoResponse) ToJsonString ¶
func (r *GetPersonGroupInfoResponse) ToJsonString() string
type GetPersonListNumRequest ¶
type GetPersonListNumRequest struct {
*tchttp.BaseRequest
// 人员库ID
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
}
func NewGetPersonListNumRequest ¶
func NewGetPersonListNumRequest() (request *GetPersonListNumRequest)
func (*GetPersonListNumRequest) FromJsonString ¶
func (r *GetPersonListNumRequest) FromJsonString(s string) error
func (*GetPersonListNumRequest) ToJsonString ¶
func (r *GetPersonListNumRequest) ToJsonString() string
type GetPersonListNumResponse ¶
type GetPersonListNumResponse struct {
*tchttp.BaseResponse
Response *struct {
// 人员数量
PersonNum *uint64 `json:"PersonNum,omitempty" name:"PersonNum"`
// 人脸数量
FaceNum *uint64 `json:"FaceNum,omitempty" name:"FaceNum"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewGetPersonListNumResponse ¶
func NewGetPersonListNumResponse() (response *GetPersonListNumResponse)
func (*GetPersonListNumResponse) FromJsonString ¶
func (r *GetPersonListNumResponse) FromJsonString(s string) error
func (*GetPersonListNumResponse) ToJsonString ¶
func (r *GetPersonListNumResponse) ToJsonString() string
type GetPersonListRequest ¶
type GetPersonListRequest struct {
*tchttp.BaseRequest
// 人员库ID
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
// 起始序号,默认值为0
Offset *uint64 `json:"Offset,omitempty" name:"Offset"`
// 返回数量,默认值为10,最大值为1000
Limit *uint64 `json:"Limit,omitempty" name:"Limit"`
}
func NewGetPersonListRequest ¶
func NewGetPersonListRequest() (request *GetPersonListRequest)
func (*GetPersonListRequest) FromJsonString ¶
func (r *GetPersonListRequest) FromJsonString(s string) error
func (*GetPersonListRequest) ToJsonString ¶
func (r *GetPersonListRequest) ToJsonString() string
type GetPersonListResponse ¶
type GetPersonListResponse struct {
*tchttp.BaseResponse
Response *struct {
// 返回的人员信息
PersonInfos []*PersonInfo `json:"PersonInfos,omitempty" name:"PersonInfos" list`
// 该人员库的人员数量
// 注意:此字段可能返回 null,表示取不到有效值。
PersonNum *uint64 `json:"PersonNum,omitempty" name:"PersonNum"`
// 该人员库的人脸数量
// 注意:此字段可能返回 null,表示取不到有效值。
FaceNum *uint64 `json:"FaceNum,omitempty" name:"FaceNum"`
// 人脸识别所用的算法模型版本。
// 注意:此字段可能返回 null,表示取不到有效值。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewGetPersonListResponse ¶
func NewGetPersonListResponse() (response *GetPersonListResponse)
func (*GetPersonListResponse) FromJsonString ¶
func (r *GetPersonListResponse) FromJsonString(s string) error
func (*GetPersonListResponse) ToJsonString ¶
func (r *GetPersonListResponse) ToJsonString() string
type GroupCandidate ¶
type GroupExDescriptionInfo ¶
type GroupInfo ¶
type GroupInfo struct {
// 人员库名称
GroupName *string `json:"GroupName,omitempty" name:"GroupName"`
// 人员库ID
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
// 人员库自定义描述字段
// 注意:此字段可能返回 null,表示取不到有效值。
GroupExDescriptions []*string `json:"GroupExDescriptions,omitempty" name:"GroupExDescriptions" list`
// 人员库信息备注
// 注意:此字段可能返回 null,表示取不到有效值。
Tag *string `json:"Tag,omitempty" name:"Tag"`
// 人脸识别所用的算法模型版本。
// 注意:此字段可能返回 null,表示取不到有效值。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// Group的创建时间和日期 CreationTimestamp。CreationTimestamp 的值是自 Unix 纪元时间到Group创建时间的毫秒数。
// Unix 纪元时间是 1970 年 1 月 1 日星期四,协调世界时 (UTC) 00:00:00。有关更多信息,请参阅 Unix 时间。
// 注意:此字段可能返回 null,表示取不到有效值。
CreationTimestamp *uint64 `json:"CreationTimestamp,omitempty" name:"CreationTimestamp"`
}
type ModifyGroupRequest ¶
type ModifyGroupRequest struct {
*tchttp.BaseRequest
// 人员库ID
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
// 人员库名称
GroupName *string `json:"GroupName,omitempty" name:"GroupName"`
// 需要修改的人员库自定义描述字段,key-value
GroupExDescriptionInfos []*GroupExDescriptionInfo `json:"GroupExDescriptionInfos,omitempty" name:"GroupExDescriptionInfos" list`
// 人员库信息备注
Tag *string `json:"Tag,omitempty" name:"Tag"`
}
func NewModifyGroupRequest ¶
func NewModifyGroupRequest() (request *ModifyGroupRequest)
func (*ModifyGroupRequest) FromJsonString ¶
func (r *ModifyGroupRequest) FromJsonString(s string) error
func (*ModifyGroupRequest) ToJsonString ¶
func (r *ModifyGroupRequest) ToJsonString() string
type ModifyGroupResponse ¶
type ModifyGroupResponse struct {
*tchttp.BaseResponse
Response *struct {
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewModifyGroupResponse ¶
func NewModifyGroupResponse() (response *ModifyGroupResponse)
func (*ModifyGroupResponse) FromJsonString ¶
func (r *ModifyGroupResponse) FromJsonString(s string) error
func (*ModifyGroupResponse) ToJsonString ¶
func (r *ModifyGroupResponse) ToJsonString() string
type ModifyPersonBaseInfoRequest ¶
type ModifyPersonBaseInfoRequest struct {
*tchttp.BaseRequest
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 需要修改的人员名称
PersonName *string `json:"PersonName,omitempty" name:"PersonName"`
// 需要修改的人员性别
Gender *int64 `json:"Gender,omitempty" name:"Gender"`
}
func NewModifyPersonBaseInfoRequest ¶
func NewModifyPersonBaseInfoRequest() (request *ModifyPersonBaseInfoRequest)
func (*ModifyPersonBaseInfoRequest) FromJsonString ¶
func (r *ModifyPersonBaseInfoRequest) FromJsonString(s string) error
func (*ModifyPersonBaseInfoRequest) ToJsonString ¶
func (r *ModifyPersonBaseInfoRequest) ToJsonString() string
type ModifyPersonBaseInfoResponse ¶
type ModifyPersonBaseInfoResponse struct {
*tchttp.BaseResponse
Response *struct {
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewModifyPersonBaseInfoResponse ¶
func NewModifyPersonBaseInfoResponse() (response *ModifyPersonBaseInfoResponse)
func (*ModifyPersonBaseInfoResponse) FromJsonString ¶
func (r *ModifyPersonBaseInfoResponse) FromJsonString(s string) error
func (*ModifyPersonBaseInfoResponse) ToJsonString ¶
func (r *ModifyPersonBaseInfoResponse) ToJsonString() string
type ModifyPersonGroupInfoRequest ¶
type ModifyPersonGroupInfoRequest struct {
*tchttp.BaseRequest
// 人员库ID
GroupId *string `json:"GroupId,omitempty" name:"GroupId"`
// 人员ID
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 需要修改的人员描述字段内容,key-value
PersonExDescriptionInfos []*PersonExDescriptionInfo `json:"PersonExDescriptionInfos,omitempty" name:"PersonExDescriptionInfos" list`
}
func NewModifyPersonGroupInfoRequest ¶
func NewModifyPersonGroupInfoRequest() (request *ModifyPersonGroupInfoRequest)
func (*ModifyPersonGroupInfoRequest) FromJsonString ¶
func (r *ModifyPersonGroupInfoRequest) FromJsonString(s string) error
func (*ModifyPersonGroupInfoRequest) ToJsonString ¶
func (r *ModifyPersonGroupInfoRequest) ToJsonString() string
type ModifyPersonGroupInfoResponse ¶
type ModifyPersonGroupInfoResponse struct {
*tchttp.BaseResponse
Response *struct {
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewModifyPersonGroupInfoResponse ¶
func NewModifyPersonGroupInfoResponse() (response *ModifyPersonGroupInfoResponse)
func (*ModifyPersonGroupInfoResponse) FromJsonString ¶
func (r *ModifyPersonGroupInfoResponse) FromJsonString(s string) error
func (*ModifyPersonGroupInfoResponse) ToJsonString ¶
func (r *ModifyPersonGroupInfoResponse) ToJsonString() string
type PersonExDescriptionInfo ¶
type PersonGroupInfo ¶
type PersonInfo ¶
type PersonInfo struct {
// 人员名称
PersonName *string `json:"PersonName,omitempty" name:"PersonName"`
// 人员Id
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 人员性别
Gender *int64 `json:"Gender,omitempty" name:"Gender"`
// 人员描述字段内容
PersonExDescriptions []*string `json:"PersonExDescriptions,omitempty" name:"PersonExDescriptions" list`
// 包含的人脸照片列表
FaceIds []*string `json:"FaceIds,omitempty" name:"FaceIds" list`
// Group的创建时间和日期 CreationTimestamp。CreationTimestamp 的值是自 Unix 纪元时间到Group创建时间的毫秒数。
// Unix 纪元时间是 1970 年 1 月 1 日星期四,协调世界时 (UTC) 00:00:00。有关更多信息,请参阅 Unix 时间。
CreationTimestamp *uint64 `json:"CreationTimestamp,omitempty" name:"CreationTimestamp"`
}
type Result ¶
type Result struct {
// 识别出的最相似候选人
Candidates []*Candidate `json:"Candidates,omitempty" name:"Candidates" list`
// 检测出的人脸框位置
FaceRect *FaceRect `json:"FaceRect,omitempty" name:"FaceRect"`
// 检测出的人脸图片状态返回码。0 表示正常。
// -1601代表不符合图片质量控制要求,此时Candidate内容为空。
RetCode *int64 `json:"RetCode,omitempty" name:"RetCode"`
}
type ResultsReturnsByGroup ¶
type ResultsReturnsByGroup struct {
// 检测出的人脸框位置。
FaceRect *FaceRect `json:"FaceRect,omitempty" name:"FaceRect"`
// 识别结果。
GroupCandidates []*GroupCandidate `json:"GroupCandidates,omitempty" name:"GroupCandidates" list`
// 检测出的人脸图片状态返回码。0 表示正常。
// -1601代表不符合图片质量控制要求,此时Candidate内容为空。
RetCode *int64 `json:"RetCode,omitempty" name:"RetCode"`
}
type SearchFacesRequest ¶
type SearchFacesRequest struct {
*tchttp.BaseRequest
// 希望搜索的人员库列表,上限100个。
GroupIds []*string `json:"GroupIds,omitempty" name:"GroupIds" list`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 最多识别的人脸数目。默认值为1(仅检测图片中面积最大的那张人脸),最大值为10。
// MaxFaceNum用于,当输入的待识别图片包含多张人脸时,设定要搜索的人脸的数量。
// 例:输入的Image或Url中的图片包含多张人脸,设MaxFaceNum=5,则会识别图片中面积最大的5张人脸。
MaxFaceNum *uint64 `json:"MaxFaceNum,omitempty" name:"MaxFaceNum"`
// 人脸长和宽的最小尺寸,单位为像素。默认为80。低于40的人脸图片无法被识别。建议设置为80。
MinFaceSize *uint64 `json:"MinFaceSize,omitempty" name:"MinFaceSize"`
// 单张被识别的人脸返回的最相似人员数量。默认值为5,最大值为100。
// 例,设MaxFaceNum为1,MaxPersonNum为8,则返回Top8相似的人员信息。
// 值越大,需要处理的时间越长。建议不要超过10。
MaxPersonNum *uint64 `json:"MaxPersonNum,omitempty" name:"MaxPersonNum"`
// 是否返回人员具体信息。0 为关闭,1 为开启。默认为 0。其他非0非1值默认为0
NeedPersonInfo *int64 `json:"NeedPersonInfo,omitempty" name:"NeedPersonInfo"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
// 出参Score中,只有超过FaceMatchThreshold值的结果才会返回。默认为0。
FaceMatchThreshold *float64 `json:"FaceMatchThreshold,omitempty" name:"FaceMatchThreshold"`
}
func NewSearchFacesRequest ¶
func NewSearchFacesRequest() (request *SearchFacesRequest)
func (*SearchFacesRequest) FromJsonString ¶
func (r *SearchFacesRequest) FromJsonString(s string) error
func (*SearchFacesRequest) ToJsonString ¶
func (r *SearchFacesRequest) ToJsonString() string
type SearchFacesResponse ¶
type SearchFacesResponse struct {
*tchttp.BaseResponse
Response *struct {
// 识别结果。
Results []*Result `json:"Results,omitempty" name:"Results" list`
// 搜索的人员库中包含的人脸数。
FaceNum *uint64 `json:"FaceNum,omitempty" name:"FaceNum"`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewSearchFacesResponse ¶
func NewSearchFacesResponse() (response *SearchFacesResponse)
func (*SearchFacesResponse) FromJsonString ¶
func (r *SearchFacesResponse) FromJsonString(s string) error
func (*SearchFacesResponse) ToJsonString ¶
func (r *SearchFacesResponse) ToJsonString() string
type SearchFacesReturnsByGroupRequest ¶
type SearchFacesReturnsByGroupRequest struct {
*tchttp.BaseRequest
// 希望搜索的人员库列表,上限10个。
GroupIds []*string `json:"GroupIds,omitempty" name:"GroupIds" list`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 最多识别的人脸数目。默认值为1(仅检测图片中面积最大的那张人脸),最大值为10。
// MaxFaceNum用于,当输入的待识别图片包含多张人脸时,设定要搜索的人脸的数量。
// 例:输入的Image或Url中的图片包含多张人脸,设MaxFaceNum=5,则会识别图片中面积最大的5张人脸。
MaxFaceNum *uint64 `json:"MaxFaceNum,omitempty" name:"MaxFaceNum"`
// 人脸长和宽的最小尺寸,单位为像素。默认为80。低于40将影响搜索精度。建议设置为80。
MinFaceSize *uint64 `json:"MinFaceSize,omitempty" name:"MinFaceSize"`
// 被检测到的人脸,对应最多返回的最相似人员数目。默认值为5,最大值为10。
// 例,设MaxFaceNum为3,MaxPersonNum为5,则最多可能返回3*5=15个人员。
MaxPersonNumPerGroup *uint64 `json:"MaxPersonNumPerGroup,omitempty" name:"MaxPersonNumPerGroup"`
// 是否返回人员具体信息。0 为关闭,1 为开启。默认为 0。其他非0非1值默认为0
NeedPersonInfo *int64 `json:"NeedPersonInfo,omitempty" name:"NeedPersonInfo"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
// 出参Score中,只有大于等于FaceMatchThreshold值的结果才会返回。
// 默认为0。
// 取值范围[0.0,100.0) 。
FaceMatchThreshold *float64 `json:"FaceMatchThreshold,omitempty" name:"FaceMatchThreshold"`
}
func NewSearchFacesReturnsByGroupRequest ¶
func NewSearchFacesReturnsByGroupRequest() (request *SearchFacesReturnsByGroupRequest)
func (*SearchFacesReturnsByGroupRequest) FromJsonString ¶
func (r *SearchFacesReturnsByGroupRequest) FromJsonString(s string) error
func (*SearchFacesReturnsByGroupRequest) ToJsonString ¶
func (r *SearchFacesReturnsByGroupRequest) ToJsonString() string
type SearchFacesReturnsByGroupResponse ¶
type SearchFacesReturnsByGroupResponse struct {
*tchttp.BaseResponse
Response *struct {
// 搜索的人员库中包含的人脸数。
FaceNum *uint64 `json:"FaceNum,omitempty" name:"FaceNum"`
// 识别结果。
ResultsReturnsByGroup []*ResultsReturnsByGroup `json:"ResultsReturnsByGroup,omitempty" name:"ResultsReturnsByGroup" list`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewSearchFacesReturnsByGroupResponse ¶
func NewSearchFacesReturnsByGroupResponse() (response *SearchFacesReturnsByGroupResponse)
func (*SearchFacesReturnsByGroupResponse) FromJsonString ¶
func (r *SearchFacesReturnsByGroupResponse) FromJsonString(s string) error
func (*SearchFacesReturnsByGroupResponse) ToJsonString ¶
func (r *SearchFacesReturnsByGroupResponse) ToJsonString() string
type SearchPersonsRequest ¶
type SearchPersonsRequest struct {
*tchttp.BaseRequest
// 希望搜索的人员库列表,上限100个。
GroupIds []*string `json:"GroupIds,omitempty" name:"GroupIds" list`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 最多识别的人脸数目。默认值为1(仅检测图片中面积最大的那张人脸),最大值为10。
// MaxFaceNum用于,当输入的待识别图片包含多张人脸时,设定要搜索的人脸的数量。
// 例:输入的Image或Url中的图片包含多张人脸,设MaxFaceNum=5,则会识别图片中面积最大的5张人脸。
MaxFaceNum *uint64 `json:"MaxFaceNum,omitempty" name:"MaxFaceNum"`
// 人脸长和宽的最小尺寸,单位为像素。默认为80。低于40将影响搜索精度。建议设置为80。
MinFaceSize *uint64 `json:"MinFaceSize,omitempty" name:"MinFaceSize"`
// 单张被识别的人脸返回的最相似人员数量。默认值为5,最大值为100。
// 例,设MaxFaceNum为1,MaxPersonNum为8,则返回Top8相似的人员信息。
// 值越大,需要处理的时间越长。建议不要超过10。
MaxPersonNum *uint64 `json:"MaxPersonNum,omitempty" name:"MaxPersonNum"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
// 出参Score中,只有大于等于FaceMatchThreshold值的结果才会返回。默认为0。取值范围[0.0,100.0) 。
FaceMatchThreshold *float64 `json:"FaceMatchThreshold,omitempty" name:"FaceMatchThreshold"`
}
func NewSearchPersonsRequest ¶
func NewSearchPersonsRequest() (request *SearchPersonsRequest)
func (*SearchPersonsRequest) FromJsonString ¶
func (r *SearchPersonsRequest) FromJsonString(s string) error
func (*SearchPersonsRequest) ToJsonString ¶
func (r *SearchPersonsRequest) ToJsonString() string
type SearchPersonsResponse ¶
type SearchPersonsResponse struct {
*tchttp.BaseResponse
Response *struct {
// 识别结果。
Results []*Result `json:"Results,omitempty" name:"Results" list`
// 搜索的人员库中包含的人员数。若输入图片中所有人脸均不符合质量要求,则返回0。
PersonNum *uint64 `json:"PersonNum,omitempty" name:"PersonNum"`
// 人脸识别所用的算法模型版本。
// 注意:此字段可能返回 null,表示取不到有效值。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewSearchPersonsResponse ¶
func NewSearchPersonsResponse() (response *SearchPersonsResponse)
func (*SearchPersonsResponse) FromJsonString ¶
func (r *SearchPersonsResponse) FromJsonString(s string) error
func (*SearchPersonsResponse) ToJsonString ¶
func (r *SearchPersonsResponse) ToJsonString() string
type SearchPersonsReturnsByGroupRequest ¶
type SearchPersonsReturnsByGroupRequest struct {
*tchttp.BaseRequest
// 希望搜索的人员库列表,上限10个。
GroupIds []*string `json:"GroupIds,omitempty" name:"GroupIds" list`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 最多识别的人脸数目。默认值为1(仅检测图片中面积最大的那张人脸),最大值为10。
// MaxFaceNum用于,当输入的待识别图片包含多张人脸时,设定要搜索的人脸的数量。
// 例:输入的Image或Url中的图片包含多张人脸,设MaxFaceNum=5,则会识别图片中面积最大的5张人脸。
MaxFaceNum *uint64 `json:"MaxFaceNum,omitempty" name:"MaxFaceNum"`
// 人脸长和宽的最小尺寸,单位为像素。默认为80。低于40将影响搜索精度。建议设置为80。
MinFaceSize *uint64 `json:"MinFaceSize,omitempty" name:"MinFaceSize"`
// 被检测到的人脸,对应最多返回的最相似人员数目。默认值为5,最大值为10。
// 例,设MaxFaceNum为3,MaxPersonNumPerGroup为5,GroupIds长度为3,则最多可能返回3*5*3=45个人员。
MaxPersonNumPerGroup *uint64 `json:"MaxPersonNumPerGroup,omitempty" name:"MaxPersonNumPerGroup"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
// 出参Score中,只有超过FaceMatchThreshold值的结果才会返回。默认为0。
FaceMatchThreshold *float64 `json:"FaceMatchThreshold,omitempty" name:"FaceMatchThreshold"`
}
func NewSearchPersonsReturnsByGroupRequest ¶
func NewSearchPersonsReturnsByGroupRequest() (request *SearchPersonsReturnsByGroupRequest)
func (*SearchPersonsReturnsByGroupRequest) FromJsonString ¶
func (r *SearchPersonsReturnsByGroupRequest) FromJsonString(s string) error
func (*SearchPersonsReturnsByGroupRequest) ToJsonString ¶
func (r *SearchPersonsReturnsByGroupRequest) ToJsonString() string
type SearchPersonsReturnsByGroupResponse ¶
type SearchPersonsReturnsByGroupResponse struct {
*tchttp.BaseResponse
Response *struct {
// 搜索的人员库中包含的人员数。若输入图片中所有人脸均不符合质量要求,则返回0。
PersonNum *uint64 `json:"PersonNum,omitempty" name:"PersonNum"`
// 识别结果。
ResultsReturnsByGroup []*ResultsReturnsByGroup `json:"ResultsReturnsByGroup,omitempty" name:"ResultsReturnsByGroup" list`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewSearchPersonsReturnsByGroupResponse ¶
func NewSearchPersonsReturnsByGroupResponse() (response *SearchPersonsReturnsByGroupResponse)
func (*SearchPersonsReturnsByGroupResponse) FromJsonString ¶
func (r *SearchPersonsReturnsByGroupResponse) FromJsonString(s string) error
func (*SearchPersonsReturnsByGroupResponse) ToJsonString ¶
func (r *SearchPersonsReturnsByGroupResponse) ToJsonString() string
type VerifyFaceRequest ¶
type VerifyFaceRequest struct {
*tchttp.BaseRequest
// 待验证的人员ID。人员ID具体信息请参考人员库管理相关接口。
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 图片 base64 数据,base64 编码后大小不可超过5M。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
// Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
}
func NewVerifyFaceRequest ¶
func NewVerifyFaceRequest() (request *VerifyFaceRequest)
func (*VerifyFaceRequest) FromJsonString ¶
func (r *VerifyFaceRequest) FromJsonString(s string) error
func (*VerifyFaceRequest) ToJsonString ¶
func (r *VerifyFaceRequest) ToJsonString() string
type VerifyFaceResponse ¶
type VerifyFaceResponse struct {
*tchttp.BaseResponse
Response *struct {
// 给定的人脸图片与 PersonId 对应人脸的相似度。若 PersonId 下有多张人脸(Face),返回相似度最大的分数。
//
// 不同算法版本返回的相似度分数不同。
// 若需要验证两张图片中人脸是否为同一人,3.0版本误识率千分之一对应分数为40分,误识率万分之一对应分数为50分,误识率十万分之一对应分数为60分。 一般超过50分则可认定为同一人。
// 2.0版本误识率千分之一对应分数为70分,误识率万分之一对应分数为80分,误识率十万分之一对应分数为90分。 一般超过80分则可认定为同一人。
Score *float64 `json:"Score,omitempty" name:"Score"`
// 是否为同一人的判断。
IsMatch *bool `json:"IsMatch,omitempty" name:"IsMatch"`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewVerifyFaceResponse ¶
func NewVerifyFaceResponse() (response *VerifyFaceResponse)
func (*VerifyFaceResponse) FromJsonString ¶
func (r *VerifyFaceResponse) FromJsonString(s string) error
func (*VerifyFaceResponse) ToJsonString ¶
func (r *VerifyFaceResponse) ToJsonString() string
type VerifyPersonRequest ¶
type VerifyPersonRequest struct {
*tchttp.BaseRequest
// 图片 base64 数据。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Image *string `json:"Image,omitempty" name:"Image"`
// 图片的 Url 。 图片的 Url、Image必须提供一个,如果都提供,只使用 Url。
// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
// 非腾讯云存储的Url速度和稳定性可能受一定影响。
// 若图片中包含多张人脸,只选取其中人脸面积最大的人脸。
// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
Url *string `json:"Url,omitempty" name:"Url"`
// 待验证的人员ID。人员ID具体信息请参考人员库管理相关接口。
PersonId *string `json:"PersonId,omitempty" name:"PersonId"`
// 图片质量控制。
// 0: 不进行控制;
// 1:较低的质量要求,图像存在非常模糊,眼睛鼻子嘴巴遮挡至少其中一种或多种的情况;
// 2: 一般的质量要求,图像存在偏亮,偏暗,模糊或一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,至少其中三种的情况;
// 3: 较高的质量要求,图像存在偏亮,偏暗,一般模糊,眉毛遮挡,脸颊遮挡,下巴遮挡,其中一到两种的情况;
// 4: 很高的质量要求,各个维度均为最好或最多在某一维度上存在轻微问题;
// 默认 0。
// 若图片质量不满足要求,则返回结果中会提示图片质量检测不符要求。
QualityControl *uint64 `json:"QualityControl,omitempty" name:"QualityControl"`
}
func NewVerifyPersonRequest ¶
func NewVerifyPersonRequest() (request *VerifyPersonRequest)
func (*VerifyPersonRequest) FromJsonString ¶
func (r *VerifyPersonRequest) FromJsonString(s string) error
func (*VerifyPersonRequest) ToJsonString ¶
func (r *VerifyPersonRequest) ToJsonString() string
type VerifyPersonResponse ¶
type VerifyPersonResponse struct {
*tchttp.BaseResponse
Response *struct {
// 给定的人脸照片与 PersonId 对应的相似度。若 PersonId 下有多张人脸(Face),会融合多张人脸信息进行验证。
Score *float64 `json:"Score,omitempty" name:"Score"`
// 是否为同一人的判断。
IsMatch *bool `json:"IsMatch,omitempty" name:"IsMatch"`
// 人脸识别所用的算法模型版本。
FaceModelVersion *string `json:"FaceModelVersion,omitempty" name:"FaceModelVersion"`
// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
} `json:"Response"`
}
func NewVerifyPersonResponse ¶
func NewVerifyPersonResponse() (response *VerifyPersonResponse)
func (*VerifyPersonResponse) FromJsonString ¶
func (r *VerifyPersonResponse) FromJsonString(s string) error
func (*VerifyPersonResponse) ToJsonString ¶
func (r *VerifyPersonResponse) ToJsonString() string