WO2020024569A1 - 动态生成人脸三维模型的方法、装置、电子设备 - Google Patents

动态生成人脸三维模型的方法、装置、电子设备 Download PDF

Info

Publication number
WO2020024569A1
WO2020024569A1 PCT/CN2019/073081 CN2019073081W WO2020024569A1 WO 2020024569 A1 WO2020024569 A1 WO 2020024569A1 CN 2019073081 W CN2019073081 W CN 2019073081W WO 2020024569 A1 WO2020024569 A1 WO 2020024569A1
Authority
WO
WIPO (PCT)
Prior art keywords
face
dimensional model
feature point
depth information
face image
Prior art date
Application number
PCT/CN2019/073081
Other languages
English (en)
French (fr)
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 北京微播视界科技有限公司
Publication of WO2020024569A1 publication Critical patent/WO2020024569A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/50Depth or shape recovery
    • 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/30196Human being; Person
    • G06T2207/30201Face

Definitions

  • the present disclosure relates to the field of image processing and computer vision, and in particular, to a method, a device, and a computer-readable storage medium for dynamically generating a three-dimensional model of a human face.
  • the technical problem solved by the present disclosure is to provide a method for dynamically generating a three-dimensional model of a human face to at least partially solve the technical problem of how to improve the reality.
  • an apparatus, an electronic device, and a computer-readable storage medium for dynamically generating a three-dimensional model of a human face are also provided.
  • a method for dynamically generating a three-dimensional model of a human face includes:
  • a face image is attached to a three-dimensional model according to the grid and the depth information to generate a three-dimensional model of the face.
  • the first feature point includes:
  • Eyebrow feature points eye feature points, nose feature points, mouth feature points, and face contour feature points.
  • the step of dynamically generating a mesh based on the first feature point includes:
  • a triangulation mesh is generated on the face image using a triangulation method, and the triangulation mesh divides the face image into a plurality of regions.
  • obtaining the depth information of the first feature point includes:
  • depth information of the first feature point is searched in a depth information table, and the depth information table is a correspondence table between the number and depth information.
  • the obtaining the depth information of the first feature point includes:
  • depth information of the first feature point is searched in a depth information table, and the depth information table is a correspondence table between the number and depth information.
  • the step of fitting a face image to a three-dimensional model according to the grid and the depth information to generate a three-dimensional model of the face includes:
  • the acquiring a face image and identifying a first feature point corresponding to the standard face feature point on the face image includes:
  • the feature point selected by the feature point selection command is used as the first feature point.
  • obtaining the depth information of the first feature point includes:
  • An ethnic depth information table is acquired according to the ethnic information, and depth information of the first characteristic point is acquired in the ethnic depth information table according to the number of the first characteristic point.
  • applying a face image to a three-dimensional model according to the grid and the depth information to generate a three-dimensional model of the face includes:
  • applying a face image to a three-dimensional model according to the grid and the depth information to generate a three-dimensional model of the face includes:
  • a device for dynamically generating a three-dimensional model of a human face includes:
  • a three-dimensional model acquisition module configured to acquire a three-dimensional model, where standard facial feature points are preset on the three-dimensional model
  • a face image obtaining module configured to obtain a face image, and identify a first feature point corresponding to the standard face feature point on the face image;
  • a mesh generation module configured to dynamically generate a mesh according to the first feature point, and a vertex of the mesh is the first feature point;
  • a depth information acquisition module configured to acquire depth information of the first feature point
  • a face three-dimensional model generating module is configured to paste a face image onto a three-dimensional model according to the grid and the depth information to generate a three-dimensional face model.
  • the face image acquisition module is specifically configured to collect a face image from an image sensor, and identify a first feature point corresponding to the standard face feature point on the face image.
  • first feature points include: eyebrow feature points, eye feature points, nose feature points, mouth feature points, and face contour feature points.
  • the mesh generation module is specifically configured to generate a triangulation mesh on a face image using a triangulation method according to a first feature point, and the triangulation mesh divides the face image into multiple region.
  • the depth information obtaining module is specifically configured to find depth information of the first feature point in a depth information table according to the number of the first feature point, and the depth information table is a correspondence between the number and the depth information. table.
  • the face three-dimensional model generation module is specifically configured to adjust the coordinates of the standard face feature points according to the coordinates of the first feature point, adjust the depth of the standard face feature points according to the depth information, and After the face images in the grid are scaled, they are correspondingly fitted to the three-dimensional model to generate a three-dimensional model of the face.
  • the face image acquisition module is specifically configured to: collect a face image from an image sensor; identify feature points in the face image; receive a feature point selection command; and select the feature points selected by the feature point selection command As the first feature point.
  • the depth information obtaining module is specifically configured to obtain racial information according to the face image; obtain a racial depth information table based on the racial information; and according to the number of the first feature point, in the racial depth information table Acquire the depth information of the first feature point.
  • the face three-dimensional model generating module is specifically configured to generate the same triangulated mesh on the three-dimensional model as on the face image, and paste multiple regions on the face image to the three-dimensional In the corresponding region of the model, the depth of the standard face feature points is adjusted according to the depth information to generate a three-dimensional model of the face.
  • a plurality of face images are identified, a plurality of three-dimensional models are obtained, and the plurality of three-dimensional models correspond to the plurality of face images one-to-one; a corresponding three-dimensional model of the face is generated for each three-dimensional model.
  • An electronic device includes:
  • Memory for storing non-transitory computer-readable instructions
  • a processor configured to run the computer-readable instructions, so that the processor, when executed, implements the steps described in any one of the foregoing technical solutions for dynamically generating a three-dimensional model of a human face.
  • a computer-readable storage medium is used to store non-transitory computer-readable instructions, and when the non-transitory computer-readable instructions are executed by a computer, cause the computer to execute any one of the above methods for dynamically generating a three-dimensional model of a human face The steps described in the technical solution.
  • Embodiments of the present disclosure provide a method for dynamically generating a three-dimensional model of a human face, a device for dynamically generating a three-dimensional model of a human face, an electronic device, and a computer-readable storage medium.
  • the method for dynamically generating a three-dimensional model of a face includes: acquiring a three-dimensional model; acquiring a face image, identifying a first feature point corresponding to the standard face feature point on the face image; and according to the first
  • the feature points dynamically generate a grid, and the vertices of the grid are the first feature points; obtaining depth information of the first feature points; and fitting a face image to a three-dimensional surface according to the grid and the depth information.
  • Model to generate a three-dimensional model of the face can attach a face image to a three-dimensional model based on the mesh and depth information, thereby generating a three-dimensional model of the face, and improving the authenticity of the three-dimensional model.
  • FIG. 1 is a schematic flowchart of a method for dynamically generating a three-dimensional model of a human face according to an embodiment of the present disclosure
  • FIG. 2 is a schematic flowchart of a method for acquiring a face image according to an embodiment of the present disclosure
  • 3a is a schematic flowchart of a method for generating a three-dimensional model of a human face based on grid and depth information according to an embodiment of the present disclosure
  • 3b is a schematic flowchart of a method for generating a three-dimensional model of a human face based on grid and depth information according to another embodiment of the present disclosure
  • FIG. 4 is a schematic structural diagram of an apparatus for dynamically generating a three-dimensional model of a human face according to an embodiment of the present disclosure
  • FIG. 5 is a schematic structural diagram of an electronic device for dynamically generating a three-dimensional model of a human face according to an embodiment of the present disclosure
  • FIG. 6 is a schematic structural diagram of a computer-readable storage medium according to an embodiment of the present disclosure.
  • FIG. 7 is a schematic structural diagram of a face modeling terminal according to an embodiment of the present disclosure.
  • an embodiment of the present disclosure provides a method for dynamically generating a three-dimensional model of a face.
  • the method for dynamically generating a three-dimensional model of a human face mainly includes the following steps S1 to S5. among them:
  • Step S1 Obtain a three-dimensional model, where standard facial feature points are preset on the three-dimensional model.
  • the three-dimensional model is a humanoid model, and the humanoid model includes a human face model, and the human face feature points are preset on the human face model, that is, the standard human face set points.
  • the standard face recognition points on the three-dimensional model can be obtained according to a preset face recognition algorithm.
  • geometric feature-based methods usually need to be combined with other algorithms to have better results
  • template-based methods can be divided into methods based on correlation matching, eigenface methods, linear discriminant analysis methods, singular value decomposition methods, and neural network methods. , Dynamic connection matching methods, etc .
  • model-based methods include methods based on hidden Markov models, active shape models, and active appearance models. Those skilled in the art may consider these methods, improvements of these methods, or a combination of these methods with other methods when establishing the humanoid model.
  • Step S2 Acquire a face image, and identify a first feature point corresponding to the standard face feature point on the face image.
  • a face image can be acquired by an image sensor, or can be acquired by receiving an image.
  • This embodiment does not limit the manner of acquiring a face image.
  • Step S3 dynamically generate a mesh according to the first feature point, and a vertex of the mesh is the first feature point.
  • the mesh generation is to divide a specific region into many small sub-regions (elements), and the shape and distribution of each element in the mesh can be determined by an automatic mesh generation algorithm.
  • the grid which mainly includes structured grid and unstructured grid.
  • Structured mesh generation algorithms mainly include infinite interpolation methods and partial differential equation mesh generation methods; unstructured mesh generation algorithms mainly include node continuum method, mapping method and Delaunay triangulation method.
  • a person skilled in the art may select a method for implementing step S3 according to actual needs, for example, using a triangulation method.
  • Step S4 Obtain depth information of the first feature point.
  • each feature point may have depth information.
  • the depth information may be preset, each feature point includes a number, and the label is corresponding to the depth information in a table, which can be obtained by looking up the table when the depth information is needed.
  • the depth information may be obtained by estimation, for example, using an algorithm such as Make3D.
  • the depth information can be calculated using two shots or multiple shots.
  • Step S5 fit a face image onto a three-dimensional model according to the grid and the depth information to generate a three-dimensional model of the face.
  • a grid is generated based on a first feature point corresponding to the standard face feature point obtained by identifying a face image, and a three-dimensional face is generated based on the grid and depth information of the first feature point.
  • the three-dimensional face model obtained in this way has a high degree of realism.
  • the preset face recognition points on the face model of the three-dimensional model may include eyebrows, eyes, nose, mouth, and feature points of the contour of the face.
  • the number can be set in advance, such as 106 or 68, and each feature point can have depth information.
  • step S2 may be implemented by: collecting a face image from an image sensor; identifying a first feature point corresponding to the standard face feature point on the face image. Recognizing a face image can generally be achieved by identifying feature points, and then a first feature point corresponding to a standard face feature point can be obtained. The number of the first feature point is the same as the number of the standard face feature point.
  • the feature points on the three-dimensional model are also identified in advance according to the algorithm. In this embodiment, the same algorithm can be used to identify faces in the image sensor, and further A face image including the same feature points is obtained.
  • step S2 may be implemented in the following ways:
  • S21 Collect a face image from an image sensor; identify feature points in the face image.
  • the first feature points include: eyebrow feature points, eye feature points, nose feature points, mouth feature points, and facial contour feature points.
  • the number of feature points of each part can be set as required, and this embodiment does not specifically limit this.
  • S22 Receive a feature point selection command; use the feature point selected by the feature point selection command as a first feature point.
  • the user can select part of the feature points to select the fit area. For example, if the feature points of the eyes are selected, only the eye parts are fit during the final fitting, and other parts of the three-dimensional model of the face may also be preset.
  • the feature points or the area where the feature points are located can be displayed to the user in the form of a list or an image, and then the user issues the feature point selection command through an operation of selecting the feature points.
  • step S3 is implemented in the following manner: According to the first feature point, a triangulation mesh is generated on the face image using a triangulation method, and the triangulation mesh converts the face image Divided into multiple areas.
  • a triangulation mesh is generated in the following manner: first, a large triangle or polygon is established, and all the first feature points are enclosed; and then a point is inserted into the point and the point and The three vertices of the triangle are connected to form three new triangles, and then they are tested for the circumcircle one by one.
  • the local optimization process for example, the local optimization process of Lawson design known in the art
  • LOP is used to optimize the set.
  • the triangle network is guaranteed to be a Delaunay triangle network by exchanging diagonal lines.
  • step S4 is implemented by: finding depth information of the first feature point in a depth information table according to the number of the first feature point, and the depth information table is the number and Correspondence table of depth information. Obtaining depth information by looking up the table has high data processing efficiency.
  • the depth information of the first feature point may also be obtained by using a two-picture calculation method or directly using an existing depth camera.
  • the calculation method using the two pictures is as follows: using a binocular camera (or a single camera moves to different positions according to a set path) to capture left and right viewpoint images of the same scene; using a stereo matching algorithm to obtain a disparity map, and further Get depth information.
  • the stereo matching algorithm includes: a BM (Block Matching) algorithm, a SGBM (Semi-Global Block Matching) algorithm, and the like.
  • step S4 is implemented by: obtaining racial information according to the face image; obtaining a racial depth information table according to the racial information, and according to the number of the first feature point, the The depth information of the first feature point is obtained in the information table.
  • the races are identified through the identified faces, and then a depth information table with multiple races is set in advance to obtain the corresponding depth information. .
  • people can be identified in the following ways: obtaining a color face image; image preprocessing (for example, cropping, normalization, denoising, etc.); performing facial skin color feature extraction; converting the image into an 8-bit grayscale image, Use Gabor filtering to extract local facial features; combine the above-mentioned facial skin color features with local facial features, and there are more feature dimensions at this time; use Adaboost learning algorithm to reduce the feature dimension (for example, from 94464 dimensions to 150 dimensions) to reduce the amount of computation; the features after dimensionality reduction are input to an ethnic classifier (for example, a support vector machine classifier) for identification, and ethnic information is obtained.
  • the race classifier can be obtained by inputting large data and training based on an existing classification algorithm, which is not described herein.
  • the acquired depth information takes into account the differences between races, which is helpful to improve the similarity between the three-dimensional model of the face generated later and the actual face.
  • step S5 is implemented in the following manner:
  • S51a Adjust the coordinates of the standard face feature points according to the coordinates of the first feature point.
  • S52a Adjust the depth of a standard face feature point according to the depth information.
  • S53a After scaling the face image in the grid, it is correspondingly attached to the three-dimensional model to generate a three-dimensional model of the face.
  • the standard face feature points are adjusted according to the feature point coordinates of the face image to make them conform to the features of the actual face.
  • a specific implementation of this adjustment method is as follows: selecting the coordinate origin from the first feature point (for example, selecting the tip of the nose or the point on the lips as the coordinate origin); and setting the coordinates of the first feature point on the three-dimensional model based on the coordinate origin
  • the corresponding mesh vertices are calibrated.
  • this process can be implemented by 3D modeling software.
  • step S5 is implemented in the following manner:
  • S51b Generate the same triangulated mesh on the three-dimensional model as on the face image.
  • step S51b may be implemented in the following manner:
  • a coordinate origin is selected from the first feature point (for example, a nose tip point is selected as the coordinate origin), and the coordinates of the first feature point are used to mark the corresponding grid vertices on the three-dimensional model based on the coordinate origin.
  • this process can be implemented by 3D modeling software.
  • step b2 the first feature point is transformed into a three-dimensional space by projection to obtain the adjusted horizontal and vertical coordinate values of the standard face feature point, and the depth is determined based on the depth information of the corresponding vertex.
  • step b3 the feature points calibrated on the three-dimensional model are moved to the above projection position, and then the same triangulation mesh is generated on the three-dimensional model based on the same triangulation method on the face image.
  • S52b Paste multiple regions on the face image into corresponding regions of the three-dimensional model.
  • S53b Adjust the depth of a standard face feature point according to the depth information to generate a three-dimensional model of the face.
  • the same triangulation method is used for the three-dimensional model and the face image, and the triangle pieces may be correspondingly bonded during the bonding.
  • multiple three-dimensional models are obtained, and the multiple three-dimensional models correspond to the multiple face images one-to-one; corresponding ones are generated for each three-dimensional model.
  • Three-dimensional model of human face With this embodiment, a three-dimensional model of a face can be generated in batches, and can also be applied to a multi-person AR (Augmented Reality, augmented reality) scene, and a three-dimensional model of a face is generated for each person.
  • the present disclosure adopts the above technical solution to generate a grid based on a first feature point corresponding to the standard face feature point obtained by identifying a face image, and based on the grid and the first feature point
  • the three-dimensional model of the face is generated by the depth information of the image, and the three-dimensional model of the face thus obtained has a higher sense of reality.
  • processing such as uploading and evaluating (eg, a user scoring the authenticity or comparing with a known three-dimensional model of the user's face) is performed according to the generated three-dimensional model of the face.
  • the following is a device embodiment of the present disclosure.
  • the device embodiment of the present disclosure can be used to perform the steps implemented by the method embodiments of the present disclosure.
  • Only parts related to the embodiments of the present disclosure are shown. Specific technical details are not disclosed. Reference is made to the method embodiments of the present disclosure.
  • an embodiment of the present disclosure provides a device for dynamically generating a three-dimensional model of a face.
  • the apparatus for dynamically generating a three-dimensional model of a human face includes a three-dimensional model obtaining module 41, a face image obtaining module 42, a mesh generating module 43, a depth information obtaining module 44, and a three-dimensional face generating module 45. Details are described below.
  • the three-dimensional model obtaining module 41 is configured to obtain a three-dimensional model, and the three-dimensional model is preset with standard facial feature points.
  • the face image obtaining module 42 is configured to obtain a face image, and identify a first feature point corresponding to the standard face feature point on the face image.
  • the mesh generation module 43 is configured to dynamically generate a mesh according to the first feature point, and a vertex of the mesh is the first feature point.
  • the depth information acquisition module 44 is configured to acquire depth information of the first feature point.
  • the three-dimensional face model generation module 45 is configured to fit a face image onto a three-dimensional model according to the mesh and the depth information to generate a three-dimensional model of the face.
  • the face image acquisition module 42 is specifically configured to collect a face image from an image sensor, and identify a first feature corresponding to the standard face feature point on the face image. point.
  • the first feature points include: eyebrow feature points, eye feature points, nose feature points, mouth feature points, and facial contour feature points.
  • the mesh generation module 43 is specifically configured to generate a triangulation mesh on a face image using a triangulation method according to a first feature point, and the triangulation mesh will be The face image is divided into multiple regions.
  • the depth information obtaining module 44 is specifically configured to find the depth information of the first feature point in a depth information table according to the number of the first feature point, where the depth information table is all The correspondence table between the number and the depth information is described.
  • the face three-dimensional model generating module 45 is specifically configured to adjust the coordinates of the standard face feature points according to the coordinates of the first feature point, and adjust the standard people according to the depth information.
  • the depth of the feature points of the face, after scaling the face image in the grid, is correspondingly fitted to the three-dimensional model to generate a three-dimensional model of the face.
  • the face image acquisition module 45 is specifically configured to: collect a face image from an image sensor; identify feature points in the face image; receive a feature point selection command; The feature point selected by the selection command is used as the first feature point.
  • the depth information obtaining module 44 is specifically configured to: obtain race information according to the face image; obtain a race depth information table according to the race information, and according to the number of the first feature point, The depth information of the first feature point is obtained in the ethnic depth information table.
  • the face three-dimensional model generating module 45 is specifically configured to generate the same triangulated mesh on the three-dimensional model as on the face image, and convert the A plurality of regions are attached to corresponding regions of the three-dimensional model, and the depth of standard facial feature points is adjusted according to the depth information to generate a three-dimensional model of the face.
  • multiple three-dimensional models are obtained, and the multiple three-dimensional models correspond to the multiple face images one-to-one; a corresponding one is generated for each three-dimensional model.
  • Three-dimensional model of human face is obtained, and the multiple three-dimensional models correspond to the multiple face images one-to-one; a corresponding one is generated for each three-dimensional model.
  • FIG. 5 is a hardware block diagram illustrating an electronic device for dynamically generating a three-dimensional model of a human face according to an embodiment of the present disclosure.
  • the electronic device 50 for dynamically generating a three-dimensional model of a human face according to an embodiment of the present disclosure includes a memory 51 and a processor 52.
  • the memory 51 is configured to store non-transitory computer-readable instructions.
  • the memory 51 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory.
  • the volatile memory may include, for example, a random access memory (RAM) and / or a cache memory.
  • the non-volatile memory may include, for example, a read-only memory (ROM), a hard disk, a flash memory, and the like.
  • the processor 52 may be a central processing unit (CPU) or other form of processing unit having data processing capabilities and / or instruction execution capabilities, and may control other components in the device 50 for dynamically generating a three-dimensional model of a human face to perform a desired operation.
  • the processor 52 is configured to run the computer-readable instructions stored in the memory 51, so that the hardware device 50 for dynamically generating a three-dimensional model of a face performs the dynamics of the foregoing embodiments of the present disclosure. All or part of the method of generating a three-dimensional model of a face.
  • this embodiment may also include well-known structures such as a communication bus and an interface. These well-known structures should also be included in the protection scope of the present disclosure. within.
  • FIG. 6 is a schematic diagram illustrating a computer-readable storage medium according to an embodiment of the present disclosure.
  • a computer-readable storage medium 60 stores non-transitory computer-readable instructions 61 thereon.
  • the non-transitory computer-readable instruction 61 is executed by a processor, all or part of the steps of the foregoing method for dynamically generating a three-dimensional model of a human face according to the embodiments of the present disclosure are performed.
  • the computer-readable storage medium 60 includes, but is not limited to, optical storage media (for example, CD-ROM and DVD), magneto-optical storage media (for example, MO), magnetic storage media (for example, magnetic tape or mobile hard disk), Non-volatile memory rewritable media (for example: memory card) and media with built-in ROM (for example: ROM box).
  • optical storage media for example, CD-ROM and DVD
  • magneto-optical storage media for example, MO
  • magnetic storage media for example, magnetic tape or mobile hard disk
  • Non-volatile memory rewritable media for example: memory card
  • media with built-in ROM for example: ROM box
  • FIG. 7 is a schematic diagram illustrating a hardware structure of a terminal device according to an embodiment of the present disclosure.
  • the face modeling terminal 70 for dynamically generating a three-dimensional model of a face includes the foregoing embodiment of an apparatus for dynamically generating a three-dimensional model of a face.
  • the face modeling terminal device may be implemented in various forms, and the terminal device in the present disclosure may include, but is not limited to, such as a mobile phone, a smart phone, a notebook computer, a digital broadcast receiver, a PDA (Personal Digital Assistant), a PAD ( Tablet PC), PMP (Portable Multimedia Player), navigation device, vehicle terminal equipment, vehicle display terminal, vehicle electronic rearview mirror, etc., mobile terminal equipment, and fixed terminal equipment such as digital TV, desktop computer, etc.
  • PDA Personal Digital Assistant
  • PAD Tablet PC
  • PMP Portable Multimedia Player
  • the terminal may further include other components.
  • the face modeling terminal 70 may include a power supply unit 71, a wireless communication unit 72, an A / V (audio / video) input unit 73, a user input unit 74, a sensing unit 75, an interface unit 76, The controller 77, the output unit 78, the memory 79, and the like.
  • FIG. 7 illustrates a terminal having various components, but it should be understood that it is not required to implement all the illustrated components, and more or fewer components may be implemented instead.
  • the wireless communication unit 72 allows radio communication between the terminal 70 and a wireless communication system or network.
  • the A / V input unit 73 is used to receive audio or video signals.
  • the user input unit 74 may generate key input data according to a command input by the user to control various operations of the terminal device.
  • the sensing unit 75 detects the current state of the terminal 70, the position of the terminal 70, the presence or absence of a user's touch input to the terminal 70, the orientation of the terminal 70, the acceleration or deceleration movement and direction of the terminal 70, and the like, and generates a signal for controlling the terminal 70's operation command or signal.
  • the interface unit 76 functions as an interface through which at least one external device can be connected to the terminal 70.
  • the output unit 78 is configured to provide an output signal in a visual, audio, and / or tactile manner.
  • the memory 79 may store software programs and the like for processing and control operations performed by the controller 77, or may temporarily store data that has been output or is to be output.
  • the memory 79 may include at least one type of storage medium.
  • the terminal 70 can cooperate with a network storage device that performs a storage function of the memory 79 through a network connection.
  • the controller 77 generally controls the overall operation of the terminal device.
  • the controller 77 may include a multimedia module for reproducing or playing back multimedia data.
  • the controller 77 may perform a pattern recognition process to recognize a handwriting input or a picture drawing input performed on the touch screen as characters or images.
  • the power supply unit 71 receives external power or internal power under the control of the controller 77 and provides appropriate power required to operate each element and component.
  • Various embodiments of the method for dynamically generating a three-dimensional model of a face proposed by the present disclosure may be implemented in a computer-readable medium using, for example, computer software, hardware, or any combination thereof.
  • various embodiments of the method for dynamically generating a three-dimensional model of a face proposed by the present disclosure can be implemented by using an application-specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable At least one of a logic device (PLD), a field programmable gate array (FPGA), a processor, a controller, a microcontroller, a microprocessor, and an electronic unit designed to perform the functions described herein is implemented in some
  • ASIC application-specific integrated circuit
  • DSP digital signal processor
  • DSPD digital signal processing device
  • FPGA field programmable gate array
  • processor a controller, a microcontroller, a microprocessor, and an electronic unit designed to perform the functions described herein is implemented in some
  • various embodiments of the method for dynamically generating a three-dimensional model of a face proposed by the present disclosure may be implemented with a separate software module that allows performing at least one function or operation.
  • the software codes may be implemented by a software application (or program) written in any suitable programming language, and the software codes may be stored in the memory 79 and executed by the controller 77.
  • an "or” used in an enumeration of items beginning with “at least one” indicates a separate enumeration such that, for example, an "at least one of A, B, or C” enumeration means A or B or C, or AB or AC or BC, or ABC (ie A and B and C).
  • the word "exemplary” does not mean that the described example is preferred or better than other examples.
  • each component or each step can be disassembled and / or recombined.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computer Graphics (AREA)
  • Geometry (AREA)
  • Software Systems (AREA)
  • Processing Or Creating Images (AREA)
  • Image Analysis (AREA)

Abstract

一种动态生成人脸三维模型的方法、装置、电子设备及计算机存储介质。其中,该动态生成人脸三维模型的方法包括获取三维模型,所述三维模型上预设有标准人脸特征点(S1);获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点(S2);根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点(S3);获取所述第一特征点的深度信息(S4);根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型(S5)。通过上述方法,可以根据人脸图像的网格以及深度信息将人脸图像贴合到三维模型上,进而生成人脸三维模型,由此可以解决如何提高人脸模型真实度的技术问题。

Description

动态生成人脸三维模型的方法、装置、电子设备
交叉引用
本公开引用于2018年08月03日递交的名称为“动态生成人脸三维模型的方法、装置、电子设备”的、申请号为201810877075.6的中国专利申请,其通过引用被全部并入本申请。
技术领域
本公开涉及一种图像处理和计算机视觉领域,特别是涉及一种动态生成人脸三维模型的方法、装置及计算机可读存储介质。
背景技术
随着计算机视觉技术的发展以及人们在图像处理领域的需求,人脸建模技术得到广泛的关注。
从视觉角度来讲,人脸建模的最基本评价就是真实感。现有的一种人脸建模方法,通过对人脸图像进行切割然后将图像贴合到通用模型上生成人脸三维模型。这种方法虽然处理速度较快,但是,无法针对不同人脸生成反映个体特征的三维模型,真实度较低。
对此,如何提高真实感也就成为业界一直讨论与研究的问题。
发明内容
本公开解决的技术问题是提供一种动态生成人脸三维模型的方法,以至少部分地解决如何提高真实度的技术问题。此外,还提供一种动态生成人脸三维模型的装置、电子设备和计算机可读存储介质。
为了实现上述目的,根据本公开的一个方面,提供以下技术方案:
一种动态生成人脸三维模型的方法,包括:
获取三维模型,所述三维模型上预设有标准人脸特征点;
获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点;
根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点;
获取所述第一特征点的深度信息;
根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型。
进一步地,所述第一特征点包括:
眉毛特征点、眼睛特征点、鼻子特征点、嘴巴特征点以及脸部轮廓特征点。
进一步地,所述根据所述第一特征点动态生成网格,包括:
根据第一特征点,使用三角剖分法在人脸图像上生成三角剖分网格,所述三角剖分网格将人脸图像分为多个区域。
进一步地,所述获取所述第一特征点的深度信息,包括:
根据第一特征点的编号,在深度信息表中查找所述第一特征点的深度信息,所述深度信息表是所述编号与深度信息的对应表。
所述获取所述第一特征点的深度信息,包括:
根据第一特征点的编号,在深度信息表中查找所述第一特征点的深度信息,所述深度信息表是所述编号与深度信息的对应表。
进一步地,所述根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型,包括:
根据所述第一特征点的坐标调整所述标准人脸特征点的坐标,根据所述深度信息调整标准人脸特征点的深度,将所述网格中的人脸图像进行缩放之后,对应贴合到三维模型上,生成人脸三维模型。
进一步地,所述获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点包括:
从图像传感器中采集人脸图像;
识别人脸图像中的特征点;
接收特征点选择命令;
将所述特征点选择命令所选择的特征点作为第一特征点。
进一步地,所述获取所述第一特征点的深度信息,包括:
根据所述人脸图像获取人种信息;
根据人种信息获取人种深度信息表,根据第一特征点的编号,在人种深度信息表中获取第一特征点的深度信息。
进一步地,根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型,包括:
在所述三维模型上生成与人脸图像上同样的三角剖分网格,将所述人脸图像上的多个区域贴合到三维模型的对应区域中,并根据所述深度信息调整标准人脸特征点的深度,生成人脸三维模型。
进一步地,根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型,包括:
在所述三维模型上生成与人脸图像上同样的三角剖分网格,将所述人脸图像上的多个区域贴合到三维模型的对应区域中,并根据所述深度信息调整标准人脸特征点的深度,生成人脸三维模型。
为了实现上述目的,根据本公开的另一个方面,还提供以下技术方案:
一种动态生成人脸三维模型的装置,包括:
三维模型获取模块,用于获取三维模型,所述三维模型上预设有标准人脸特征点;
人脸图像获取模块,用于获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点;
网格生成模块,用于根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点;
深度信息获取模块,用于获取所述第一特征点的深度信息;
人脸三维模型生成模块,用于根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型。
进一步地,所述人脸图像获取模块具体用于从图像传感器中采集人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点。
进一步地,所述第一特征点包括:眉毛特征点、眼睛特征点、鼻子特征 点、嘴巴特征点以及脸部轮廓特征点。
进一步地,所述网格生成模块具体用于根据第一特征点,使用三角剖分法在人脸图像上生成三角剖分网格,所述三角剖分网格将人脸图像分为多个区域。
进一步地,所述深度信息获取模块具体用于根据第一特征点的编号,在深度信息表中查找所述第一特征点的深度信息,所述深度信息表是所述编号与深度信息的对应表。
进一步地,所述人脸三维模型生成模块具体用于:根据所述第一特征点的坐标调整所述标准人脸特征点的坐标,根据所述深度信息调整标准人脸特征点的深度,将所述网格中的人脸图像进行缩放之后,对应贴合到三维模型上,生成人脸三维模型。
进一步地,所述人脸图像获取模块具体用于:从图像传感器中采集人脸图像;识别人脸图像中的特征点;接收特征点选择命令;将所述特征点选择命令所选择的特征点作为第一特征点。
进一步地,所述深度信息获取模块具体用于:根据所述人脸图像获取人种信息;根据人种信息获取人种深度信息表,根据第一特征点的编号,在人种深度信息表中获取第一特征点的深度信息。
进一步地,所述人脸三维模型生成模块具体用于:在所述三维模型上生成与人脸图像上同样的三角剖分网格,将所述人脸图像上的多个区域贴合到三维模型的对应区域中,并根据所述深度信息调整标准人脸特征点的深度,生成人脸三维模型。
进一步地,当识别出有多个人脸图像时,获取多个三维模型,所述多个三维模型与所述多个人脸图像一一对应;对每个三维模型生成对应的人脸三维模型。
为了实现上述目的,根据本公开的又一个方面,还提供以下技术方案:
一种电子设备,包括:
存储器,用于存储非暂时性计算机可读指令;以及
处理器,用于运行所述计算机可读指令,使得所述处理器执行时实现上述任一动态生成人脸三维模型的方法技术方案中所述的步骤。
为了实现上述目的,根据本公开的又一个方面,还提供以下技术方案:
一种计算机可读存储介质,用于存储非暂时性计算机可读指令,当所述 非暂时性计算机可读指令由计算机执行时,使得所述计算机执行上述任一动态生成人脸三维模型的方法技术方案中所述的步骤。
为了实现上述目的,根据本公开的又一个方面,还提供以下技术方案:
本公开实施例提供一种动态生成人脸三维模型的方法、动态生成人脸三维模型的装置、电子设备、计算机可读存储介质。其中,该动态生成人脸三维模型的方法包括:获取三维模型;获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点;根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点;获取所述第一特征点的深度信息;根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型。本公开实施例通过采取该技术方案,可以基于网格和深度信息将人脸图像贴合到三维模型上,从而生成人脸三维模型,提高了三维模型的真实度。
上述说明仅是本公开技术方案的概述,为了能更清楚了解本公开的技术手段,而可依照说明书的内容予以实施,并且为让本公开的上述和其他目的、特征和优点能够更明显易懂,以下特举较佳实施例,并配合附图,详细说明如下。
附图说明
图1为根据本公开一个实施例的动态生成人脸三维模型的方法的流程示意图;
图2为根据本公开一个实施例的获取人脸图像的方法的流程示意图;
图3a为根据本公开一个实施例的基于网格和深度信息生成人脸三维模型的方法的流程示意图;
图3b为根据本公开另一个实施例的基于网格和深度信息生成人脸三维模型的方法的流程示意图;
图4为根据本公开一个实施例的动态生成人脸三维模型的装置的结构示意图;
图5为根据本公开一个实施例的用于动态生成人脸三维模型的电子设备的结构示意图;
图6为根据本公开一个实施例的计算机可读存储介质的结构示意图;
图7为根据本公开一个实施例的人脸建模终端的结构示意图。
具体实施方式
以下通过特定的具体实例说明本公开的实施方式,本领域技术人员可由本说明书所揭露的内容轻易地了解本公开的其他优点与功效。显然,所描述的实施例仅仅是本公开一部分实施例,而不是全部的实施例。本公开还可以通过另外不同的具体实施方式加以实施或应用,本说明书中的各项细节也可以基于不同观点与应用,在没有背离本公开的精神下进行各种修饰或改变。需说明的是,在不冲突的情况下,以下实施例及实施例中的特征可以相互组合。基于本公开中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本公开保护的范围。
需要说明的是,下文描述在所附权利要求书的范围内的实施例的各种方面。应显而易见,本文中所描述的方面可体现于广泛多种形式中,且本文中所描述的任何特定结构及/或功能仅为说明性的。基于本公开,所属领域的技术人员应了解,本文中所描述的一个方面可与任何其它方面独立地实施,且可以各种方式组合这些方面中的两者或两者以上。举例来说,可使用本文中所阐述的任何数目个方面来实施设备及/或实践方法。另外,可使用除了本文中所阐述的方面中的一或多者之外的其它结构及/或功能性实施此设备及/或实践此方法。
还需要说明的是,以下实施例中所提供的图示仅以示意方式说明本公开的基本构想,图式中仅显示与本公开中有关的组件而非按照实际实施时的组件数目、形状及尺寸绘制,其实际实施时各组件的型态、数量及比例可为一种随意的改变,且其组件布局型态也可能更为复杂。
另外,在以下描述中,提供具体细节是为了便于透彻理解实例。然而,所属领域的技术人员将理解,可在没有这些特定细节的情况下实践所述方面。
为了解决如何提高人脸模型的真实度的技术问题,本公开实施例提供一种动态生成人脸三维模型的方法。如图1所示,该动态生成人脸三维模型的方法主要包括如下步骤S1至步骤S5。其中:
步骤S1:获取三维模型,所述三维模型上预设有标准人脸特征点。
其中,三维模型为人形模型,所述人形模型包括人脸模型,所述人脸模型上预设有人脸特征点,即所述标准人脸设别点。三维模型上的标准人脸识别点可以根据预设的人脸识别算法得到。
整体来讲,人脸识别技术大致可以归结为如下几类:基于几何特征的方法、基于模板的方法和基于模型的方法。其中,基于几何特征的方法通常需要和其他算法结合才能有比较好的效果;基于模板的方法可以分为基于相关匹配的方法、特征脸方法、线性判别分析方法、奇异值分解方法、神经网络方法、动态连接匹配方法等;基于模型的方法则有基于隐马尔柯夫模型、主动形状模型和主动外观模型的方法等。本领域技术人员在建立所述人形模型时,可以考虑这些方法、这些方法的改进、或者这些方法与其他方法的结合。
步骤S2:获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点。
其中,人脸图像可以通过图像传感器采集得到,也可以通过接收图像而获取。本实施例并不限制人脸图像的获取方式。
步骤S3:根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点。
其中,网格生成是把特定区域分割成由许多很小的子区域(元素),网格中的每个元素的形状和分布可以通过自动的网格生成算法来确定。通常,根据网格的连接关系来区分,主要包括结构化网格和非结构化网格。结构化网格生成算法主要有无限插值方法和偏微分方程网格生成方法;非结构化网格生成算法主要有结点连元法、映射法和Delaunay三角化方法。本领域技术人员可以根据实际需要选择实现本步骤S3的方法,例如,采用三角剖分法。
步骤S4:获取所述第一特征点的深度信息。
其中,可以每个特征点都有深度信息。在一个应用中,深度信息可以是预设的,每个特征点包括编号,在一个表中将标号和深度信息对应,需要深度信息时查表获取即可。在另一个应用中,深度信息可通过估算获得,例如,采用诸如Make3D之类的算法估算。在另一个应用中,深度信息可以使用两次拍摄或者多次拍摄计算出来。
步骤S5:根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型。
采用本公开技术方案,基于识别人脸图像得到的与所述标准人脸特征点对应的第一特征点生成网格,并基于该网格以及所述第一特征点的深度信息生成人脸三维模型,这样得到的人脸三维模型具有较高的真实感。
下面以具体实施例对图1所示相关步骤进行详细说明,这些说明意在举例以使技术方案更容易理解。
在一个可选的实施例中,在步骤S1中,所述三维模型的人脸模型上预设的人脸识别点可以包括眉毛、眼睛、鼻子、嘴巴以及脸轮廓的特征点等,特征点的数量可以预先设置,比如106个或者68个等等,每个特征点可以有深度信息。
在一个可选的实施例中,步骤S2可以通过以下方式实现:从图像传感器中采集人脸图像;在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点。识别人脸图像一般可以使用特征点的识别来实现,之后可以获取与标准人脸特征点对应的第一特征点,第一特征点的编号与标准人脸特征点的编号相同。如前文所述,人脸识别算法很多,而在实际使用中,三维模型上的特征点也是根据算法预先识别出来的,在本实施例中可以使用同样的算法识别图像传感器中的人脸,进而得到包括同样的特征点的人脸图像。
在一个可选的实施例中,参照图2,步骤S2可以通过以下方式实现:
S21:从图像传感器中采集人脸图像;识别人脸图像中的特征点。其中,所述第一特征点包括:眉毛特征点、眼睛特征点、鼻子特征点、嘴巴特征点以及脸部轮廓特征点。各个部位的特征点的数量可以根据需要设置,本实施例对此不作具体限制。
S22:接收特征点选择命令;将所述特征点选择命令所选择的特征点作为第一特征点。
采用该实施例,可以由用户选择部分特征点,以此选择贴合区域。比如选择眼睛的特征点,则最终贴合时,只贴合眼睛部分,人脸三维模型的其他部分也可以是预设的。其中,可以以列表、图像的方式将特征点或特征点所在区域展示给用户,进而由用户通过选择特征点的操作发出所述特征点选择命令。
在一个可选的实施例中,步骤S3通过以下方式实现:根据第一特征点,使用三角剖分法在人脸图像上生成三角剖分网格,所述三角剖分网格将人脸图像分为多个区域。
作为本实施例的一种实现,采用以下方式生成三角剖分网格:首先建立一个大的三角形或多边形,把所有的第一特征点包围起来;然后向其中插入一点,该点与包含它的三角形三个顶点相连,形成三个新的三角形,然后逐 个对它们进行空外接圆检测,同时用局部最优化过程(例如,本领域所熟知的Lawson设计的局部最优化过程)LOP进行优化,集通过交换对角线的方法来保证所形成的三角网为Delaunay三角网。
作为本实施例的另一种实现,采用以下步骤生成三角剖分网格:
首先,建立初始三角网格。具体而言,针对第一特征点的点集,找到一个包含该点集的矩形,连接该矩形的任意一条对角线,形成两个三角形,作为初始三角网格。
然后,逐点插入。具体而言,假设目前已经有一个三角网格T,现在在它里面再插入一个P,需要找到该点P所在的三角形。从P所在的三角形开始,搜索该三角形的邻近三角形,并进行空外接圆检测。找到外接圆包含点P的所有的三角形并删除这些三角形,形成一个包含P的多边形空腔,然后连接P与多边形空腔的每一个顶点,形成新的三角网格。
最后,删除前面所述的矩形。具体而言,重复执行前述逐点插入处理,当点集中所有点都已经插入到三角形网格中后,将顶点包含签署矩形的三角形全部删除。
在一个可选的实施例中,步骤S4通过以下方式实现:根据第一特征点的编号,在深度信息表中查找所述第一特征点的深度信息,所述深度信息表是所述编号与深度信息的对应表。通过查表的方式获取深度信息,具有较高的数据处理效率。除此之外,还可以采用两幅图计算方式、或者直接使用现有的深度摄像机,得到第一特征点的深度信息。
其中,所述采用两幅图计算方式如下:采用双目相机(或者单个摄像机按设定路径移动到不同位置)拍摄同一场景的左、右两幅视点图像;采用立体匹配算法获取视差图,进而获取深度信息。其中,示例性地,所述立体匹配算法包括:BM(Block Matching)算法、SGBM(Semi-Global Block matching)算法等。
当然,在一些其他应用中,不限于两幅图,还可以是两幅以上。
在一个可选的实施例中,步骤S4通过以下方式实现:根据所述人脸图像获取人种信息;根据人种信息获取人种深度信息表,根据第一特征点的编号,在人种深度信息表中获取第一特征点的深度信息。
在本实施例中,考虑到不同人种的脸型有差异,深度信息也有不同,所以通过识别的人脸识别出人种,然后查找预先设置有多个人种的深度信息表,得到对应的深度信息。
其中,可以采用以下方式识别人种:获取彩色人脸图像;图像预处理(例如,裁剪、归一化、去噪等);进行人脸肤色特征提取;将图像转换为8位灰度图,采用Gabor滤波提取人脸局部特征;将上述人脸肤色特征和人脸局部特征结合,此时的特征维度较多;采用Adaboost学习算法将特征维数进行降维处理(例如,由94464维降到150维)以降低运算量;将降维之后的特征输入人种分类器(例如,支持向量机分类器)进行识别,得到人种信息。所述人种分类器可以通过输入大数据、基于现有的分类算法训练得到,此处不赘述。
采用该实施例,获取的深度信息考虑了人种差异,有利于提高后续生成的人脸三维模型与实际人脸的相似度。
在一个可选的实施例中,如图3a所示,步骤S5通过以下方式实现:
S51a:根据所述第一特征点的坐标调整所述标准人脸特征点的坐标。
S52a:根据所述深度信息调整标准人脸特征点的深度。
S53a:将所述网格中的人脸图像进行缩放之后,对应贴合到三维模型上,生成人脸三维模型。
在本实施例中,根据人脸图像的特征点坐标调整标准人脸特征点,使其符合实际人脸的特征。该调整方式的一种具体实现如下:从第一特征点中选取坐标原点(例如,选取鼻尖点或者嘴唇上的点作为坐标原点);基于该坐标原点将第一特征点的坐标在三维模型上标定出对应的网格顶点。示例性地,该过程可以通过三维建模软件实现。
在一个可选的实施例中,如图3b所示,步骤S5通过以下方式实现:
S51b:在所述三维模型上生成与人脸图像上同样的三角剖分网格。
在本实施例中,具体而言,步骤S51b可以采用以下方式实现:
步骤b1,从第一特征点中选取坐标原点(例如,选取鼻尖点作为坐标原点),基于该坐标原点将第一特征点的坐标在三维模型上标定出对应的网格顶点。示例性地,该过程可以通过三维建模软件实现。
步骤b2,将第一特征点通过投影变换到三维空间中,得到调整后的标准人脸特征点的横坐标值和纵坐标值,深度则基于对应顶点的深度信息确定。
步骤b3,将在三维模型上标定的特征点移至上述投影位置,然后基于同样的三角剖分法在三维模型上生成与人脸图像上同样的三角剖分网格。
S52b:将所述人脸图像上的多个区域贴合到三维模型的对应区域中。
S53b:根据所述深度信息调整标准人脸特征点的深度,生成人脸三维模型。
在本实施例中,三维模型和人脸图像使用同样的三角剖分方式,贴合时对应贴合三角片即可。
在一个可选的实施例中,当识别出有多个人脸图像时,获取多个三维模型,所述多个三维模型与所述多个人脸图像一一对应;对每个三维模型生成对应的人脸三维模型。采用该实施例,可以批量生成人脸三维模型,还可以应用到多人AR(Augmented Reality,增强现实)场景中,对每个人分别生成一个人脸三维模型。
根据前文描述可知,本公开通过采取上述技术方案,基于识别人脸图像得到的与所述标准人脸特征点对应的第一特征点生成网格,并基于该网格以及所述第一特征点的深度信息生成人脸三维模型,这样得到的人脸三维模型具有较高的真实感。
本领域技术人员应能理解,在上述获得较高真实感的实施例的基础上,还可以进行明显变型或等同替换,例如,本领域技术人员可以在兼顾上述真实感的同时,合理地调整(例如,删除、增加、移动)特征点、改变网格划分方法、改变深度信息的获取方法、改变坐标调整方法等。
本公开实施例在具体实施时,在上述实施例的基础上,还可以增加相应的步骤。例如,根据生成的人脸三维模型进行上传、评价(例如,用户对于真实度打分,或者,与已知的用户人脸三维模型进行比对)等处理。
下面为本公开装置实施例,本公开装置实施例可用于执行本公开方法实施例实现的步骤,为了便于说明,仅示出了与本公开实施例相关的部分,具体技术细节未揭示的,请参照本公开方法实施例。
为了解决如何提高人脸模型的真实度的技术问题,本公开实施例提供一种动态生成人脸三维模型的装置。参照图4,所述动态生成人脸三维模型的装置包括三维模型获取模块41、人脸图像获取模块42、网格生成模块43、深度信息获取模块44和人脸三维模型生成模块45。下面进行详细说明。
在本实施例中,三维模型获取模块41用于获取三维模型,所述三维模型上预设有标准人脸特征点。
在本实施例中,人脸图像获取模块42用于获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点。
在本实施例中,网格生成模块43用于根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点。
在本实施例中,深度信息获取模块44用于获取所述第一特征点的深度信息。
在本实施例中,人脸三维模型生成模块45用于根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型。
在一种可选实施例中,所述人脸图像获取模块42具体用于从图像传感器中采集人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点。
在一种可选实施例中,所述第一特征点包括:眉毛特征点、眼睛特征点、鼻子特征点、嘴巴特征点以及脸部轮廓特征点。
在一种可选实施例中,所述网格生成模块43具体用于根据第一特征点,使用三角剖分法在人脸图像上生成三角剖分网格,所述三角剖分网格将人脸图像分为多个区域。
在一种可选实施例中,所述深度信息获取模块44具体用于根据第一特征点的编号,在深度信息表中查找所述第一特征点的深度信息,所述深度信息表是所述编号与深度信息的对应表。
在一种可选实施例中,所述人脸三维模型生成模块45具体用于:根据所述第一特征点的坐标调整所述标准人脸特征点的坐标,根据所述深度信息调整标准人脸特征点的深度,将所述网格中的人脸图像进行缩放之后,对应贴合到三维模型上,生成人脸三维模型。
在一种可选实施例中,所述人脸图像获取模块45具体用于:从图像传感器中采集人脸图像;识别人脸图像中的特征点;接收特征点选择命令;将所述特征点选择命令所选择的特征点作为第一特征点。
在一种可选实施例中,所述深度信息获取模块44具体用于:根据所述人脸图像获取人种信息;根据人种信息获取人种深度信息表,根据第一特征点的编号,在人种深度信息表中获取第一特征点的深度信息。
在一种可选实施例中,所述人脸三维模型生成模块45具体用于:在所述三维模型上生成与人脸图像上同样的三角剖分网格,将所述人脸图像上的多个区域贴合到三维模型的对应区域中,并根据所述深度信息调整标准人脸特征点的深度,生成人脸三维模型。
在一种可选实施例中,当识别出有多个人脸图像时,获取多个三维模型,所述多个三维模型与所述多个人脸图像一一对应;对每个三维模型生成对应的人脸三维模型。
有关动态生成人脸三维模型的工作原理、实现的技术效果等详细说明可以参考前述动态生成人脸三维模型的方法实施例中的相关说明,在此不再赘述。
图5是图示根据本公开的实施例的用于动态生成人脸三维模型的电子设备的硬件框图。如图5所示,根据本公开实施例的用于动态生成人脸三维模型的电子设备50包括存储器51和处理器52。
该存储器51用于存储非暂时性计算机可读指令。具体地,存储器51可以包括一个或多个计算机程序产品,该计算机程序产品可以包括各种形式的计算机可读存储介质,例如易失性存储器和/或非易失性存储器。该易失性存储器例如可以包括随机存取存储器(RAM)和/或高速缓冲存储器(cache)等。该非易失性存储器例如可以包括只读存储器(ROM)、硬盘、闪存等。
该处理器52可以是中央处理单元(CPU)或者具有数据处理能力和/或指令执行能力的其它形式的处理单元,并且可以控制动态生成人脸三维模型的装置50中的其它组件以执行期望的功能。在本公开的一个实施例中,该处理器52用于运行该存储器51中存储的该计算机可读指令,使得该动态生成人脸三维模型的硬件装置50执行前述的本公开各实施例的动态生成人脸三维模型的方法的全部或部分步骤。
本领域技术人员应能理解,为了解决如何获得良好用户体验效果的技术问题,本实施例中也可以包括诸如通信总线、接口等公知的结构,这些公知的结构也应包含在本公开的保护范围之内。
有关本实施例的详细说明可以参考前述各实施例中的相应说明,在此不再赘述。
图6是图示根据本公开的实施例的计算机可读存储介质的示意图。如图6所示,根据本公开实施例的计算机可读存储介质60,其上存储有非暂时性计算机可读指令61。当该非暂时性计算机可读指令61由处理器运行时,执行前述的本公开各实施例的动态生成人脸三维模型的方法的全部或部分步骤。
上述计算机可读存储介质60包括但不限于:光存储介质(例如:CD-ROM和DVD)、磁光存储介质(例如:MO)、磁存储介质(例如:磁带或移动硬盘)、具有内置的可重写非易失性存储器的媒体(例如:存储卡)和具有 内置ROM的媒体(例如:ROM盒)。
有关本实施例的详细说明可以参考前述各实施例中的相应说明,在此不再赘述。
图7是图示根据本公开实施例的终端设备的硬件结构示意图。如图7所示,该用于动态生成人脸三维模型的人脸建模终端70包括上述动态生成人脸三维模型的装置实施例。
该人脸建模终端设备可以以各种形式来实施,本公开中的终端设备可以包括但不限于诸如移动电话、智能电话、笔记本电脑、数字广播接收器、PDA(个人数字助理)、PAD(平板电脑)、PMP(便携式多媒体播放器)、导航装置、车载终端设备、车载显示终端、车载电子后视镜等等的移动终端设备以及诸如数字TV、台式计算机等等的固定终端设备。
作为等同替换的实施方式,该终端还可以包括其他组件。如图7所示,该人脸建模终端70可以包括电源单元71、无线通信单元72、A/V(音频/视频)输入单元73、用户输入单元74、感测单元75、接口单元76、控制器77、输出单元78和存储器79等等。图7示出了具有各种组件的终端,但是应理解的是,并不要求实施所有示出的组件,也可以替代地实施更多或更少的组件。
其中,无线通信单元72允许终端70与无线通信系统或网络之间的无线电通信。A/V输入单元73用于接收音频或视频信号。用户输入单元74可以根据用户输入的命令生成键输入数据以控制终端设备的各种操作。感测单元75检测终端70的当前状态、终端70的位置、用户对于终端70的触摸输入的有无、终端70的取向、终端70的加速或减速移动和方向等等,并且生成用于控制终端70的操作的命令或信号。接口单元76用作至少一个外部装置与终端70连接可以通过的接口。输出单元78被构造为以视觉、音频和/或触觉方式提供输出信号。存储器79可以存储由控制器77执行的处理和控制操作的软件程序等等,或者可以暂时地存储己经输出或将要输出的数据。存储器79可以包括至少一种类型的存储介质。而且,终端70可以与通过网络连接执行存储器79的存储功能的网络存储装置协作。控制器77通常控制终端设备的总体操作。另外,控制器77可以包括用于再现或回放多媒体数据的多媒体模块。控制器77可以执行模式识别处理,以将在触摸屏上执行的手写输入或者图片绘制输入识别为字符或图像。电源单元71在控制器77的控制下接收外部电力或内部电力并且提供操作各元件和组件所需的适当的电力。
本公开提出的动态生成人脸三维模型的方法的各种实施方式可以以使 用例如计算机软件、硬件或其任何组合的计算机可读介质来实施。对于硬件实施,本公开提出的动态生成人脸三维模型的方法的各种实施方式可以通过使用特定用途集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理装置(DSPD)、可编程逻辑装置(PLD)、现场可编程门阵列(FPGA)、处理器、控制器、微控制器、微处理器、被设计为执行这里描述的功能的电子单元中的至少一种来实施,在一些情况下,本公开提出的动态生成人脸三维模型的的方法的各种实施方式可以在控制器77中实施。对于软件实施,本公开提出的动态生成人脸三维模型的方法的各种实施方式可以与允许执行至少一种功能或操作的单独的软件模块来实施。软件代码可以由以任何适当的编程语言编写的软件应用程序(或程序)来实施,软件代码可以存储在存储器79中并且由控制器77执行。
有关本实施例的详细说明可以参考前述各实施例中的相应说明,在此不再赘述。
以上结合具体实施例描述了本公开的基本原理,但是,需要指出的是,在本公开中提及的优点、优势、效果等仅是示例而非限制,不能认为这些优点、优势、效果等是本公开的各个实施例必须具备的。另外,上述公开的具体细节仅是为了示例的作用和便于理解的作用,而非限制,上述细节并不限制本公开为必须采用上述具体的细节来实现。
本公开中涉及的器件、装置、设备、系统的方框图仅作为例示性的例子并且不意图要求或暗示必须按照方框图示出的方式进行连接、布置、配置。如本领域技术人员将认识到的,可以按任意方式连接、布置、配置这些器件、装置、设备、系统。诸如“包括”、“包含”、“具有”等等的词语是开放性词汇,指“包括但不限于”,且可与其互换使用。这里所使用的词汇“或”和“和”指词汇“和/或”,且可与其互换使用,除非上下文明确指示不是如此。这里所使用的词汇“诸如”指词组“诸如但不限于”,且可与其互换使用。
另外,如在此使用的,在以“至少一个”开始的项的列举中使用的“或”指示分离的列举,以便例如“A、B或C的至少一个”的列举意味着A或B或C,或AB或AC或BC,或ABC(即A和B和C)。此外,措辞“示例的”不意味着描述的例子是优选的或者比其他例子更好。
还需要指出的是,在本公开的系统和方法中,各部件或各步骤是可以分解和/或重新组合的。这些分解和/或重新组合应视为本公开的等效方案。
可以不脱离由所附权利要求定义的教导的技术而进行对在此所述的技术的各种改变、替换和更改。此外,本公开的权利要求的范围不限于以上所述的处理、机器、制造、事件的组成、手段、方法和动作的具体方面。可以 利用与在此所述的相应方面进行基本相同的功能或者实现基本相同的结果的当前存在的或者稍后要开发的处理、机器、制造、事件的组成、手段、方法或动作。因而,所附权利要求包括在其范围内的这样的处理、机器、制造、事件的组成、手段、方法或动作。
提供所公开的方面的以上描述以使本领域的任何技术人员能够做出或者使用本公开。对这些方面的各种修改对于本领域技术人员而言是非常显而易见的,并且在此定义的一般原理可以应用于其他方面而不脱离本公开的范围。因此,本公开不意图被限制到在此示出的方面,而是按照与在此公开的原理和新颖的特征一致的最宽范围。
为了例示和描述的目的已经给出了以上描述。此外,此描述不意图将本公开的实施例限制到在此公开的形式。尽管以上已经讨论了多个示例方面和实施例,但是本领域技术人员将认识到其某些变型、修改、改变、添加和子组合。

Claims (13)

  1. 一种动态生成人脸三维模型的方法,包括:
    获取三维模型,所述三维模型上预设有标准人脸特征点;
    获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点;
    根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点;
    获取所述第一特征点的深度信息;
    根据所述网格以及所述深度信息将人脸图像贴合到三维模型上以生成人脸三维模型。
  2. 根据权利要求1所述的动态生成人脸三维模型的方法,其中所述获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点包括:
    从图像传感器中采集人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点。
  3. 根据权利要求2所述的动态生成人脸三维模型的方法,其中所述第一特征点包括:
    眉毛特征点、眼睛特征点、鼻子特征点、嘴巴特征点以及脸部轮廓特征点。
  4. 根据权利要求1所述的动态生成人脸三维模型的方法,其中所述根据所述第一特征点动态生成网格,包括:
    根据第一特征点,使用三角剖分法在人脸图像上生成三角剖分网格,所述三角剖分网格将所述人脸图像分为多个区域。
  5. 根据权利要求1所述的动态生成人脸三维模型的方法,其中所述获 取所述第一特征点的深度信息,包括:
    根据第一特征点的编号,在深度信息表中查找所述第一特征点的深度信息。
  6. 根据权利要求1所述的动态生成人脸三维模型的方法,其中所述根据所述网格以及所述深度信息将人脸图像贴合到三维模型上以生成人脸三维模型,包括:
    根据所述第一特征点的坐标调整所述标准人脸特征点的坐标,根据所述深度信息调整标准人脸特征点的深度,将所述网格中的人脸图像进行缩放之后,对应贴合到三维模型上,生成人脸三维模型。
  7. 根据权利要求1所述的动态生成人脸三维模型的方法,其中所述获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点包括:
    从图像传感器中采集人脸图像;
    识别人脸图像中的特征点;
    接收特征点选择命令;
    将所述特征点选择命令所选择的特征点作为第一特征点。
  8. 根据权利要求1所述的动态生成人脸三维模型的方法,其中所述获取所述第一特征点的深度信息,包括:
    根据所述人脸图像获取人种信息;
    根据人种信息获取人种深度信息表;
    根据第一特征点的编号在人种深度信息表中获取第一特征点的深度信息。
  9. 根据权利要求4所述的动态生成人脸三维模型的方法,其中根据所述网格以及所述深度信息将人脸图像贴合到三维模型上以生成人脸三维模型,包括:
    在所述三维模型上生成与人脸图像上同样的三角剖分网格,将所述人脸图像上的多个区域贴合到三维模型的对应区域中,并根据所述深度信息调整标准人脸特征点的深度,生成人脸三维模型。
  10. 根据权利要求1所述的动态生成人脸三维模型的方法,其中:
    当识别出有多个人脸图像时,获取多个三维模型,所述多个三维模型与所述多个人脸图像一一对应;
    对每个三维模型生成对应的人脸三维模型。
  11. 一种动态生成人脸三维模型的装置,包括:
    三维模型获取模块,用于获取三维模型,所述三维模型上预设有标准人脸特征点;
    人脸图像获取模块,用于获取人脸图像,在所述人脸图像上识别与所述标准人脸特征点对应的第一特征点;
    网格生成模块,用于根据所述第一特征点动态生成网格,所述网格的顶点为所述第一特征点;
    深度信息获取模块,用于获取所述第一特征点的深度信息;
    人脸三维模型生成模块,用于根据所述网格以及所述深度信息将人脸图像贴合到三维模型上,以生成人脸三维模型。
  12. 一种电子设备,包括:
    存储器,用于存储非暂时性计算机可读指令;以及
    处理器,用于运行所述计算机可读指令,使得所述处理器执行时实现根据权利要求1-10中任意一项所述的动态生成人脸三维模型的方法。
  13. 一种计算机可读存储介质,用于存储非暂时性计算机可读指令,当所述非暂时性计算机可读指令由计算机执行时,使得所述计算机执行权利要求1-10中任意一项所述的动态生成人脸三维模型的方法。
PCT/CN2019/073081 2018-08-03 2019-01-25 动态生成人脸三维模型的方法、装置、电子设备 WO2020024569A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810877075.6 2018-08-03
CN201810877075.6A CN109118579A (zh) 2018-08-03 2018-08-03 动态生成人脸三维模型的方法、装置、电子设备

Publications (1)

Publication Number Publication Date
WO2020024569A1 true WO2020024569A1 (zh) 2020-02-06

Family

ID=64851895

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/073081 WO2020024569A1 (zh) 2018-08-03 2019-01-25 动态生成人脸三维模型的方法、装置、电子设备

Country Status (2)

Country Link
CN (1) CN109118579A (zh)
WO (1) WO2020024569A1 (zh)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109118579A (zh) * 2018-08-03 2019-01-01 北京微播视界科技有限公司 动态生成人脸三维模型的方法、装置、电子设备
CN109816791B (zh) * 2019-01-31 2020-04-28 北京字节跳动网络技术有限公司 用于生成信息的方法和装置
CN110047119B (zh) * 2019-03-20 2021-04-13 北京字节跳动网络技术有限公司 包含动态背景的动画生成方法、装置及电子设备
CN110059660A (zh) * 2019-04-26 2019-07-26 北京迈格威科技有限公司 移动端平台3d人脸注册方法及装置
CN110223374A (zh) * 2019-05-05 2019-09-10 太平洋未来科技(深圳)有限公司 一种预置标准人脸及头部3d模型方法
CN110675475B (zh) * 2019-08-19 2024-02-20 腾讯科技(深圳)有限公司 一种人脸模型生成方法、装置、设备及存储介质
CN111083373B (zh) * 2019-12-27 2021-11-16 恒信东方文化股份有限公司 一种大屏幕及其智能拍照方法
CN111601181B (zh) * 2020-04-27 2022-04-29 北京首版科技有限公司 生成视频指纹数据的方法及装置
CN112381928A (zh) * 2020-11-19 2021-02-19 北京百度网讯科技有限公司 图像显示的方法、装置、设备以及存储介质
CN113506367B (zh) * 2021-08-24 2024-02-27 广州虎牙科技有限公司 一种三维人脸模型训练方法、三维人脸重建方法及相关装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104376594A (zh) * 2014-11-25 2015-02-25 福建天晴数码有限公司 三维人脸建模方法和装置
CN105913416A (zh) * 2016-04-06 2016-08-31 中南大学 一种自动分割三维人脸模型区域的方法
CN107993216A (zh) * 2017-11-22 2018-05-04 腾讯科技(深圳)有限公司 一种图像融合方法及其设备、存储介质、终端
CN109118579A (zh) * 2018-08-03 2019-01-01 北京微播视界科技有限公司 动态生成人脸三维模型的方法、装置、电子设备

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100468465C (zh) * 2007-07-13 2009-03-11 中国科学技术大学 基于虚拟图像对应的立体视觉三维人脸建模方法
CN101593365A (zh) * 2009-06-19 2009-12-02 电子科技大学 一种通用三维人脸模型的调整方法
CN102222363B (zh) * 2011-07-19 2012-10-03 杭州实时数码科技有限公司 从人脸图像快速构建高精度个性化人脸模型的方法
CN103116902A (zh) * 2011-11-16 2013-05-22 华为软件技术有限公司 三维虚拟人头像生成方法、人头像运动跟踪方法和装置
CN103035022B (zh) * 2012-12-07 2015-04-01 大连大学 基于特征点的人脸表情合成方法
CN104268932A (zh) * 2014-09-12 2015-01-07 上海明穆电子科技有限公司 3d脸型自动变化方法及系统
JP6754619B2 (ja) * 2015-06-24 2020-09-16 三星電子株式会社Samsung Electronics Co.,Ltd. 顔認識方法及び装置
CN105513007A (zh) * 2015-12-11 2016-04-20 惠州Tcl移动通信有限公司 一种基于移动终端的拍照美颜方法、系统及移动终端
CN105678252A (zh) * 2016-01-05 2016-06-15 安阳师范学院 依据人脸三角网格自适应细分和高斯小波的迭代插值方法
CN106203400A (zh) * 2016-07-29 2016-12-07 广州国信达计算机网络通讯有限公司 一种人脸识别方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104376594A (zh) * 2014-11-25 2015-02-25 福建天晴数码有限公司 三维人脸建模方法和装置
CN105913416A (zh) * 2016-04-06 2016-08-31 中南大学 一种自动分割三维人脸模型区域的方法
CN107993216A (zh) * 2017-11-22 2018-05-04 腾讯科技(深圳)有限公司 一种图像融合方法及其设备、存储介质、终端
CN109118579A (zh) * 2018-08-03 2019-01-01 北京微播视界科技有限公司 动态生成人脸三维模型的方法、装置、电子设备

Also Published As

Publication number Publication date
CN109118579A (zh) 2019-01-01

Similar Documents

Publication Publication Date Title
WO2020024569A1 (zh) 动态生成人脸三维模型的方法、装置、电子设备
JP7191213B2 (ja) 顔モデルの生成方法、装置、電子機器及びコンピュータ可読記憶媒体
US10860838B1 (en) Universal facial expression translation and character rendering system
KR102565755B1 (ko) 얼굴의 특징점의 움직임에 따라 모션이 수행된 아바타를 표시하는 전자 장치와 이의 동작 방법
WO2020029554A1 (zh) 增强现实多平面模型动画交互方法、装置、设备及存储介质
WO2020019663A1 (zh) 基于人脸的特效生成方法、装置和电子设备
CN109063560B (zh) 图像处理方法、装置、计算机可读存储介质和终端
CN108986016B (zh) 图像美化方法、装置及电子设备
US11176355B2 (en) Facial image processing method and apparatus, electronic device and computer readable storage medium
US11276238B2 (en) Method, apparatus and electronic device for generating a three-dimensional effect based on a face
US8976182B2 (en) Facial sketch creation device, configuration information generation device, configuration information generation method, and storage medium
WO2020019664A1 (zh) 基于人脸的形变图像生成方法和装置
KR101794399B1 (ko) 사용자 얼굴의 복합 다중 감정 인식 방법 및 시스템
CN108830787A (zh) 图像变形的方法、装置及电子设备
US11727675B2 (en) Object detection with instance detection and general scene understanding
US11978248B1 (en) Scene graph-based scene re-identification
US10269165B1 (en) Facial animation models
CN104378620A (zh) 一种图像处理方法及电子设备
JP2023529790A (ja) フロアプランを生成するための方法、装置およびプログラム
CN112561071A (zh) 根据3d语义网格的对象关系估计
US20210158565A1 (en) Pose selection and animation of characters using video data and training techniques
CN108989681A (zh) 全景图像生成方法和装置
CN114862997A (zh) 图像渲染方法和装置、介质和计算机设备
US11488352B1 (en) Modeling a geographical space for a computer-generated reality experience
CN113384892A (zh) 场景模型的素材图片获取和展示方法、装置及存储介质

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: 19844495

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

122 Ep: pct application non-entry in european phase

Ref document number: 19844495

Country of ref document: EP

Kind code of ref document: A1