WO2018187917A1 - 图片质量评估方法及装置 - Google Patents
图片质量评估方法及装置 Download PDFInfo
- Publication number
- WO2018187917A1 WO2018187917A1 PCT/CN2017/079975 CN2017079975W WO2018187917A1 WO 2018187917 A1 WO2018187917 A1 WO 2018187917A1 CN 2017079975 W CN2017079975 W CN 2017079975W WO 2018187917 A1 WO2018187917 A1 WO 2018187917A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- picture
- preprocessed
- video file
- edge
- quality evaluation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/13—Edge detection
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/136—Segmentation; Edge detection involving thresholding
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10016—Video; Image sequence
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30168—Image quality inspection
Definitions
- the present invention relates to the field of image processing, and in particular, to a picture quality evaluation method and apparatus.
- Video files in formats such as 360-degree video files and 3D video files do not have a uniform file identifier. Many players recognize whether the video file is in a 360-degree video format or a 3D video format by intercepting a picture frame in the video file. However, in the process of intercepting the picture frame, sometimes the picture with the solid color, the large area solid color or the low contrast is intercepted. This picture is not suitable as the basis for identifying the video type, and the picture frame needs to be re-interpreted after the recognition calculation. Recognizing again, resulting in a reduction in the efficiency of video format recognition.
- the embodiment of the invention discloses a picture quality evaluation method and device, which improves the efficiency of video format recognition.
- an embodiment of the present invention discloses a picture quality evaluation method, including:
- the first picture is used to determine a target video file type when the N is greater than or equal to a first threshold.
- an embodiment of the present invention discloses a picture quality evaluation apparatus, including:
- a first acquiring module configured to acquire a first picture
- a processing module configured to perform pre-processing on the first picture to obtain a pre-processed picture
- a detecting module configured to perform edge detection on the preprocessed picture to count the number N of edge points,
- the N is a positive integer
- a determining module configured to use the first picture to determine a target video file type when the N is greater than or equal to the first threshold.
- an embodiment of the present invention discloses a picture quality evaluation apparatus, including:
- a processor coupled to the memory
- the processor invokes the executable program code stored in the memory to perform all or part of the steps of the first aspect.
- the first picture is obtained from the video file; secondly, the first picture is preprocessed to obtain a preprocessed picture; and again, the preprocessed picture is performed.
- Edge detection to count the number N of edge points, the N is a positive integer; when the N is greater than or equal to the first threshold, the first picture is used to determine the target video file type.
- the solution of the embodiment of the invention improves the efficiency of video format recognition.
- FIG. 1 is a schematic flowchart of a picture quality evaluation method according to an embodiment of the present invention.
- FIG. 2 is a schematic diagram of pixel points of a picture
- FIG. 3 is a schematic diagram of another picture pixel point
- FIG. 4 is a schematic flowchart diagram of another picture quality evaluation method according to an embodiment of the present disclosure.
- FIG. 5 is a schematic structural diagram of a picture quality evaluation method according to an embodiment of the present invention.
- FIG. 6 is a schematic structural diagram showing a partial structure of a picture quality evaluation method according to an embodiment of the present disclosure
- FIG. 7 is a schematic partial structural diagram of a picture quality evaluation method according to an embodiment of the present invention.
- FIG. 8 is a schematic structural diagram of another picture quality evaluation method according to an embodiment of the present invention.
- FIG. 1 is a schematic flowchart diagram of an image quality evaluation method according to an embodiment of the present invention. As shown in Figure 1, the method includes:
- the picture quality evaluation apparatus acquires the first picture.
- the first picture is a frame picture in the target video file.
- the target video file is a video file of a type to be determined.
- the target video file may be a VR video file, a 3D video file, a 360-degree video file, or other video files.
- the first picture is a key frame in the target video file.
- the key frame is the frame in which the key action in the motion or change of the character or object in the target video file is located.
- the picture quality evaluation apparatus performs preprocessing on the first picture to obtain a preprocessed picture.
- the pre-processing the first picture to obtain a pre-processed picture includes:
- performing the resolution processing on the first picture by the picture quality evaluation apparatus is specifically: reducing the resolution of the first picture to a preset value, and using the reduced first picture as the second picture.
- the preset value may be 640x480, 320x180, 567x390, 626x413 or other values.
- the above preset value is 320x180.
- the picture quality evaluation apparatus performs grayscale processing on the second picture, in particular, converting the second picture from a color picture to a gray picture, and using the gray picture as the third picture.
- the above image quality evaluation apparatus performs histogram equalization processing on the third picture to make The third picture described above changes faster, avoiding that the third picture is a gradation picture and no edge is detected.
- the picture quality evaluation apparatus performs edge detection on the preprocessed picture to count the number N of edge points, where N is a positive integer.
- the performing edge detection on the preprocessed picture to count the number N of edge points includes:
- Edge detection is performed on M pixel points in the preset area of the preprocessed picture to obtain M detection values, and the M detection values are in one-to-one correspondence with the M pixel points;
- a pixel point corresponding to the second threshold value of the M detection values is used as an edge point to count the number N of edge points, and the M is greater than or equal to N.
- FIG. 2 is a schematic diagram of pixel points of a preprocessed picture.
- the black point is the pixel of the preprocessed picture.
- FIG. 2 there are n columns of pixels on the horizontal axis and m rows of pixels on the vertical axis, and the size of the preprocessed picture may be mxn.
- the preset region from the m-th row may be between 1 to 2 m-th row region in FIG. 2, FIG. 2 may also be in the region from the first column to the n 1 n 2 between the second column, may also FIG. 2 in between the m-th row to the m-th row 1 and column 2 intersection region between n 1 to n 2 of the second column.
- the above m 1 is greater than or equal to 0 and less than or equal to m-2, and the above m 2 is greater than or equal to 1 and less than or equal to m-1.
- the above n 1 is greater than or equal to 0 and less than or equal to n-2, and the above n 2 is greater than or equal to 1 and less than or equal to n-1.
- the magnitudes of the above m 1 , m 2 , n 1 , and n 2 may be set according to the size of the preprocessed picture.
- the preset area is the area between the 45th line and the 274th line in FIG. 3, that is, the 45th line and the last number in the picture shown in FIG. The area between 45 lines.
- the picture quality evaluation apparatus After determining the preset area, the picture quality evaluation apparatus obtains the detection values one by one for the M pixel points in the preset area to obtain M detection values. The image quality evaluation apparatus then compares the M detection values one by one with the second threshold. If the detected value A is greater than the second threshold, the pixel corresponding to the detected value A is taken as an edge point. The detected value A is any one of the M detection values. Finally, the picture quality evaluation device counts the number of edge points to obtain the number N of edge points.
- performing edge detection on M pixel points in a preset area of the preprocessed picture Testing including:
- Edge detection is performed on M pixel points in a preset area of the preprocessed picture by a detection operator.
- the above image quality evaluation device may also pass a Prewitt operator, a Canny operator, a Roberts operator, a Sobel operator, and Krisch.
- An operator or other operator performs edge detection on M pixels in the preset area of the preprocessed picture.
- the picture quality evaluation apparatus uses the first picture to determine a target video file type.
- the method when the N is less than the first threshold, the method includes:
- the picture quality evaluation apparatus may use the first picture corresponding to the pre-processed picture to confirm the type of the target video file. If it is determined that the above N is smaller than the first threshold, the picture quality evaluation apparatus acquires the fourth picture, and performs the processes described in the above steps S102-S104 again.
- the fourth picture is a frame picture different from the first picture in the target video file, and the fourth picture is a key frame in the target video file.
- the value of the first threshold is determined according to the size of the preprocessed picture.
- the first threshold may be 1280 or other values.
- the first picture is obtained from the video file; secondly, the first picture is preprocessed to obtain a preprocessed picture; and again, the preprocessed picture is performed.
- Edge detection to count the number N of edge points, the N is a positive integer; when the N is greater than or equal to the first threshold, the first picture is used to determine the target video file type.
- the solution of the embodiment of the invention improves the efficiency of video format recognition.
- FIG. 4 is a flowchart showing another method for evaluating picture quality according to an embodiment of the present invention. intention. As shown in FIG. 4, the method includes:
- the picture quality evaluation apparatus acquires the first picture.
- the picture quality evaluation apparatus performs resolution processing on the first picture to obtain a second picture.
- the second picture of the picture quality evaluation apparatus performs grayscale processing to obtain a third picture.
- the third picture of the picture quality evaluation apparatus performs histogram equalization processing to obtain a preprocessed picture.
- the picture quality evaluation apparatus performs edge detection on the M pixel points in the preset area of the preprocessed picture, and acquires M detection values.
- the picture quality evaluation apparatus determines whether the M pixel points are edge points one by one, and counts the number N of edge points.
- the picture quality evaluation apparatus determines whether the N is greater than or equal to a first threshold.
- the picture quality evaluation apparatus performs step S408; otherwise, the picture quality evaluation apparatus performs step S409.
- the picture quality evaluation apparatus uses the first picture to determine a type of the target video file.
- the picture quality evaluation apparatus acquires a fourth picture, and performs the above steps S402-S407 again.
- FIG. 5 is a schematic structural diagram of a picture quality evaluation apparatus according to an embodiment of the present invention. As shown in FIG. 5, the apparatus 500 includes:
- the first obtaining module 501 is configured to acquire a first picture.
- the first picture is a frame of pictures in the target video file.
- the first picture is a key frame in the target video file.
- the processing module 502 is configured to perform pre-processing on the first picture to obtain a pre-processed picture.
- processing module 502 includes:
- the first processing unit 5021 is configured to perform resolution processing on the target image to obtain a second image.
- a second processing unit 5022 configured to perform grayscale processing on the second picture to obtain a third picture
- the third processing unit 5023 is configured to perform a histogram equalization process on the third picture to obtain a pre-processed picture.
- the detecting module 503 is configured to perform edge detection on the preprocessed picture to count the number N of edge points, where N is a positive integer.
- the detecting module 503 further includes:
- the detecting unit 5031 is configured to perform edge detection on the M pixel points in the preset area of the preprocessed picture to obtain M detection values, where the M detection values are in one-to-one correspondence with the M pixel points;
- the statistic unit 5032 is configured to use a pixel point corresponding to the second threshold value of the M detection values as an edge point to count the number N of edge points, where the M is greater than or equal to N.
- the detecting mode 303 is specifically configured to: perform edge detection on M pixel points in a preset area of the preprocessed picture by using a detection operator.
- the determining module 504 is configured to use the first picture to determine a target video file type when the N is greater than or equal to the first threshold.
- the apparatus 500 when the N is less than the first threshold, the apparatus 500 includes:
- the second obtaining module 505 is configured to obtain a fourth picture, where the fourth picture is a frame picture different from the first picture in the target video file, and the picture quality evaluation operation is performed again based on the fourth picture.
- each of the above modules (the first obtaining module 501, the processing module 502, the detecting module 503, the determining module 504, and the second acquiring module 505) is configured to execute the related steps of the method for determining the driving trajectory.
- the “module” in this embodiment may be an application-specific integrated circuit (ASIC), a processor and memory that executes one or more software or firmware programs, integrated logic circuits, and/or others that may provide the above functions.
- ASIC application-specific integrated circuit
- the first acquiring module 501, The processing module 502, the detecting module 503, the determining module 504, and the second obtaining module 505 can be implemented by a processor in the apparatus 800 described in FIG.
- the picture quality evaluation apparatus can be implemented by the structure in FIG.
- the apparatus 800 includes at least one processor 801, at least one memory 802, and at least one communication interface 803.
- the device may also include general components such as an antenna, which will not be described in detail herein.
- the processor 801 can be a general purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the above program.
- CPU central processing unit
- ASIC application-specific integrated circuit
- the communication interface 803 is configured to communicate with other devices or communication networks, such as Ethernet, Radio Access Network (RAN), Wireless Local Area Networks (WLAN), and the like.
- RAN Radio Access Network
- WLAN Wireless Local Area Networks
- the memory 802 can be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM) or other type that can store information and instructions.
- the dynamic storage device can also be an Electrically Erasable Programmable Read-Only Memory (EEPROM), a Compact Disc Read-Only Memory (CD-ROM) or other optical disc storage, and a disc storage device. (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or can be used to carry or store desired program code in the form of instructions or data structures and can be Any other media accessed, but not limited to this.
- the memory can exist independently and be connected to the processor via a bus.
- the memory can also be integrated with the processor.
- the memory 802 is configured to store application code that executes the above solution, and is controlled by the processor 801 for execution.
- the processor 801 is configured to execute application code stored in the memory 802.
- the picture quality evaluation apparatus shown in FIG. 8 the code stored in the memory 802 can perform the image quality evaluation method provided above, for example, the picture quality evaluation apparatus acquires the first picture; and preprocesses the first picture to obtain a preprocessed picture; Edge detection is performed on the preprocessed picture to count the number N of edge points, where N is a positive integer; when the N is greater than or equal to the first threshold, the first picture is used to determine a target video file. Types of.
- the embodiment of the present invention further provides a computer storage medium, wherein the computer storage medium may store a program, and the program includes some or all of the steps of any one of the picture quality evaluation methods described in the foregoing method embodiments.
- the disclosed apparatus may be implemented in other ways.
- the device embodiments described above are merely illustrative.
- the division of the unit is only a logical function division.
- there may be another division manner for example, multiple units or components may be combined or may be Integrate into another system, or some features can be ignored or not executed.
- the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be electrical or otherwise.
- the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
- each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
- the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
- the integrated unit if implemented in the form of a software functional unit and sold or used as a standalone product, may be stored in a computer readable memory. Based on such understanding, the technical solution of the present invention may contribute to the prior art or all or part of the technical solution may be embodied in the form of a software product stored in a memory. A number of instructions are included to cause a computer device (which may be a personal computer, server or network device, etc.) to perform all or part of the steps of the methods of the various embodiments of the present invention.
- the foregoing memory includes: a U disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk, and the like, which can store program codes.
- ROM Read-Only Memory
- RAM Random Access Memory
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Image Analysis (AREA)
Abstract
一种图像质量评估方法及装置,所述方法包括:获取第一图片(S101);对所述第一图片进行预处理,得到预处理图片(S102);对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数(S103);当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型(S104)。采用所述方法提高了视频格式识别的效率。
Description
本发明涉及图像处理领域,尤其涉及一种图片质量评估方法及装置。
近年来,随着虚拟现实(Virtual Reality,VR)技术的发展,并广泛应用于360度视频文件和3D视频文件的播放,丰富了人们的娱乐生活。
360度视频文件和3D视频文件等格式的视频文件没有统一的文件标识,很多播放器通过截取视频文件中的图片帧来识别该视频文件是否为360度视频格式或者3D视频格式。但在截取图片帧的过程中,有时候会截取到以纯色、大面积纯色为主或对比度低的图片,这种图片不适合作为识别视频类型的依据,就需要再识别计算后重新截取图片帧再次识别,造成视频格式识别效率的降低。
发明内容
本发明实施例公开一种图片质量评估方法及装置,提高了视频格式识别的效率。
第一方面,本发明实施例公开一种图片质量评估方法,包括:
获取第一图片;
对所述第一图片进行预处理,得到预处理图片;
对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数;
当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。
第二方面,本发明实施例公开一种图片质量评估装置,包括:
第一获取模块,用于获取第一图片;
处理模块,用于对所述第一图片进行预处理,得到预处理图片;
检测模块,用于对所述预处理图片进行边缘检测,以统计边缘点的个数N,
所述N为正整数;
确定模块,用于当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。
第三方面,本发明实施例公开一种图片质量评估装置,包括:
存储有可执行程序代码的存储器;
与所述存储器耦合的处理器;
所述处理器调用所述存储器中存储的所述可执行程序代码,执行第一方面的全部步骤或者部分步骤。
可以看出,在本发明实施例的方案中,首先,从视频文件中获取第一图片;其次,对所述第一图片进行预处理,得到预处理图片;再次,对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数;最后所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。与现有技术相比,本发明实施例的方案提高了视频格式识别的效率。
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为本发明实施例提供的一种图片质量评估方法的流程示意图;
图2为图片像素点的示意图;
图3为另一图片像素点的示意图;
图4为本发明实施例提供的另一种图片质量评估方法的流程示意图;
图5为本发明实施例提供的一种图片质量评估方法的结构示意图;
图6为本发明实施例提供的一种图片质量评估方法的局部结构示意图;
图7为本发明实施例提供的一种图片质量评估方法的局部结构示意图;
图8为本发明实施例提供的另一种图片质量评估方法的结构示意图。
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
请参阅图1,图1为本发明实施例提供的一种图像质量评估方法的流程示意图。如图1所示,该方法包括:
S101、图片质量评估装置获取第一图片。
其中,所述第一图片为目标视频文件中的一帧图片。该目标视频文件为待确定类型的视频文件。
可选地,上述目标视频文件可为VR视频文件、3D视频文件、360度视频文件或者其他视频文件。
进一步地,所述第一图片为目标视频文件中的关键帧。该关键帧为上述目标视频文件中的角色或者物体运动或变化中的关键动作所处的那一帧。
S102、所述图片质量评估装置对所述第一图片进行预处理,得到预处理图片。
其中,所述对所述第一图片进行预处理,得到预处理图片,包括:
对所述第一图片进行分辨率处理,得到第二图片;
对所述第二图片进行灰度化处理,得到第三图片;
对所述第三图片进行直方图均衡化处理,得到预处理图片。
具体地,上述图片质量评估装置对上述第一图片进行分辨率处理具体是将上述第一图片的分辨率降低至预设值,并将降低分辨率后的第一图片作为第二图片。
可选地,上述预设值可为640x480、320x180、567x390、626x413或者其他值。优选地,上述预设值为320x180。
具体地,上述图片质量评估装置对上述第二图片进行灰度化处理具体是将上述第二图片由彩色图片转换为灰度图片,并将该灰度图片作为第三图片。
上述图像质量评估装置对上述第三图片进行直方图均衡化处理目的是使
上述第三图片变化得更快,避免上述第三图片是渐变图片而检测不到边缘。
S103、所述图片质量评估装置对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数。
其中,所述对所述预处理图片进行边缘检测,以统计边缘点的个数N,包括:
对所述预处理图片的预设区域内的M个像素点进行边缘检测,得到M个检测值,所述M个检测值与所述M个像素点一一对应;
将所述M个检测值中大于或等于第二阈值对应的像素点作为边缘点,以统计边缘点的个数N,所述M大于或等于N。
举例说明上述预设区域,参见图2,假设图2为预处理图片的像素点示意图。其中的黑点为该预处理图片的像素点,图2中横轴上有n列像素点,纵轴上有m行像素点,则上述预处理图片的尺寸可以mxn。上述预设区域可为图2中从第m1行到第m2行之间的区域,也可为图2中从第n1列到第n2列之间的区域,还可为图2中第m1行到第m2行之间和第n1列到第n2列之间的交叉区域。
其中,上述m1大于或者等于0且小于或等于m-2,上述m2大于或者等于1且小于或等于m-1。上述n1大于或等于0且小于或等于n-2,上述n2大于或等于1且小于或等于n-1。
上述m1、m2、n1、n2的取值大小可根据上述预处理图片的尺寸进行设置。
参见图3,假设上述预处理图片的尺寸为320x180,则上述预设区域为图3中第45行到第274行之间的区域,即为图3所示的图片中第45行和倒数第45行之间的区域。
上述图片质量评估装置确定预设区域后,对该预设区域内的M个像素点逐个获取检测值,以得到M个检测值。然后上述图像质量评估装置将M个检测值逐个与第二阈值进行比较。若检测值A大于第二阈值,则将检测值A对应的像素点作为边缘点。上述检测值A为上述M个检测值中的任意一个。最后,上述图片质量评估装置统计边缘点的个数,得到边缘点的个数N。
可选地,所述对所述预处理图片的预设区域内的M个像素点进行边缘检
测,包括:
通过检测算子对所述预处理图片的预设区域内的M个像素点进行边缘检测。
可选地,上述图像质量评估装置还可通过普瑞维特(Prewitt)算子、坎尼(Canny)算子、罗伯特(Roberts)算子、索伯尔(Sobel)算子、克瑞斯(Krisch)算子或者其他算子对上述预处理图片的预设区域内的M个像素点进行边缘检测。
S104、当所述N大于或等于第一阈值时,所述图片质量评估装置将所述第一图片用于确定目标视频文件类型。
可选地,当所述N小于第一阈值时,所述方法包括:
获取第四图片,所述第四图片为所述目标视频文件中不同于所述第一图片的一帧图片;
基于所述第四图片重新进行图片质量评估操作。
具体地,上述图片质量评估装置获取上述预处理图片的边缘点的个数N后,确定上述N是否大于或等于上述第一阈值。若确定上述N大于或等于上述第一阈值,则上述图片质量评估装置可将上述预处理图片对应的第一图用于确认上述目标视频文件的类型。若确定上述N小于上述第一阈值,则上述图片质量评估装置获取第四图片,并重新进行上述步骤S102-S104所述的过程。上述第四图片为上述目标视频文件中不同于上述第一图片的一帧图片,且该第四图片为上述目标视频文件中的关键帧。
其中,上述第一阈值的取值根据上述预处理图片的尺寸大小来确定。
可选地,上述第一阈值可为1280或者其他值。
可以看出,在本发明实施例的方案中,首先,从视频文件中获取第一图片;其次,对所述第一图片进行预处理,得到预处理图片;再次,对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数;最后所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。与现有技术相比,本发明实施例的方案提高了视频格式识别的效率。
参见图4,图4为本发明实施例提供的另一种图片质量评估方法的流程示
意图。如图4所示,该方法包括:
S401、图片质量评估装置获取第一图片。
S402、所述图片质量评估装置对所述第一图片进行分辨率处理,得到第二图片。
S403、所述图片质量评估装置所述第二图片进行灰度化处理,得到第三图片。
S404、所述图片质量评估装置所述第三图片进行直方图均衡化处理,得到预处理图片。
S405、所述图片质量评估装置对所述预处理图片的预设区域中的M个像素点进行边缘检测,获取M个检测值。
S406、所述图片质量评估装置对所述M个像素点逐个进行判断是否为边缘点,并统计边缘点的个数N。
S407、所述图片质量评估装置确定所述N是否大于或等于第一阈值。
其中,若确定所述N大于或等于所述第一阈值,所述图片质量评估装置执行步骤S408;反之,所述图片质量评估装置执行步骤S409。
S408、图片质量评估装置将所述第一图片用于确定所述目标视频文件的类型。
S409、所述图片质量评估装置获取第四图片,并重新执行上述步骤S402-S407。
需要说明的是,上述步骤S401-S409的描述可参见上述步骤S101-S104的相关描述,在此不再叙述。
参见图5,图5为本发明实施例提供的一种图片质量评估装置的结构示意图。如图5所示,该装置500包括:
第一获取模块501,用于获取第一图片。
可选地,所述第一图片为目标视频文件中的一帧图片。
可选地,所述第一图片为目标视频文件中的关键帧。
处理模块502,用于对所述第一图片进行预处理,得到预处理图片。
可选地,所述处理模块502包括:
第一处理单元5021,用于对所述目标图片进行分辨率处理,得到第二图片;
第二处理单元5022,用于对所述第二图片进行灰度化处理,得到第三图片;
第三处理单元5023,用于对所述第三图片进行直方图均衡化处理,得到预处理图片。
检测模块503,用于对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数。
可选地,,所述检测模块503还包括:
检测单元5031,用于对所述预处理图片的预设区域内的M个像素点进行边缘检测,得到M个检测值,所述M个检测值与所述M个像素点一一对应;
统计单元5032,用于将所述M个检测值中大于或等于第二阈值对应的像素点作为边缘点,以统计边缘点的个数N,所述M大于或等于N。
可选地,所述检测模303具体用于:通过检测算子对所述预处理图片的预设区域内的M个像素点进行边缘检测。
确定模块504,用于当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。
其中,当所述N小于第一阈值时,所述装置500包括:
第二获取模块505,用于获取第四图片,所述第四图片为所述目标视频文件中不同于所述第一图片的一帧图片并基于所述第四图片重新进行图片质量评估操作。
需要说明的是,上述各模块(第一获取模块501、处理模块502、检测模块503、确定模块504、第二获取模块505)用于执行上述行车轨迹的确定方法的相关步骤。
本实施例中的“模块”可是指定应用集成电路(application-specific integrated circuit,ASIC),执行一个或多个软件或固件程序的处理器和存储器,集成逻辑电路,和/或其他可以提供上述功能的器件。此外,上述第一获取模块501、
处理模块502、检测模块503、确定模块504、第二获取模块505可通过图8所述的装置800中的处理器来实现。
如图8所示,图片质量评估装置可以以图8中的结构来实现。该装置800包括至少一个处理器801,至少一个存储器802、至少一个通信接口803。此外,该装置还可以包括天线等通用部件,在此不再详述。
处理器801可以是通用中央处理器(CPU),微处理器,特定应用集成电路(application-specific integrated circuit,ASIC),或一个或多个用于控制以上方案程序执行的集成电路。
通信接口803,用于与其他设备或通信网络通信,如以太网,无线接入网(RAN),无线局域网(Wireless Local Area Networks,WLAN)等。
存储器802可以是只读存储器(read-only memory,ROM)或可存储静态信息和指令的其他类型的静态存储设备,随机存取存储器(random access memory,RAM)或者可存储信息和指令的其他类型的动态存储设备,也可以是电可擦可编程只读存储器(Electrically Erasable Programmable Read-Only Memory,EEPROM)、只读光盘(Compact Disc Read-Only Memory,CD-ROM)或其他光盘存储、光碟存储(包括压缩光碟、激光碟、光碟、数字通用光碟、蓝光光碟等)、磁盘存储介质或者其他磁存储设备、或者能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,但不限于此。存储器可以是独立存在,通过总线与处理器相连接。存储器也可以和处理器集成在一起。
其中,所述存储器802用于存储执行以上方案的应用程序代码,并由处理器801来控制执行。所述处理器801用于执行所述存储器802中存储的应用程序代码。
图8所示的图片质量评估装置,存储器802存储的代码可执行以上提供的图像质量评估方法,比如图片质量评估装置获取第一图片;对所述第一图片进行预处理,得到预处理图片;对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数;当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。
本发明实施例还提供一种计算机存储介质,其中,该计算机存储介质可存储有程序,该程序执行时包括上述方法实施例中记载的任何一种图片质量评估方法的部分或全部步骤。
需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明并不受所描述的动作顺序的限制,因为依据本发明,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本发明所必须的。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
在本申请所提供的几个实施例中,应该理解到,所揭露的装置,可通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储器中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储器
中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储器包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储器中,存储器可以包括:闪存盘、只读存储器(英文:Read-Only Memory,简称:ROM)、随机存取器(英文:Random Access Memory,简称:RAM)、磁盘或光盘等。
以上对本发明实施例进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的一般技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上上述,本说明书内容不应理解为对本发明的限制。
Claims (15)
- 一种图片质量评估方法,其特征在于,包括:获取第一图片;对所述第一图片进行预处理,得到预处理图片;对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数;当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。
- 根据权利要求1所述的方法,其特征在于,所述第一图片为所述目标视频文件中的一帧图片。
- 根据权利要求2所述的方法,其特征在于,所述第一图片为所述目标视频文件中的关键帧。
- 根据权利要求1-3任一项所述的方法,其特征在于,所述对所述第一图片进行预处理,得到预处理图片,包括:对所述第一图片进行分辨率处理,得到第二图片;对所述第二图片进行灰度化处理,得到第三图片;对所述第三图片进行直方图均衡化处理,得到预处理图片。
- 根据权利要求4所述的方法,其特征在于,所述对所述预处理图片进行边缘检测,以统计边缘点的个数N,包括:对所述预处理图片的预设区域内的M个像素点进行边缘检测,得到M个检测值,所述M个检测值与所述M个像素点一一对应;将所述M个检测值中大于或等于第二阈值对应的像素点作为边缘点,以统计边缘点的个数N,所述M大于或等于N。
- 根据权利要求4所述的方法,其特征在于,所述对所述预处理图片的预设区域内的M个像素点进行边缘检测,包括:通过检测算子对所述预处理图片的预设区域内的M个像素点进行边缘检测。
- 根据权利6所述的方法,其特征在于,当所述N小于第一阈值时,所 述方法包括:获取第四图片,所述第四图片为所述目标视频文件中不同于所述第一图片的一帧图片;基于所述第四图片重新进行图片质量评估操作。
- 一种图片质量评估装置,其特征在于,包括:第一获取模块,用于获取第一图片;处理模块,用于对所述第一图片进行预处理,得到预处理图片;检测模块,用于对所述预处理图片进行边缘检测,以统计边缘点的个数N,所述N为正整数;确定模块,用于当所述N大于或等于第一阈值时,将所述第一图片用于确定目标视频文件类型。
- 根据权利要求8所述的装置,其特征在于,所述第一图片为所述目标视频文件中的一帧图片。
- 根据权利要求9所述的装置,其特征在于,所述第一图片为所述目标视频文件中的关键帧。
- 根据权利要求8-10任一项所述的装置,其特征在于,所述处理模块包括:第一处理单元,用于对所述第一图片进行分辨率处理,得到第二图片;第二处理单元,用于对所述第二图片进行灰度化处理,得到第三图片;第三处理单元,用于对所述第三图片进行直方图均衡化处理,得到预处理图片。
- 根据权利要求11所述的装置,其特征在于,所述检测模块包括:检测单元,用于对所述预处理图片的预设区域内的M个像素点进行边缘检测,得到M个检测值,所述M个检测值与所述M个像素点一一对应;统计单元,用于将所述M个检测值中大于或等于第二阈值对应的像素点作为边缘点,以统计边缘点的个数N,所述M大于或等于N。
- 根据权利要求11所述的装置,其特征在于,所述检测模具体用于:通过检测算子对所述预处理图片的预设区域内的M个像素点进行边缘检测。
- 根据权利13所述的装置,其特征在于,当所述N小于第一阈值时,所述装置包括:第二获取模块,用于获取第四图片,所述第四图片为所述目标视频文件中不同于所述第一图片的一帧图片并基于所述第四图片重新进行图片质量评估操作。
- 一种图片质量评估装置,其特征在于,包括:存储有可执行程序代码的存储器;与所述存储器耦合的处理器;所述处理器调用所述存储器中存储的所述可执行程序代码,执行权利要求1-7所述的方法。
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201780004630.8A CN108475430B (zh) | 2017-04-10 | 2017-04-10 | 图片质量评估方法及装置 |
| PCT/CN2017/079975 WO2018187917A1 (zh) | 2017-04-10 | 2017-04-10 | 图片质量评估方法及装置 |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/CN2017/079975 WO2018187917A1 (zh) | 2017-04-10 | 2017-04-10 | 图片质量评估方法及装置 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2018187917A1 true WO2018187917A1 (zh) | 2018-10-18 |
Family
ID=63266546
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2017/079975 Ceased WO2018187917A1 (zh) | 2017-04-10 | 2017-04-10 | 图片质量评估方法及装置 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN108475430B (zh) |
| WO (1) | WO2018187917A1 (zh) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116630307A (zh) * | 2023-07-20 | 2023-08-22 | 济宁市华祥石墨制品有限公司 | 石墨拖杆打磨质量评估系统、装置及计算机可读存储介质 |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109272498B (zh) * | 2018-09-20 | 2021-11-23 | 易诚高科(大连)科技有限公司 | 一种枯叶图图卡视频的实时细节自动分析方法 |
| CN111626973A (zh) * | 2019-02-27 | 2020-09-04 | 通用电气精准医疗有限责任公司 | 医学成像设备的图像质量检测方法及系统、存储介质 |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102075786A (zh) * | 2011-01-19 | 2011-05-25 | 宁波大学 | 一种图像客观质量评价方法 |
| CN103065300A (zh) * | 2012-12-24 | 2013-04-24 | 安科智慧城市技术(中国)有限公司 | 一种视频标注方法和装置 |
| CN103262096A (zh) * | 2010-12-09 | 2013-08-21 | 诺基亚公司 | 基于有限上下文从视频序列中识别关键帧 |
| CN103269436A (zh) * | 2013-05-20 | 2013-08-28 | 山东大学 | 一种2d-3d视频转换中的关键帧选择方法 |
Family Cites Families (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US7612832B2 (en) * | 2005-03-29 | 2009-11-03 | Microsoft Corporation | Method and system for video clip compression |
| CN102202227B (zh) * | 2011-06-21 | 2013-02-20 | 珠海世纪鼎利通信科技股份有限公司 | 一种无参考视频质量客观评估方法 |
| CN104504717B (zh) * | 2014-12-31 | 2017-10-27 | 北京奇艺世纪科技有限公司 | 一种图像信息检测方法及装置 |
| CN104822069B (zh) * | 2015-04-30 | 2018-09-28 | 北京爱奇艺科技有限公司 | 一种图像信息检测方法及装置 |
-
2017
- 2017-04-10 WO PCT/CN2017/079975 patent/WO2018187917A1/zh not_active Ceased
- 2017-04-10 CN CN201780004630.8A patent/CN108475430B/zh not_active Expired - Fee Related
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103262096A (zh) * | 2010-12-09 | 2013-08-21 | 诺基亚公司 | 基于有限上下文从视频序列中识别关键帧 |
| CN102075786A (zh) * | 2011-01-19 | 2011-05-25 | 宁波大学 | 一种图像客观质量评价方法 |
| CN103065300A (zh) * | 2012-12-24 | 2013-04-24 | 安科智慧城市技术(中国)有限公司 | 一种视频标注方法和装置 |
| CN103269436A (zh) * | 2013-05-20 | 2013-08-28 | 山东大学 | 一种2d-3d视频转换中的关键帧选择方法 |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN116630307A (zh) * | 2023-07-20 | 2023-08-22 | 济宁市华祥石墨制品有限公司 | 石墨拖杆打磨质量评估系统、装置及计算机可读存储介质 |
| CN116630307B (zh) * | 2023-07-20 | 2023-09-19 | 济宁市华祥石墨制品有限公司 | 石墨拖杆打磨质量评估系统、装置及计算机可读存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN108475430B (zh) | 2022-01-28 |
| CN108475430A (zh) | 2018-08-31 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP3709266A1 (en) | Human-tracking methods, apparatuses, systems, and storage media | |
| US20190347767A1 (en) | Image processing method and device | |
| CN110889824A (zh) | 一种样本生成方法、装置、电子设备及计算机可读存储介质 | |
| US10169673B2 (en) | Region-of-interest detection apparatus, region-of-interest detection method, and recording medium | |
| CN103679129A (zh) | 一种图像中的目标物体识别方法及装置 | |
| US8971615B2 (en) | Image type classifier for improved remote presentation session compression | |
| CN109743566B (zh) | 一种用于识别vr视频格式的方法与设备 | |
| CN112070792B (zh) | 一种用于图像分割的边缘生长连接方法及装置 | |
| JP2013004089A (ja) | 画像処理方法、画像処理装置及びスキャナ | |
| WO2018187917A1 (zh) | 图片质量评估方法及装置 | |
| CN112163544A (zh) | 一种非机动车辆乱摆放的判断方法及系统 | |
| US10395373B1 (en) | Image feature detection | |
| US9836823B2 (en) | Method and device for enhancing edge of image and digital camera | |
| KR20220069846A (ko) | 차선 패턴을 검출하기 위한 방법 및 시스템 | |
| CN115668221A (zh) | 自动伪影检测 | |
| CN111967529A (zh) | 识别方法、装置、设备及系统 | |
| US11546577B2 (en) | Video jitter detection method and apparatus | |
| CN108629219A (zh) | 一种识别一维码的方法及装置 | |
| CN113496513A (zh) | 一种目标对象检测方法及装置 | |
| CN111507931A (zh) | 一种数据处理方法和装置 | |
| CN113191210A (zh) | 一种图像处理方法、装置及设备 | |
| WO2018187939A1 (zh) | 三维图像的识别方法和终端 | |
| CN113837987A (zh) | 舌部图像采集方法、装置及计算机设备 | |
| CN113117341B (zh) | 图片处理方法及装置、计算机可读存储介质、电子设备 | |
| US20240303885A1 (en) | Image processing apparatus, image processing method, and storage medium |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 17905365 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 32PN | Ep: public notification in the ep bulletin as address of the adressee cannot be established |
Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 21.02.2020) |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 17905365 Country of ref document: EP Kind code of ref document: A1 |