WO2019148442A1 - Template optimization method and device, electronic device and computer program product - Google Patents

Template optimization method and device, electronic device and computer program product Download PDF

Info

Publication number
WO2019148442A1
WO2019148442A1 PCT/CN2018/075055 CN2018075055W WO2019148442A1 WO 2019148442 A1 WO2019148442 A1 WO 2019148442A1 CN 2018075055 W CN2018075055 W CN 2018075055W WO 2019148442 A1 WO2019148442 A1 WO 2019148442A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
template
quality
area
image template
Prior art date
Application number
PCT/CN2018/075055
Other languages
French (fr)
Chinese (zh)
Inventor
王洛威
王恺
廉士国
Original Assignee
深圳前海达闼云端智能科技有限公司
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 深圳前海达闼云端智能科技有限公司 filed Critical 深圳前海达闼云端智能科技有限公司
Priority to CN201880000097.2A priority Critical patent/CN108369731B/en
Priority to PCT/CN2018/075055 priority patent/WO2019148442A1/en
Publication of WO2019148442A1 publication Critical patent/WO2019148442A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/77Retouching; Inpainting; Scratch removal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • G06T3/4053Scaling of whole images or parts thereof, e.g. expanding or contracting based on super-resolution, i.e. the output image resolution being higher than the sensor resolution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30168Image quality inspection

Definitions

  • the present application relates to the field of augmented reality technologies, and in particular, to a template optimization method, apparatus, electronic device, and computer program product.
  • AR Augmented Reality
  • the technology collects real-world images in real time and sets the position of the virtual object according to the position of the camera relative to the real object, so that the virtual object can be correctly superimposed on the real object.
  • the commonly used AR technology mostly uses flat objects (such as cards, book covers) as targets for superposition, and these targets for superposition are AR image templates.
  • the planar image of the template (such as the image of the cover of the book) is pre-stored, the video frame is recognized in real time at runtime, and the image matching algorithm is used to match the image template, and the pose information of the camera is calculated according to the matching result.
  • the image matching refers to identifying a point of the same name between two or more images by a certain matching algorithm. For example, in the two-dimensional image matching, by comparing the correlation coefficients of the same size window in the target area and the search area, the search area is taken. The center point of the window corresponding to the largest correlation coefficient is used as the point of the same name. The essence is to use the best search problem of matching criteria under the condition of primitive similarity.
  • Image matching can be mainly divided into gray-based matching and feature-based matching. When natural images are used as templates, matching is usually based on image features.
  • Feature matching refers to an algorithm that performs feature matching by extracting features (points, lines, faces, etc.) of two or more images, and then using the described parameters to perform matching.
  • Features processed by feature-based matching typically include features such as color features, texture features, shape features, spatial location features, and the like.
  • Feature matching Firstly, the image is preprocessed to extract its high-level features, and then the matching correspondence between the two images is established.
  • the commonly used feature primitives have some features, edge features and regional features.
  • Feature matching requires many mathematical operations such as matrix operations, gradient solutions, and Fourier transforms and Taylor expansion.
  • Feature extraction and matching methods are: statistical methods, geometric methods, model methods, signal processing methods, boundary feature methods, Fourier shape description methods, geometric parameter methods, shape invariant moment methods, and so on.
  • the feature matching algorithm is mainly composed of the following four elements: (1) Feature space, which is composed of image features participating in matching. Selecting features can improve matching performance, reduce search space, reduce noise, etc.
  • the similarity measure which measure is used to determine the similarity between the features to be matched, which is usually defined as a form of a cost function or a distance function
  • Image matching transformation type image geometric transformation is used to solve geometric position difference between two images, including rigid body transformation, affine transformation, projection transformation, polynomial transformation, etc.
  • search strategy search strategy is appropriate
  • the search method finds the optimal estimation of the transformation parameters such as translation and rotation in the search space, so that the similarity between the transformed images is the largest.
  • the camera pose is obtained by solving the template object and the homography matrix of the target in the video frame, so as to set the corresponding virtual object pose.
  • the embodiment of the present application proposes a template optimization method, device, device and computer program product, which are mainly used to optimize some AR image templates so as to correctly perform corresponding pose calculation and virtualization according to the matching of the image templates with the features of the real image.
  • Object overlay proposes a template optimization method, device, device and computer program product, which are mainly used to optimize some AR image templates so as to correctly perform corresponding pose calculation and virtualization according to the matching of the image templates with the features of the real image.
  • the embodiment of the present application provides a template optimization method, where the method includes: acquiring an AR image template; determining, according to image features included in the image template, that the image template quality does not meet the first standard. Adding enhanced image features to the image template.
  • the embodiment of the present application provides a template optimization apparatus, where the apparatus includes: an obtaining module, configured to acquire an AR image template; and a quality determining module, configured to: according to the image included in the image template The feature determines that the image template quality does not satisfy the first criterion; and the optimization module is configured to add an enhanced image feature to the image template.
  • an embodiment of the present application provides an electronic device, including: a memory, one or more processors; and one or more modules, the one or more modules being Stored in the memory and configured to be executed by the one or more processors, the one or more modules including instructions for performing the various steps of the above methods.
  • embodiments of the present application provide a computer program product for use in conjunction with an electronic device, the computer program product comprising a computer program embedded in a computer readable storage medium, the computer program comprising An instruction to cause the electronic device to perform the various steps in the above methods.
  • the AR image template can be optimized, the image template matching accuracy rate is improved, and the feature matching efficiency is improved.
  • FIG. 1 is a schematic flow chart of a template optimization method in Embodiment 1 of the present application.
  • FIG. 2 is a schematic structural diagram of a template optimization apparatus in Embodiment 2 of the present application.
  • FIG. 3 is a schematic structural diagram of an electronic device in Embodiment 3 of the present application.
  • the present application provides a template optimization method for optimizing an AR image template by adding an enhanced image feature when determining an image template quality according to an image feature of the AR image template.
  • the AR image template can be optimized, the image template matching accuracy rate is improved, and the feature matching efficiency is improved.
  • Embodiment 1 is a diagrammatic representation of Embodiment 1:
  • FIG. 1 is a schematic flowchart of a template optimization method according to Embodiment 1 of the present application. As shown in FIG. 1, the template optimization method includes:
  • Step 101 Acquire an AR image template.
  • Step 102 Determine, according to image features included in the image template, that the image template quality does not meet the first criterion
  • Step 103 adding an enhanced image feature to the image template.
  • an AR image template is obtained, that is, an AR image template that is input by the user and uploaded by the terminal or retrieved by the cloud server, and the AR image template is an overlay template when the virtual image is superimposed using the AR technology, and is usually Printed on a flat object.
  • step 102 it is determined whether the image template quality satisfies the first criterion according to the image features included in the image template, that is, whether the AR image template is of poor quality needs to be optimized.
  • the image feature is the basis of AR image template matching.
  • the image feature determination method may be different in different image matching algorithms, and the number and location of image features may also be different.
  • the image template quality can be evaluated according to the image features contained in the image template to determine whether it meets the preset first criterion, and the image features specifically refer to various states or information of the image features. , which may include the number of image features, the density of image features (the number of image features per unit area or a certain amount of pixels), the degree of aggregation of image features (whether the image features are scattered or gathered), or the significantness of image features.
  • the first criterion may be one or a combination of a number threshold of an image feature, a density threshold, an aggregation degree threshold, or a significance degree threshold. If the image feature reaches a preset standard, the image template is considered to have rich image features, good robustness, and is suitable for feature matching in the AR; if the preset standard cannot be achieved, the subsequent steps are added to the image. Features for template optimization.
  • determining that the image template quality does not meet the first criterion is based on a density and/or a degree of aggregation of image features included in the image template.
  • the density threshold of the image features may be defined, that is, the first criterion is N image features per thousand pixels (N may be an integer or a non-integer), according to the number of pixels in the current image template. And the number of image features n determines whether the quality of the image template satisfies the first criterion. When the number of pixels per thousand pixels in the image template is greater than N, it is considered that the image template quality satisfies the first criterion.
  • the threshold C of the degree of aggregation of image features may be defined, that is, the first criterion is C, and the calculation formula of the degree of aggregation of image features is as follows:
  • c represents the degree of aggregation of image features in the image template
  • ⁇ d is the sum of the Euclidean distances between the two image features in the image template
  • n is the number of image features in the image template
  • s is the area of the image template.
  • the threshold of the density and the degree of aggregation of the image features can be set simultaneously as the first criterion, and the image template is regarded as satisfying the first criterion when it reaches two thresholds at the same time.
  • a relatively simple algorithm can be employed to quickly determine whether an image template needs to be optimized when performing quality assessments on image templates according to the first standard.
  • Step 103 adding an enhanced image feature to the image template.
  • an image feature may be actively added to the image template, for example, adding image features of points, lines, and faces having special colors, textures, shapes, etc., and adding new enhanced image features into the image template.
  • the image template matching accuracy rate can be improved to a certain extent, and the feature matching efficiency is improved.
  • geometric patterns such as stars and rectangles can be selected as enhanced image features.
  • the image template is further divided into a plurality of image regions; the step 103 is specifically to add an enhanced image feature to the quality difference region of the image template, the quality The difference area is an image area whose image quality determined according to image characteristics included in each image area does not satisfy the second standard.
  • the image template may be divided into regions, for example, divided into two regions, four regions, and divided into nine regions by the "#" type. Or divided into multiple regions in other random or non-random ways.
  • the image quality of each image region is evaluated, and the image quality of each image region is determined to satisfy the second standard by using various states or information similar to the image features included in each region in step 102, and the image quality is not satisfied.
  • the image area of the second standard is listed as a quality difference area, and an enhanced image feature is added in the quality difference area.
  • the image features and the corresponding second standard are similar to those in step 102 and will not be described again. It can be appreciated that the addition of enhanced image features to areas of relatively poor image quality can significantly improve the overall image quality of the image template.
  • the high quality area is divided into a plurality of areas, and the high quality area is an area in which the image quality determined according to the image features included in each image area satisfies the second standard.
  • the image template is divided into a plurality of image regions and the image quality of each image region is evaluated, whether the image quality of each image region is satisfied is determined by using various states or information according to the image features included in each region in step 102.
  • the image area that satisfies the second standard is listed as a high-quality area, and the enhanced image feature is not added to the high-quality area in the divided image area, but is further divided, and the area divided by the high-quality area is included.
  • the quality difference area the enhanced image feature is added to the quality difference area. If the classified area is still a high quality area, further division is continued until the high quality areas cannot continue to be divided.
  • the judging whether the high-quality area can continue to be divided may be determined according to the resolution of the current area.
  • the resolution is less than a certain threshold
  • the high-quality area may not be divided, because the partitioned area is likely to be a quality difference area, but Adding enhanced image features does not significantly indicate the quality of the image template.
  • the image features and corresponding second standards in this embodiment are similar to those in step 102, and are not described again. It can be understood that adding enhanced image features to regions with relatively poor image quality can significantly improve the image quality of the image template as a whole. When some image regions are high-quality regions, they may still contain poor quality parts, so the quality is excellent. Further segmentation of the regions to identify these regions and the addition of enhanced image features can enhance the quality of the image template more specifically.
  • the second criterion is determined based on a mean threshold and a variance threshold of Harris response values corresponding to all image features included in the image region.
  • a relatively complicated evaluation standard may be adopted, for example, a Harris response value corresponding to each image feature in the image region may be calculated, and It is calculated whether the average value and the variance of the corresponding Harris response values of all image features in the image region satisfy a preset threshold criterion, that is, a second criterion, to determine that each image region is a quality region or a quality difference region.
  • Harris corner detection is a feature point detection method, which uses the gray point difference of adjacent pixels to determine whether it is a corner point, an edge, and a smooth area.
  • the basic principle is to calculate the gray value in the image by using a moving window.
  • the main flow includes converting images into grayscale images, calculating differential images, Gaussian smoothing, calculating local extrema, confirming corners, and so on.
  • the calculated response value of each image feature can represent the degree of saliency of each image feature to a certain extent.
  • the saliency threshold is used as the second criterion to determine whether each image feature is significant, and the degree of significance is significant.
  • the evaluation is similar, it is possible to determine whether it is a quality region or a quality difference region according to the degree of significance of the image feature in the image region, so as to further determine whether it is necessary to add an enhanced image feature or whether further division is required.
  • the cloud server can complete the correlation calculation, and feed the calculation result to the front end of each of the initiated AR image template optimization requests.
  • the AR image template can be optimized, the image template matching accuracy rate is improved, and the feature matching efficiency is improved. It is possible to determine which region of the image template to add the enhanced image feature to based on the division of the image region of the image template and the image quality evaluation of the sub-region, so as to significantly improve the image quality of the image template as a whole; the quality of the segmented image region is still good. The time division is further divided to more accurately determine the image area of poor quality to more specifically add enhanced image features.
  • the present application can quickly determine the image template to be optimized by using reasonable evaluation criteria, and can also determine whether the divided image regions need further optimization by using reasonable evaluation criteria.
  • Embodiment 2 is a diagrammatic representation of Embodiment 1:
  • the template optimization apparatus 200 includes:
  • the obtaining module 201 is configured to acquire an AR image template.
  • the quality determining module 202 is configured to determine, according to the image features included in the image template, that the image template quality does not satisfy the first criterion;
  • the optimization module 203 is configured to add an enhanced image feature to the image template.
  • the quality determining module 202 is specifically configured to determine that the image template quality does not satisfy the first criterion according to the density and/or the degree of aggregation of the image features included in the image template.
  • the apparatus 200 further includes a partitioning module 204 for dividing the image template into a plurality of image regions before adding the enhanced image features to the image template;
  • the optimization module 203 is specifically configured to add an enhanced image feature to the quality difference region of the image template, where the quality difference region is an image region whose image quality determined according to image features included in each image region does not satisfy the second standard.
  • the partitioning module 204 is further configured to divide the high quality area into multiples when there is a high quality area and the quality of the quality area is determined according to the resolution of the quality area.
  • the area, the high quality area is an area in which the image quality determined according to the image features included in each image area satisfies the second criterion.
  • the second criterion is determined based on a mean threshold and a variance threshold of Harris response values corresponding to all image features included in the image region.
  • Embodiment 3 is a diagrammatic representation of Embodiment 3
  • the electronic device 300 includes: a memory 301, one or more processors 302; and one or more modules, the one or more modules being stored in the memory and configured to Executed by the one or more processors, the one or more modules include instructions for performing the various steps of any of the above methods.
  • Embodiment 4 is a diagrammatic representation of Embodiment 4:
  • an embodiment of the present application further provides a computer program product for use in combination with an electronic device, the computer program product comprising a computer program embedded in a computer readable storage medium, the computer program comprising An instruction to cause the electronic device to perform each of the steps of any of the above methods.
  • embodiments of the present application can be provided as a method, system, or computer program product.
  • the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment in combination of software and hardware.
  • the application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
  • the computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device.
  • the apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
  • These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device.
  • the instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Analysis (AREA)
  • Image Processing (AREA)

Abstract

A template optimization method and device, an electronic device and a computer program product, the method comprising: acquiring an augmented reality (AR) image template; according to image features comprised in the image template, determining that the quality of the image template does not meet a first standard; and adding an enhanced image feature to said image template. In the present application, it is possible to optimize an AR image template, thus increasing the correct matching rate for image templates and increasing the efficiency of feature matching.

Description

模板优化方法、装置、电子设备和计算机程序产品Template optimization method, device, electronic device and computer program product 技术领域Technical field
本申请涉及增强现实技术领域,特别涉及模板优化方法、装置、电子设备和计算机程序产品。The present application relates to the field of augmented reality technologies, and in particular, to a template optimization method, apparatus, electronic device, and computer program product.
背景技术Background technique
AR(Augmented Reality,增强现实)技术是通过计算机系统提供的信息增加用户对现实世界感知的技术,并将计算机生成的虚拟物体、场景或系统提示信息叠加到真实场景中,从而实现对现实的“增强”。该技术通过实时采集真实世界的图像,并根据摄像机相对于真实物体的位置设置虚拟物体的位置,使得虚拟物体能正确叠加在真实物体之上。AR (Augmented Reality) technology is a technology that increases the user's perception of the real world through the information provided by the computer system, and superimposes the computer-generated virtual object, scene or system prompt information into the real scene, thereby realizing the reality. Enhanced." The technology collects real-world images in real time and sets the position of the virtual object according to the position of the camera relative to the real object, so that the virtual object can be correctly superimposed on the real object.
常用的AR技术多以平面物体(如卡片,书本封面)作为叠加的目标,这些用于叠加的目标即AR图像模板。首先预存模板的平面图像(如卡片,书本封面的图像),在运行时实时识别视频帧,使用图像匹配算法将其与图像模板进行匹配,根据匹配结果计算出相机的位姿信息。所述图像匹配是指通过一定的匹配算法在两幅或多幅图像之间识别同名点,如二维图像匹配中通过比较目标区和搜索区中相同大小的窗口的相关系数,取搜索区中相关系数最大所对应的窗口中心点作为同名点。其实质是在基元相似性的条件下,运用匹配准则的最佳搜索问题。图像匹配主要可分为以灰度为基础的匹配和以特征为基础的匹配,在以自然图像为模板时通常以图像特征为基础进行匹配。The commonly used AR technology mostly uses flat objects (such as cards, book covers) as targets for superposition, and these targets for superposition are AR image templates. First, the planar image of the template (such as the image of the cover of the book) is pre-stored, the video frame is recognized in real time at runtime, and the image matching algorithm is used to match the image template, and the pose information of the camera is calculated according to the matching result. The image matching refers to identifying a point of the same name between two or more images by a certain matching algorithm. For example, in the two-dimensional image matching, by comparing the correlation coefficients of the same size window in the target area and the search area, the search area is taken. The center point of the window corresponding to the largest correlation coefficient is used as the point of the same name. The essence is to use the best search problem of matching criteria under the condition of primitive similarity. Image matching can be mainly divided into gray-based matching and feature-based matching. When natural images are used as templates, matching is usually based on image features.
特征匹配是指通过分别提取两个或多个图像的特征(点、线、面等特征),对特征进行参数描述后运用所描述的参数来进行匹配的一种算法。基于特征的匹配所处理的图像一般包含的特征有颜色特征、纹理特征、形状 特征、空间位置特征等。特征匹配首先对图像进行预处理来提取其高层次的特征,然后建立两幅图像之间特征的匹配对应关系,通常使用的特征基元有点特征、边缘特征和区域特征。特征匹配需要用到许多诸如矩阵的运算、梯度的求解、还有傅立叶变换和泰勒展开等数学运算。常用的特征提取与匹配方法有:统计方法、几何法、模型法、信号处理法、边界特征法、傅氏形状描述法、几何参数法、形状不变矩法等。此外特征匹配算法主要由如下四个要素组合而成:(1)特征空间,特征空间是由参与匹配的图像特征构成的,选择好的特征可以提高匹配性能、降低搜索空间、减小噪声等不确定性因素对匹配算法的影响;(2)相似性度量,相似性度量指用什么度量来确定待匹配特征之间的相似性,它通常定义为某种代价函数或者是距离函数的形式;(3)图像匹配变换类型,图像几何变换用于解决两幅图像之间的几何位置差别,包括刚体变换、仿射变换、投影变换、多项式变换等;(4)搜索策略,搜索策略是用合适的搜索方法在搜索空间中找出平移、旋转等变换参数的最优估计,使得图像之间经过变换后的相似性最大。特征匹配成功以后,通过求解模板目标与视频帧中目标的单应矩阵,进而得到相机姿态,以便设置相应的虚拟物体姿态。Feature matching refers to an algorithm that performs feature matching by extracting features (points, lines, faces, etc.) of two or more images, and then using the described parameters to perform matching. Features processed by feature-based matching typically include features such as color features, texture features, shape features, spatial location features, and the like. Feature matching Firstly, the image is preprocessed to extract its high-level features, and then the matching correspondence between the two images is established. The commonly used feature primitives have some features, edge features and regional features. Feature matching requires many mathematical operations such as matrix operations, gradient solutions, and Fourier transforms and Taylor expansion. Commonly used feature extraction and matching methods are: statistical methods, geometric methods, model methods, signal processing methods, boundary feature methods, Fourier shape description methods, geometric parameter methods, shape invariant moment methods, and so on. In addition, the feature matching algorithm is mainly composed of the following four elements: (1) Feature space, which is composed of image features participating in matching. Selecting features can improve matching performance, reduce search space, reduce noise, etc. The influence of deterministic factors on the matching algorithm; (2) the similarity measure, which measure is used to determine the similarity between the features to be matched, which is usually defined as a form of a cost function or a distance function; 3) Image matching transformation type, image geometric transformation is used to solve geometric position difference between two images, including rigid body transformation, affine transformation, projection transformation, polynomial transformation, etc.; (4) search strategy, search strategy is appropriate The search method finds the optimal estimation of the transformation parameters such as translation and rotation in the search space, so that the similarity between the transformed images is the largest. After the feature matching is successful, the camera pose is obtained by solving the template object and the homography matrix of the target in the video frame, so as to set the corresponding virtual object pose.
现有技术的不足在于:The shortcomings of the prior art are:
当AR图像模板质量较差时,将不能正确的根据这些图像模板与现实图像的特征匹配完成相应的位姿计算和虚拟物体叠加。When the quality of the AR image template is poor, the corresponding pose calculation and virtual object superposition cannot be correctly performed according to the matching of the image templates with the features of the real image.
发明内容Summary of the invention
本申请实施例提出了模板优化方法、装置、设备和计算机程序产品,主要用以对一些AR图像模板进行优化以便能够正确的根据这些图像模板与现实图像的特征匹配完成相应的位姿计算和虚拟物体叠加。The embodiment of the present application proposes a template optimization method, device, device and computer program product, which are mainly used to optimize some AR image templates so as to correctly perform corresponding pose calculation and virtualization according to the matching of the image templates with the features of the real image. Object overlay.
在一个方面,本申请实施例提供了一种模板优化方法,其特征在于, 所述方法包括:获取AR图像模板;根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准;为所述图像模板添加增强图像特征。In one aspect, the embodiment of the present application provides a template optimization method, where the method includes: acquiring an AR image template; determining, according to image features included in the image template, that the image template quality does not meet the first standard. Adding enhanced image features to the image template.
在另一个方面,本申请实施例提供了一种模板优化装置,其特征在于,所述装置包括:获取模块,用于获取AR图像模板;质量确定模块,用于根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准;优化模块,用于为所述图像模板添加增强图像特征。In another aspect, the embodiment of the present application provides a template optimization apparatus, where the apparatus includes: an obtaining module, configured to acquire an AR image template; and a quality determining module, configured to: according to the image included in the image template The feature determines that the image template quality does not satisfy the first criterion; and the optimization module is configured to add an enhanced image feature to the image template.
在另一个方面,本申请实施例提供了一种电子设备,其特征在于,所述电子设备包括:存储器,一个或多个处理器;以及一个或多个模块,所述一个或多个模块被存储在所述存储器中,并被配置成由所述一个或多个处理器执行,所述一个或多个模块包括用于执行上述方法中各个步骤的指令。In another aspect, an embodiment of the present application provides an electronic device, including: a memory, one or more processors; and one or more modules, the one or more modules being Stored in the memory and configured to be executed by the one or more processors, the one or more modules including instructions for performing the various steps of the above methods.
在另一个方面,本申请实施例提供了一种与电子设备结合使用的计算机程序产品,所述计算机程序产品包括内嵌于计算机可读的存储介质中的计算机程序,所述计算机程序包括用于使所述电子设备执行上述方法中的各个步骤的指令。In another aspect, embodiments of the present application provide a computer program product for use in conjunction with an electronic device, the computer program product comprising a computer program embedded in a computer readable storage medium, the computer program comprising An instruction to cause the electronic device to perform the various steps in the above methods.
本申请实施例的有益效果如下:The beneficial effects of the embodiments of the present application are as follows:
本申请中,能够对AR图像模板进行优化,提升图像模板匹配正确率,提升特征匹配效率。In the present application, the AR image template can be optimized, the image template matching accuracy rate is improved, and the feature matching efficiency is improved.
附图说明DRAWINGS
下面将参照附图描述本申请的具体实施例,其中:Specific embodiments of the present application will be described below with reference to the accompanying drawings, in which:
图1示出了本申请实施例一中模板优化方法的流程示意图;1 is a schematic flow chart of a template optimization method in Embodiment 1 of the present application;
图2示出了本申请实施例二中模板优化装置的结构示意图;2 is a schematic structural diagram of a template optimization apparatus in Embodiment 2 of the present application;
图3示出了本申请实施例三中电子设备的结构示意图。FIG. 3 is a schematic structural diagram of an electronic device in Embodiment 3 of the present application.
具体实施方式Detailed ways
为了使本申请的技术方案及优点更加清楚明白,以下结合附图对本申请的示例性实施例进行进一步详细的说明,显然,所描述的实施例仅是本申请的一部分实施例,而不是所有实施例的穷举。并且在不冲突的情况下,本说明中的实施例及实施例中的特征可以互相结合。The exemplary embodiments of the present application are further described in detail below with reference to the accompanying drawings, in which the embodiments described are only a part of the embodiments of the present application, but not all embodiments. An exhaustive example. And in the case of no conflict, the features in the embodiments and the embodiments in the description can be combined with each other.
发明人在发明过程中注意到:当某些AR图像模板包含的图像特征不鲁棒或者数量太少时,将不能正确的根据这些图像模板与现实图像的特征匹配完成相应的位姿计算和虚拟物体叠加。The inventor noticed during the invention that when some AR image templates contain image features that are not robust or too small, they will not correctly match the image poses with the features of the real images to complete the corresponding pose calculations and virtual objects. Superimposed.
针对上述不足,本申请提供了一种模板优化方法,当根据AR图像模板的图像特征情况确定其图像模板质量不佳时,通过添加增强图像特征的方式对所述AR图像模板进行优化。本申请中,能够对AR图像模板进行优化,提升图像模板匹配正确率,提升特征匹配效率。In view of the above-mentioned deficiencies, the present application provides a template optimization method for optimizing an AR image template by adding an enhanced image feature when determining an image template quality according to an image feature of the AR image template. In the present application, the AR image template can be optimized, the image template matching accuracy rate is improved, and the feature matching efficiency is improved.
以下通过具体示例,进一步阐明本发明实施例技术方案的实质。The essence of the technical solution of the embodiment of the present invention is further clarified by specific examples below.
实施例一:Embodiment 1:
图1示出了本申请实施例一中模板优化方法流程示意图,如图1所示,所述模板优化方法包括:FIG. 1 is a schematic flowchart of a template optimization method according to Embodiment 1 of the present application. As shown in FIG. 1, the template optimization method includes:
步骤101,获取AR图像模板;Step 101: Acquire an AR image template.
步骤102,根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准;Step 102: Determine, according to image features included in the image template, that the image template quality does not meet the first criterion;
步骤103,为所述图像模板添加增强图像特征。 Step 103, adding an enhanced image feature to the image template.
在步骤101中,获取AR图像模板,即接收用户输入的,接收终端上传的或者云端服务器调取获得的AR图像模板,所述AR图像模板即使用AR技术叠加虚拟图像时的叠加模板,通常被印制在平面物体上。In step 101, an AR image template is obtained, that is, an AR image template that is input by the user and uploaded by the terminal or retrieved by the cloud server, and the AR image template is an overlay template when the virtual image is superimposed using the AR technology, and is usually Printed on a flat object.
在步骤102中,根据所述图像模板包含的图像特征判断所述图像模板质量是否满足第一标准,即确定所述AR图像模板是否质量较差需要被优 化。In step 102, it is determined whether the image template quality satisfies the first criterion according to the image features included in the image template, that is, whether the AR image template is of poor quality needs to be optimized.
图像特征是AR图像模板匹配的基础,在不同的图像匹配算法中对图像特征确定方式可能不同,图像特征的数量和位置也可能不同。在应用各类图像匹配算法时,都可以根据图像模板包含的图像特征对图像模板质量进行评价,判断其是否满足预设的第一标准,所述图像特征具体指图像特征的各种状态或者信息,其可以包括图像特征的数量、图像特征的密度(单位面积或者一定量的像素中图像特征的数量)、图像特征的聚集程度(各图像特征是否分散或者聚拢的排布)或者图像特征的显著程度(在某种图像识别或者匹配算法下,各图像特征是否易于识别)等中的一种或者几种的组合,以各种图像特征对模板质量进行判断时相应的有不同的标准,即所述第一标准可以为图像特征的数量阈值、密度阈值、聚集程度阈值或者显著程度阈值等中的一种或者几种的组合。若图像特征达到了预先设定的标准,则认为该图像模板的图像特征丰富,鲁棒性好,比较合适进行AR中的特征匹配;若不能达到预先设定的标准,则进行后续步骤添加图像特征以进行模板优化。The image feature is the basis of AR image template matching. The image feature determination method may be different in different image matching algorithms, and the number and location of image features may also be different. When applying various image matching algorithms, the image template quality can be evaluated according to the image features contained in the image template to determine whether it meets the preset first criterion, and the image features specifically refer to various states or information of the image features. , which may include the number of image features, the density of image features (the number of image features per unit area or a certain amount of pixels), the degree of aggregation of image features (whether the image features are scattered or gathered), or the significantness of image features. A combination of one or more of the degree (under certain image recognition or matching algorithms, whether each image feature is easy to recognize), etc., when the image quality is judged by various image features, there are different standards, that is, The first criterion may be one or a combination of a number threshold of an image feature, a density threshold, an aggregation degree threshold, or a significance degree threshold. If the image feature reaches a preset standard, the image template is considered to have rich image features, good robustness, and is suitable for feature matching in the AR; if the preset standard cannot be achieved, the subsequent steps are added to the image. Features for template optimization.
在一些实施方式中,根据所述图像模板包含的图像特征的密度和/或聚集程度确定所述图像模板质量不满足第一标准。In some embodiments, determining that the image template quality does not meet the first criterion is based on a density and/or a degree of aggregation of image features included in the image template.
以图像特征的密度为例,可以限定图像特征的密度阈值,即所述第一标准为每千个像素N个图像特征(N可以为整数或者非整数),根据当前的图像模板中的像素数量和图像特征数量n确定其所述图像模板的质量是否满足第一标准,当图像模板中每千个像素的数量大于N时,视为图像模板质量满足第一标准。Taking the density of image features as an example, the density threshold of the image features may be defined, that is, the first criterion is N image features per thousand pixels (N may be an integer or a non-integer), according to the number of pixels in the current image template. And the number of image features n determines whether the quality of the image template satisfies the first criterion. When the number of pixels per thousand pixels in the image template is greater than N, it is considered that the image template quality satisfies the first criterion.
以图像特征的聚集程度为例,可以限定图像特征的聚集程度的阈值C,即所述第一标准为C,图像特征的聚集程度计算公式如下:Taking the degree of aggregation of image features as an example, the threshold C of the degree of aggregation of image features may be defined, that is, the first criterion is C, and the calculation formula of the degree of aggregation of image features is as follows:
Figure PCTCN2018075055-appb-000001
Figure PCTCN2018075055-appb-000001
上式中c表示图像模板中图像特征的聚集程度,∑d为图像模板中所有图像特征两两之间的欧氏距离的总和,n为图像模板中的图像特征数量,s为图像模板的面积。当c≥C时,视为图像模板的质量满足第一标准。需要说明的是,图像特征的聚集程度的计算不限于上述算法,常用的能够表征散点聚集程度的算法均可使用,相应的需要设定不同的第一标准。In the above formula, c represents the degree of aggregation of image features in the image template, ∑d is the sum of the Euclidean distances between the two image features in the image template, n is the number of image features in the image template, and s is the area of the image template. . When c ≥ C, the quality of the image template is considered to satisfy the first criterion. It should be noted that the calculation of the degree of aggregation of image features is not limited to the above algorithm, and commonly used algorithms capable of characterizing the degree of scatter aggregation can be used, and correspondingly need to set different first standards.
此外还可以同时设定图像特征的密度和聚集程度的阈值作为第一标准,图像模板同时达到两个阈值时视为满足第一标准。在根据第一标准对图像模板进行质量评估时可以采用相对简单的算法以快速确定某图像模板是否需要被优化。In addition, the threshold of the density and the degree of aggregation of the image features can be set simultaneously as the first criterion, and the image template is regarded as satisfying the first criterion when it reaches two thresholds at the same time. A relatively simple algorithm can be employed to quickly determine whether an image template needs to be optimized when performing quality assessments on image templates according to the first standard.
步骤103,为所述图像模板添加增强图像特征。 Step 103, adding an enhanced image feature to the image template.
当图像模板的质量不满足预设标准时可主动为所述图像模板添加图像特征,例如添加具有特殊颜色、纹理、形状等的点、线、面的图像特征等,将新的增强图像特征添加入图像模板后,能够在一定程度上提升图像模板匹配正确率,提升特征匹配效率。当然可以选择如星形、矩形等几何图案作为增强图像特征进行添加,这些图案特征更加明显,在传感器噪声、成像过程中视角改变引起的图像变化、目标移动和变形、光照或者环境的改变带来的图像变化影响下,这些特征的相似性并不高,不容易受各种影响,能够在特征匹配过程中很容易的被分辨出来,进一步提升图像模板的匹配正确率,提升特征匹配效率。When the quality of the image template does not meet the preset criteria, an image feature may be actively added to the image template, for example, adding image features of points, lines, and faces having special colors, textures, shapes, etc., and adding new enhanced image features into the image template. After the image template, the image template matching accuracy rate can be improved to a certain extent, and the feature matching efficiency is improved. Of course, geometric patterns such as stars and rectangles can be selected as enhanced image features. These pattern features are more obvious, resulting in sensor noise, image changes caused by changes in viewing angles, target movement and deformation, illumination or environmental changes. Under the influence of image changes, the similarity of these features is not high, and it is not easy to be affected by various effects. It can be easily distinguished in the feature matching process, further improving the matching accuracy of image templates and improving feature matching efficiency.
在一些实施方式中,在所述步骤103之前还包括将所述图像模板划分为多个图像区域;所述步骤103具体为,为所述图像模板的质差区域添加增强图像特征,所述质差区域为根据各图像区域包含的图像特征确定的图像质量不满足第二标准的图像区域。In some embodiments, before the step 103, the image template is further divided into a plurality of image regions; the step 103 is specifically to add an enhanced image feature to the quality difference region of the image template, the quality The difference area is an image area whose image quality determined according to image characteristics included in each image area does not satisfy the second standard.
即在步骤102确定了图像模板质量不满足预设的第一标准后,可对该图像模板进行区域划分,例如平均分为2个区域、4个区域、以“#”型划 分为9个区域,或者以其他随机或者非随机的方式划分为多个区域。That is, after it is determined in step 102 that the image template quality does not satisfy the preset first criterion, the image template may be divided into regions, for example, divided into two regions, four regions, and divided into nine regions by the "#" type. Or divided into multiple regions in other random or non-random ways.
在划分了区域后评估各图像区域的图像质量,可以采用类似步骤102中的根据各区域中包含的图像特征的各种状态或者信息确定各图像区域的图像质量是否满足第二标准,将不满足第二标准的图像区域列为质差区域,并在质差区域中添加增强图像特征。其中图像特征和相应的第二标准与步骤102中类似,不再赘述。可以理解将增强图像特征添加至图像质量相对较差的区域更能够明显提升图像模板整体的图像质量。After the regions are divided, the image quality of each image region is evaluated, and the image quality of each image region is determined to satisfy the second standard by using various states or information similar to the image features included in each region in step 102, and the image quality is not satisfied. The image area of the second standard is listed as a quality difference area, and an enhanced image feature is added in the quality difference area. The image features and the corresponding second standard are similar to those in step 102 and will not be described again. It can be appreciated that the addition of enhanced image features to areas of relatively poor image quality can significantly improve the overall image quality of the image template.
在一些实施方式中,在上述为质差区域添加增强图像特征的实施方式的基础上,在存在质优区域并且根据所述质优区域的分辨率确定所述质优区域能够划分时,将所述质优区域划分为多个区域,所述质优区域为根据各图像区域包含的图像特征确定的图像质量满足第二标准的区域。In some embodiments, on the basis of the above-described embodiment of adding an enhanced image feature to the qualitative difference region, when there is a high quality region and determining that the high quality region can be divided according to the resolution of the high quality region, The high quality area is divided into a plurality of areas, and the high quality area is an area in which the image quality determined according to the image features included in each image area satisfies the second standard.
将所述图像模板划分为多个图像区域后评估各图像区域的图像质量,可以采用类似步骤102中的根据各区域中包含的图像特征的各种状态或者信息确定各图像区域的图像质量是否满足第二标准,将满足第二标准的图像区域列为质优区域,对划分出的图像区域中的质优区域暂不添加增强图像特征,而是进一步划分,质优区域划分出来的区域如果包含质差区域,则为质差区域添加增强图像特征,若划分出来的仍为质优区域,则继续进一步划分,直到各质优区域不能继续划分为止。其中判断质优区域是否能够继续划分可以根据当前区域的分辨率确定,当分辨率小于一定阈值后可以不再对该质优区域进行划分,因为划分出来的很可能将为质差区域,但在其中添加增强图像特征并不能明显的提示图像模板的质量。本实施方式中图像特征和相应的第二标准与步骤102中类似,不再赘述。可以理解将增强图像特征添加至图像质量相对较差的区域更能够明显提升图像模板整体的图像质量,当某些图像区域为质优区域时,其可能仍包含质量不佳的部分,因此对质优区域进一步划分找出这些区域并添加增强图像特征能够 更有针对性的提升图像模板的质量。After the image template is divided into a plurality of image regions and the image quality of each image region is evaluated, whether the image quality of each image region is satisfied is determined by using various states or information according to the image features included in each region in step 102. In the second standard, the image area that satisfies the second standard is listed as a high-quality area, and the enhanced image feature is not added to the high-quality area in the divided image area, but is further divided, and the area divided by the high-quality area is included. In the quality difference area, the enhanced image feature is added to the quality difference area. If the classified area is still a high quality area, further division is continued until the high quality areas cannot continue to be divided. The judging whether the high-quality area can continue to be divided may be determined according to the resolution of the current area. When the resolution is less than a certain threshold, the high-quality area may not be divided, because the partitioned area is likely to be a quality difference area, but Adding enhanced image features does not significantly indicate the quality of the image template. The image features and corresponding second standards in this embodiment are similar to those in step 102, and are not described again. It can be understood that adding enhanced image features to regions with relatively poor image quality can significantly improve the image quality of the image template as a whole. When some image regions are high-quality regions, they may still contain poor quality parts, so the quality is excellent. Further segmentation of the regions to identify these regions and the addition of enhanced image features can enhance the quality of the image template more specifically.
在一些实施方式中,所述第二标准根据图像区域包含的所有图像特征对应的Harris响应值的均值阈值和方差阈值确定。In some embodiments, the second criterion is determined based on a mean threshold and a variance threshold of Harris response values corresponding to all image features included in the image region.
在对某个划分得到的图像区域进一步进行质量评估判断其是否质差区域或者质优区域时,可以采用相对复杂的评估标准,例如可计算该图像区域中各图像特征对应的Harris响应值,并计算该图像区域中所有图像特征的对应的Harris响应值的平均值和方差是否满足预设的阈值标准,即第二标准,以确定各图像区域为质优区域或者质差区域。When further performing quality evaluation on a divided image region to determine whether it is a poor quality region or a high quality region, a relatively complicated evaluation standard may be adopted, for example, a Harris response value corresponding to each image feature in the image region may be calculated, and It is calculated whether the average value and the variance of the corresponding Harris response values of all image features in the image region satisfy a preset threshold criterion, that is, a second criterion, to determine that each image region is a quality region or a quality difference region.
其中Harris角点检测是一种特征点检测方法,其应用邻近像素点灰度差值判断是否为角点、边缘、平滑区域,基本其原理是利用移动的窗口在图像中计算灰度变化值,主要流程包括将图像转化为灰度图像、计算差分图像、高斯平滑、计算局部极值、确认角点等。计算得到的各图像特征对应的响应值可以在一定程度上表征各图像特征的显著程度,在该种实施方式中以显著程度阈值作为第二标准,以对各图像特征是否均显著,其显著程度是否相差不多进行评估,能够根据图像区域中图像特征的显著程度合理的确定其为质优区域或者质差区域,以便进一步确定其是否需要添加增强图像特征或者是否需要进一步划分。Harris corner detection is a feature point detection method, which uses the gray point difference of adjacent pixels to determine whether it is a corner point, an edge, and a smooth area. The basic principle is to calculate the gray value in the image by using a moving window. The main flow includes converting images into grayscale images, calculating differential images, Gaussian smoothing, calculating local extrema, confirming corners, and so on. The calculated response value of each image feature can represent the degree of saliency of each image feature to a certain extent. In this embodiment, the saliency threshold is used as the second criterion to determine whether each image feature is significant, and the degree of significance is significant. Whether or not the evaluation is similar, it is possible to determine whether it is a quality region or a quality difference region according to the degree of significance of the image feature in the image region, so as to further determine whether it is necessary to add an enhanced image feature or whether further division is required.
本实施例因涉及图像处理运算,当算法复杂运算量大时,可由云端服务器完成相关计算,并将计算结果反馈给各个发起AR图像模板优化请求的前端。In this embodiment, when the image processing operation is involved, when the algorithm has a large amount of computation, the cloud server can complete the correlation calculation, and feed the calculation result to the front end of each of the initiated AR image template optimization requests.
本申请中,能够对AR图像模板进行优化,提升图像模板匹配正确率,提升特征匹配效率。能够基于对图像模板的图像区域的划分和分区域的图像质量评估确定将增强图像特征添加至图像模板的哪个区域,以便显著的提升图像模板整体的图像质量;在划分的图像区域质量仍较好时进一步划分,以便更精确的确定质量差的图像区域以便更有针对性的添加增强图像 特征。此外本申请还能够采用合理的评估标准快速的确定需要优化的图像模板,也能够采用合理的评估标准更准确的确定划分的图像区域是否需要进一步优化。In the present application, the AR image template can be optimized, the image template matching accuracy rate is improved, and the feature matching efficiency is improved. It is possible to determine which region of the image template to add the enhanced image feature to based on the division of the image region of the image template and the image quality evaluation of the sub-region, so as to significantly improve the image quality of the image template as a whole; the quality of the segmented image region is still good. The time division is further divided to more accurately determine the image area of poor quality to more specifically add enhanced image features. In addition, the present application can quickly determine the image template to be optimized by using reasonable evaluation criteria, and can also determine whether the divided image regions need further optimization by using reasonable evaluation criteria.
实施例二:Embodiment 2:
基于同一发明构思,本申请实施例中还提供了一种模板优化装置,由于这些装置解决问题的原理与模板优化方法相似,因此这些装置的实施可以参见方法的实施,重复之处不再赘述。如图2所示,所述模板优化装置200包括:Based on the same inventive concept, a template optimization device is also provided in the embodiment of the present application. Since the principle of solving the problem is similar to the template optimization method, the implementation of the device may refer to the implementation of the method, and the repeated description is not repeated. As shown in FIG. 2, the template optimization apparatus 200 includes:
获取模块201,用于获取AR图像模板;The obtaining module 201 is configured to acquire an AR image template.
质量确定模块202,用于根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准;The quality determining module 202 is configured to determine, according to the image features included in the image template, that the image template quality does not satisfy the first criterion;
优化模块203,用于为所述图像模板添加增强图像特征。The optimization module 203 is configured to add an enhanced image feature to the image template.
在一些实施方式中,所述质量确定模块202具体用于,根据所述图像模板包含的图像特征的密度和/或聚集程度确定所述图像模板质量不满足第一标准。In some embodiments, the quality determining module 202 is specifically configured to determine that the image template quality does not satisfy the first criterion according to the density and/or the degree of aggregation of the image features included in the image template.
在一些实施方式中,所述装置200还包括分区模块204,用于在所述为所述图像模板添加增强图像特征之前,将所述图像模板划分为多个图像区域;In some embodiments, the apparatus 200 further includes a partitioning module 204 for dividing the image template into a plurality of image regions before adding the enhanced image features to the image template;
所述优化模块203具体用于,为所述图像模板的质差区域添加增强图像特征,所述质差区域为根据各图像区域包含的图像特征确定的图像质量不满足第二标准的图像区域。The optimization module 203 is specifically configured to add an enhanced image feature to the quality difference region of the image template, where the quality difference region is an image region whose image quality determined according to image features included in each image region does not satisfy the second standard.
在一些实施方式中,所述分区模块204还用于,在存在质优区域并且根据所述质优区域的分辨率确定所述质优区域能够划分时,将所述质优区域划分为多个区域,所述质优区域为根据各图像区域包含的图像特征确定的图像质量满足第二标准的区域。In some embodiments, the partitioning module 204 is further configured to divide the high quality area into multiples when there is a high quality area and the quality of the quality area is determined according to the resolution of the quality area. The area, the high quality area is an area in which the image quality determined according to the image features included in each image area satisfies the second criterion.
在一些实施方式中,所述第二标准根据图像区域包含的所有图像特征对应的Harris响应值的均值阈值和方差阈值确定。In some embodiments, the second criterion is determined based on a mean threshold and a variance threshold of Harris response values corresponding to all image features included in the image region.
实施例三:Embodiment 3:
基于同一发明构思,本申请实施例中还提供了一种电子设备,由于其原理与模板优化方法相似,因此其实施可以参见方法的实施,重复之处不再赘述。如图3所示,所述电子设备300包括:存储器301,一个或多个处理器302;以及一个或多个模块,所述一个或多个模块被存储在所述存储器中,并被配置成由所述一个或多个处理器执行,所述一个或多个模块包括用于执行任一上述方法中各个步骤的指令。Based on the same inventive concept, an electronic device is also provided in the embodiment of the present application. Since the principle is similar to the template optimization method, the implementation of the method may refer to the implementation of the method, and the repeated description is not repeated. As shown in FIG. 3, the electronic device 300 includes: a memory 301, one or more processors 302; and one or more modules, the one or more modules being stored in the memory and configured to Executed by the one or more processors, the one or more modules include instructions for performing the various steps of any of the above methods.
实施例四:Embodiment 4:
基于同一发明构思,本申请实施例还提供了一种与电子设备结合使用的计算机程序产品,所述计算机程序产品包括内嵌于计算机可读的存储介质中的计算机程序,所述计算机程序包括用于使所述电子设备执行任一上述方法中的各个步骤的指令。Based on the same inventive concept, an embodiment of the present application further provides a computer program product for use in combination with an electronic device, the computer program product comprising a computer program embedded in a computer readable storage medium, the computer program comprising An instruction to cause the electronic device to perform each of the steps of any of the above methods.
为了描述的方便,以上所述装置的各部分以功能分为各种模块分别描述。当然,在实施本申请时可以把各模块或单元的功能在同一个或多个软件或硬件中实现。For the convenience of description, the various parts of the above-described apparatus are separately described by functions into various modules. Of course, the functions of each module or unit may be implemented in the same software or hardware in the implementation of the present application.
本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art will appreciate that embodiments of the present application can be provided as a method, system, or computer program product. Thus, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment in combination of software and hardware. Moreover, the application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流 程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (system), and computer program products according to embodiments of the present application. It will be understood that each flow and/or block of the flowchart and/or block diagrams, and combinations of flows and/or blocks in the flowcharts and/or block diagrams can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing device to produce a machine for the execution of instructions for execution by a processor of a computer or other programmable data processing device. Means for implementing the functions specified in one or more of the flow or in a block or blocks of the flow chart.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。The computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device. The apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device. The instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.
尽管已描述了本申请的优选实施例,但本领域内的技术人员一旦得知了基本创造性概念,则可对这些实施例作出另外的变更和修改。所以,所附权利要求意欲解释为包括优选实施例以及落入本申请范围的所有变更和修改。While the preferred embodiment of the present application has been described, it will be apparent that those skilled in the art can make further changes and modifications to the embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and the modifications and

Claims (12)

  1. 一种模板优化方法,其特征在于,所述方法包括:A template optimization method, the method comprising:
    获取AR图像模板;Obtain an AR image template;
    根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准;Determining that the image template quality does not satisfy the first criterion according to the image features included in the image template;
    为所述图像模板添加增强图像特征。An enhanced image feature is added to the image template.
  2. 如权利要求1所述的方法,其特征在于,所述根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准,包括:The method according to claim 1, wherein the determining, according to the image features included in the image template, that the image template quality does not satisfy the first criterion comprises:
    根据所述图像模板包含的图像特征的密度和/或聚集程度确定所述图像模板质量不满足第一标准。The image template quality is determined to not satisfy the first criterion based on the density and/or degree of aggregation of the image features contained in the image template.
  3. 如权利要求1或2中任一所述的方法,其特征在于,在所述为所述图像模板添加增强图像特征之前,还包括:The method according to any one of claims 1 to 2, further comprising: before adding the enhanced image feature to the image template,
    将所述图像模板划分为多个图像区域;Dividing the image template into a plurality of image regions;
    所述为所述图像模板添加增强图像特征,包括:Adding enhanced image features to the image template includes:
    为所述图像模板的质差区域添加增强图像特征,所述质差区域为根据各图像区域包含的图像特征确定的图像质量不满足第二标准的图像区域。An enhanced image feature is added to the quality difference region of the image template, the quality difference region being an image region whose image quality determined according to image features included in each image region does not satisfy the second standard.
  4. 如权利要求3所述的方法,其特征在于,所述方法还包括:The method of claim 3, wherein the method further comprises:
    在存在质优区域并且根据所述质优区域的分辨率确定所述质优区域能够划分时,将所述质优区域划分为多个区域,所述质优区域为根据各图像区域包含的图像特征确定的图像质量满足第二标准的区域。When there is a high quality area and it is determined that the high quality area can be divided according to the resolution of the high quality area, the high quality area is divided into a plurality of areas, and the high quality area is an image according to each image area The feature-determined image quality satisfies the area of the second standard.
  5. 如权利要求3或4中任一所述的方法,其特征在于,所述第二标准根据图像区域包含的所有图像特征对应的Harris响应值的均值阈值和方差阈值确定。The method of any of claims 3 or 4, wherein the second criterion is determined based on a mean threshold and a variance threshold of Harris response values corresponding to all image features included in the image region.
  6. 一种模板优化装置,其特征在于,所述装置包括:A template optimization device, characterized in that the device comprises:
    获取模块,用于获取AR图像模板;Obtaining a module, configured to acquire an AR image template;
    质量确定模块,用于根据所述图像模板包含的图像特征确定所述图像模板质量不满足第一标准;a quality determining module, configured to determine, according to the image features included in the image template, that the image template quality does not meet the first criterion;
    优化模块,用于为所述图像模板添加增强图像特征。An optimization module for adding enhanced image features to the image template.
  7. 如权利要求6所述的装置,其特征在于,所述质量确定模块具体用于,根据所述图像模板包含的图像特征的密度和/或聚集程度确定所述图像模板质量不满足第一标准。The apparatus according to claim 6, wherein the quality determining module is configured to determine that the image template quality does not satisfy the first criterion according to the density and/or the degree of aggregation of the image features included in the image template.
  8. 如权利要求6或7中任一所述的装置,其特征在于,所述装置还包括分区模块,用于在所述为所述图像模板添加增强图像特征之前,将所述图像模板划分为多个图像区域;The apparatus according to any one of claims 6 or 7, wherein said apparatus further comprises a partitioning module for dividing said image template into a plurality of said image templates prior to said adding an enhanced image feature to said image template Image area;
    所述优化模块具体用于,为所述图像模板的质差区域添加增强图像特征,所述质差区域为根据各图像区域包含的图像特征确定的图像质量不满足第二标准的图像区域。The optimization module is specifically configured to add an enhanced image feature to the quality difference region of the image template, where the quality difference region is an image region whose image quality determined according to image features included in each image region does not satisfy the second standard.
  9. 如权利要求8所述的装置,其特征在于,所述分区模块还用于,在存在质优区域并且根据所述质优区域的分辨率确定所述质优区域能够划分时,将所述质优区域划分为多个区域,所述质优区域为根据各图像区域包含的图像特征确定的图像质量满足第二标准的区域。The device according to claim 8, wherein the partitioning module is further configured to: when there is a high quality area and determine that the high quality area can be divided according to the resolution of the high quality area, The excellent area is divided into a plurality of areas, and the high quality area is an area in which the image quality determined according to the image features included in each image area satisfies the second standard.
  10. 如权利要求8或9中任一所述的装置,其特征在于,所述第二标准根据图像区域包含的所有图像特征对应的Harris响应值的均值阈值和方差阈值确定。The apparatus according to any one of claims 8 or 9, wherein said second criterion is determined based on a mean threshold and a variance threshold of Harris response values corresponding to all image features included in the image region.
  11. 一种电子设备,其特征在于,所述电子设备包括:An electronic device, comprising:
    存储器,一个或多个处理器;以及一个或多个模块,所述一个或多个模块被存储在所述存储器中,并被配置成由所述一个或多个处理器执行,所述一个或多个模块包括用于执行权利要求1至5中任一所述方法中各个步骤的指令。a memory, one or more processors; and one or more modules, the one or more modules being stored in the memory and configured to be executed by the one or more processors, the one or The plurality of modules includes instructions for performing the various steps of the method of any of claims 1 to 5.
  12. 一种与电子设备结合使用的计算机程序产品,所述计算机程序产 品包括内嵌于计算机可读的存储介质中的计算机程序,所述计算机程序包括用于使所述电子设备执行权利要求1至5中任一所述方法中的各个步骤的指令。A computer program product for use in conjunction with an electronic device, the computer program product comprising a computer program embedded in a computer readable storage medium, the computer program comprising means for causing the electronic device to perform claims 1 to 5 The instructions of the various steps in any of the methods described.
PCT/CN2018/075055 2018-02-02 2018-02-02 Template optimization method and device, electronic device and computer program product WO2019148442A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201880000097.2A CN108369731B (en) 2018-02-02 2018-02-02 Template optimization method, device, electronic equipment and computer program product
PCT/CN2018/075055 WO2019148442A1 (en) 2018-02-02 2018-02-02 Template optimization method and device, electronic device and computer program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/075055 WO2019148442A1 (en) 2018-02-02 2018-02-02 Template optimization method and device, electronic device and computer program product

Publications (1)

Publication Number Publication Date
WO2019148442A1 true WO2019148442A1 (en) 2019-08-08

Family

ID=63012593

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/075055 WO2019148442A1 (en) 2018-02-02 2018-02-02 Template optimization method and device, electronic device and computer program product

Country Status (2)

Country Link
CN (1) CN108369731B (en)
WO (1) WO2019148442A1 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103426003A (en) * 2012-05-22 2013-12-04 腾讯科技(深圳)有限公司 Implementation method and system for enhancing real interaction
CN106898018A (en) * 2017-01-22 2017-06-27 武汉秀宝软件有限公司 A kind of image continuous coupling method and system
US20170287154A1 (en) * 2016-03-29 2017-10-05 Fujitsu Limited Image processing apparatus and image processing method

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5299197B2 (en) * 2009-09-29 2013-09-25 コニカミノルタ株式会社 Image processing apparatus, image processing method, and program
US9317770B2 (en) * 2013-04-28 2016-04-19 Tencent Technology (Shenzhen) Co., Ltd. Method, apparatus and terminal for detecting image stability
CN105513071B (en) * 2015-12-08 2017-12-19 江苏省基础地理信息中心 A kind of topographic map symbols quality evaluating method
US10198624B2 (en) * 2016-02-18 2019-02-05 Pinscreen, Inc. Segmentation-guided real-time facial performance capture
CN106097378A (en) * 2016-07-24 2016-11-09 江西理工大学 A kind of level set retinal vascular images dividing method merging shape prior
CN106960436A (en) * 2017-03-20 2017-07-18 哈尔滨工业大学 A kind of remote sensing image process performance appraisal procedure
CN107451954A (en) * 2017-05-23 2017-12-08 南京邮电大学 Iterated pixel interpolation method based on image low-rank property
CN107452013A (en) * 2017-05-27 2017-12-08 深圳市美好幸福生活安全系统有限公司 Conspicuousness detection method based on Harris Corner Detections and Sugeno fuzzy integrals

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103426003A (en) * 2012-05-22 2013-12-04 腾讯科技(深圳)有限公司 Implementation method and system for enhancing real interaction
US20170287154A1 (en) * 2016-03-29 2017-10-05 Fujitsu Limited Image processing apparatus and image processing method
CN106898018A (en) * 2017-01-22 2017-06-27 武汉秀宝软件有限公司 A kind of image continuous coupling method and system

Also Published As

Publication number Publication date
CN108369731A (en) 2018-08-03
CN108369731B (en) 2023-07-21

Similar Documents

Publication Publication Date Title
US9881204B2 (en) Method for determining authenticity of a three-dimensional object
Cheng et al. Repfinder: finding approximately repeated scene elements for image editing
Aldoma et al. OUR-CVFH–oriented, unique and repeatable clustered viewpoint feature histogram for object recognition and 6DOF pose estimation
JP4739355B2 (en) Fast object detection method using statistical template matching
US20140204084A1 (en) Systems and Methods for Animating the Faces of 3D Characters Using Images of Human Faces
CN106991689B (en) Target tracking method based on FHOG and color characteristics and GPU acceleration
WO2015161816A1 (en) Three-dimensional facial recognition method and system
CN114627543A (en) Method and apparatus for face recognition
WO2019071976A1 (en) Panoramic image saliency detection method based on regional growth and eye movement model
WO2017070923A1 (en) Human face recognition method and apparatus
CN105868767B (en) Face feature point positioning method and device
TW201434010A (en) Image processor with multi-channel interface between preprocessing layer and one or more higher layers
JP2014134856A (en) Subject identification device, subject identification method, and subject identification program
Donoser et al. Robust planar target tracking and pose estimation from a single concavity
WO2014205787A1 (en) Vehicle detecting method based on hybrid image template
KR20110087620A (en) Layout based page recognition method for printed medium
Ahn et al. Segmenting a noisy low-depth-of-field image using adaptive second-order statistics
WO2019148442A1 (en) Template optimization method and device, electronic device and computer program product
Avazov et al. Automatic moving shadow detection and removal method for smart city environments
US20230410561A1 (en) Method and apparatus for distinguishing different configuration states of an object based on an image representation of the object
CN112749713B (en) Big data image recognition system and method based on artificial intelligence
WO2017179728A1 (en) Image recognition device, image recognition method, and image recognition program
CN112989304A (en) User authentication apparatus, user authentication method, and training method for user authentication
Ullah et al. A Robust Convolutional Neural Network for 6D Object Pose Estimation from RGB Image with Distance Regularization Voting Loss
CN116645525B (en) Game image recognition method and processing system

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201880000097.2

Country of ref document: CN

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18903232

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 01.12.2020)

122 Ep: pct application non-entry in european phase

Ref document number: 18903232

Country of ref document: EP

Kind code of ref document: A1