调用QueryVideoQualityJob查询视频质量审核作业的状态与结果。

使用说明

  • 本接口目前支持的地域为华东2(上海)。
  • 本接口通过视频质量审核作业的ID对作业结果进行查询。

QPS限制

本接口的单用户QPS限制为50次/秒。超过限制,API调用会被限流,这可能会影响您的业务,请合理调用。更多信息,请参见QPS限制

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

请求参数

名称 类型 是否必选 示例值 描述
Action String QueryVideoQualityJob

系统规定参数,取值:QueryVideoQualityJob

UserId Long 125340688170****

用户ID。可以通过MPS控制台顶部导航栏左侧单击头像查看。

JobId String 7c2abbb270474c98823dac56cc06****

需要查询的视频质量审核作业ID。可以从提交视频质量审核作业的返回参数中获取。

返回数据

名称 类型 示例值 描述
Message String The job is completed successfully

作业信息。

RequestId String 5210DBB0-E327-4D45-ADBC-0B83C8796E26

请求ID。

Job Object

作业详情。

Status String Success

作业状态。可取值:

  • Success:处理成功。
  • Fail:处理失败。
  • Processing:处理中。
  • Submitted:已提交等待处理。
JobId String 0c8f04aa60bd4377a906bd6c91ec****

作业ID。

UserId Long 125340688170****

用户ID。

VideoQualityResults String {"LessExpose":[{"Ratio":"0.917673658134****","TimeStamp":"00:00:10.0"}],"Noise":[{"Ratio":"0.0419343847352","TimeStamp":"00:00:05.0"}],"ImageDefinition":[{"TimeStamp":"00:00:05.0"},{"TimeStamp":"00:00:10.0"}],"Border":[{"TimeStamp":"00:00:05.0"},{"TimeStamp":"00:00:10.0"}],"Freeze":[{"Score":"1","TimeStamp":"00:00:00.233"},{"Score":"1","TimeStamp":"00:00:02.600"},{"Score":"1","TimeStamp":"00:00:02.900"},{"Score":"1","TimeStamp":"00:00:02.933"},{"Score":"1","TimeStamp":"00:00:03.400"},{"Score":"1","TimeStamp":"00:00:05.166"},{"Score":"1","TimeStamp":"00:00:05.800"},{"Score":"1","TimeStamp":"00:00:07.700"},{"Score":"1","TimeStamp":"00:00:07.800"},{"Score":"1","TimeStamp":"00:00:08.633"},{"Score":"1","TimeStamp":"00:00:08.833"},{"Score":"1","TimeStamp":"00:00:09.0"}]}

审核结果摘要,有质量问题的图片信息列表,不含坐标信息。

Message String The job is completed successfully

作业信息。

Output String oss://example-bucket-****.oss-cn-shanghai.aliyuncs.com/example1.txt

审核结果汇总,存放于用户提供的输出文件OSS地址。例如:oss://example-bucket-****.oss-cn-shanghai.aliyuncs.com/example1.txt,用户根据需要解析。

说明 格式示例: {"审核标签一":[ {问题帧一}, {问题帧二}, ... , {问题帧N}]} {"审核标签二":[ {问题帧一}, {问题帧二}, ... , {问题帧N}]} ... {"审核标签N":[ {问题帧一}, {问题帧二}, ... , {问题帧N}]}
Code String Success

错误码。请求成功时返回Success。

VideoQualityResults示例


"VideoQualityResults":{
  "Blockness":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Score":"0.33"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Score":"0.66"
     }
  ],
  "Brightness":[
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Result":"white",
        "Score":"0.33"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Result":"white",
        "Score":"0.66"
     }
  ],
  "Freeze":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Score":"0.33"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Score":"0.66"
     }
  ],
  "ImageDefinition":[
     {
       "TimeStamp":"hh:mm:ss[.SSS]"
     },
     {
       "TimeStamp":"hh:mm:ss[.SSS]",
     }
  ],
  "LessExpose":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Ratio":"0.33"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Ratio":"0.66"
     }
  ],
  "OverExpose":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Ratio":"0.33"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Ratio":"0.66"
     }
  ],
  "Border":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]"
     }
  ],
  "Noise":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Ratio":"0.33"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]",
        "Ratio":"0.66"
     }
  ],
  "Mosaic":[
      {
        "TimeStamp":"hh:mm:ss[.SSS]"
     },
     {
        "TimeStamp":"hh:mm:ss[.SSS]"
     }
  ]
  }

Output示例


{
	"brightness": [{
		"result": "dark",
		"score": -2.5150070190429688,
		"timestamp": "5520",
		"type": "brightness"
	}, {
		"result": "dark",
		"score": -2.1238651275634766,
		"timestamp": "344000",
		"type": "brightness"
	}]
} {
	"blockness": [{
		"result": "blocking",
		"score": 4.1806020736694336,
		"timestamp": "160",
		"type": "blockness"
	}, {
		"result": "blocking",
		"score": 4.515049934387207,
		"timestamp": "240",
		"type": "blockness"
	}]
} {
	"freeze": [{
		"result": "freeze",
		"score": 4.1445174217224121,
		"timestamp": "202240",
		"type": "freeze"
	}]
} {
	"border": [{
		"border": [0, 0, 1280, 720],
		"id": 25,
		"timestamp": 1000.0
	}, {
		"border": [1, 0, 1279, 720],
		"id": 50,
		"timestamp": 2000.0
	}]
} {
	"mosaic": [{
		"box": [
			[294, 59, 328, 93],
			[124, 98, 168, 142],
			[268, 109, 300, 141],
			[162, 109, 194, 141],
			[268, 76, 300, 108],
			[162, 59, 194, 91],
			[94, 73, 130, 109],
			[94, 28, 130, 64],
			[294, 94, 328, 128],
			[222, 21, 266, 65],
			[203, 21, 247, 65],
			[241, 33, 273, 65],
			[190, 59, 220, 89],
			[333, 59, 367, 93],
			[314, 59, 358, 103],
			[124, 53, 168, 97],
			[361, 59, 391, 89],
			[1029, 77, 1057, 105],
			[349, 59, 379, 89]
		],
		"id": 25,
		"timestamp": 1000.0
	}, {
		"box": [
			[241, 33, 273, 65],
			[228, 33, 260, 65],
			[189, 81, 221, 113],
			[336, 75, 366, 105],
			[254, 21, 298, 65],
			[163, 60, 205, 102],
			[320, 59, 354, 93],
			[125, 97, 169, 141],
			[221, 39, 247, 65]
		],
		"id": 50,
		"timestamp": 2000.0
	}]
} {
	"over_expose": [{
		"ratio": "0.97276288701703",
		"id": 25,
		"timestamp": 1000.0
	}, {
		"ratio": "0.8629491725526869",
		"id": 50,
		"timestamp": 2000.0
	}]
}

视频质量审核结果算法各字段含义

花屏识别(blockness)

字段

含义

result

检测结果:blocking和normal

score

结果置信度

timestamp

问题帧发生时间,单位:ms。

黑屏、白屏(brightness)

字段

含义

result

检测结果:dark,bright,black,white,normal

score

结果置信度

timestamp

问题帧发生时间,单位:ms。

静帧(freeze)

字段

含义

result

检测结果:freeze,normal

score

结果置信度

timestamp

问题帧发生时间,单位:ms。

模糊识别(image_definition)

字段

含义

id

问题帧

timestamp

问题帧发生时间,单位:ms。

低光照识别(less_expose)

字段

含义

ratio

欠曝比例

id

问题帧

timestamp

问题帧发生时间,单位:ms。

过曝光识别(over_expose)

字段

含义

ratio

过曝比例

id

问题帧

timestamp

问题帧发生时间,单位:ms。

黑边、白边(border)

字段

含义

border

图片的位置 [x1,y1,x2,y2]

id

问题帧

timestamp

问题帧发生时间,单位:ms。

马赛克识别(mosaic)

字段

含义

box

马赛克位置[x1,y1,x2,y2]

id

问题帧

timestamp

问题帧发生时间,单位:ms。

雪花/噪点识别(noise)

字段

含义

noise_rate

噪声比例

id

问题帧

timestamp

问题帧发生时间,单位:ms。

示例

请求示例

http(s)://mts.cn-shanghai.aliyuncs.com/?Action=QueryVideoQualityJob
&JobId=7c2abbb270474c98823dac56cc06****
&<公共请求参数>

正常返回示例

XML格式

HTTP/1.1 200 OK
Content-Type:application/xml

<QueryVideoQualityJobResponse>
    <Message>The job is completed successfully</Message>
    <RequestId>5210DBB0-E327-4D45-ADBC-0B83C8796E26</RequestId>
    <Job>
        <Status>Success</Status>
        <JobId>0c8f04aa60bd4377a906bd6c91ec****</JobId>
        <VideoQualityResults>{"LessExpose":[{"Ratio":"0.917673658134****","TimeStamp":"00:00:10.0"}],"Noise":[{"Ratio":"0.0419343847352","TimeStamp":"00:00:05.0"}],"ImageDefinition":[{"TimeStamp":"00:00:05.0"},{"TimeStamp":"00:00:10.0"}],"Border":[{"TimeStamp":"00:00:05.0"},{"TimeStamp":"00:00:10.0"}],"Freeze":[{"Score":"1","TimeStamp":"00:00:00.233"},{"Score":"1","TimeStamp":"00:00:02.600"},{"Score":"1","TimeStamp":"00:00:02.900"},{"Score":"1","TimeStamp":"00:00:02.933"},{"Score":"1","TimeStamp":"00:00:03.400"},{"Score":"1","TimeStamp":"00:00:05.166"},{"Score":"1","TimeStamp":"00:00:05.800"},{"Score":"1","TimeStamp":"00:00:07.700"},{"Score":"1","TimeStamp":"00:00:07.800"},{"Score":"1","TimeStamp":"00:00:08.633"},{"Score":"1","TimeStamp":"00:00:08.833"},{"Score":"1","TimeStamp":"00:00:09.0"}]}</VideoQualityResults>
        <Message>The job is completed successfully</Message>
        <Output>oss://example-bucket-****.oss-cn-shanghai.aliyuncs.com/example1.txt</Output>
    </Job>
    <Code>Success</Code>
</QueryVideoQualityJobResponse>

JSON格式

HTTP/1.1 200 OK
Content-Type:application/json

{
  "Message" : "The job is completed successfully",
  "RequestId" : "5210DBB0-E327-4D45-ADBC-0B83C8796E26",
  "Job" : {
    "Status" : "Success",
    "JobId" : "0c8f04aa60bd4377a906bd6c91ec****",
    "VideoQualityResults" : "{\"LessExpose\":[{\"Ratio\":\"0.917673658134****\",\"TimeStamp\":\"00:00:10.0\"}],\"Noise\":[{\"Ratio\":\"0.0419343847352\",\"TimeStamp\":\"00:00:05.0\"}],\"ImageDefinition\":[{\"TimeStamp\":\"00:00:05.0\"},{\"TimeStamp\":\"00:00:10.0\"}],\"Border\":[{\"TimeStamp\":\"00:00:05.0\"},{\"TimeStamp\":\"00:00:10.0\"}],\"Freeze\":[{\"Score\":\"1\",\"TimeStamp\":\"00:00:00.233\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:02.600\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:02.900\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:02.933\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:03.400\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:05.166\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:05.800\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:07.700\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:07.800\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:08.633\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:08.833\"},{\"Score\":\"1\",\"TimeStamp\":\"00:00:09.0\"}]}",
    "Message" : "The job is completed successfully",
    "Output" : "oss://example-bucket-****.oss-cn-shanghai.aliyuncs.com/example1.txt"
  },
  "Code" : "Success"
}

错误码

访问错误中心查看更多错误码。