CN112113516A - Color raster phase decomposition method - Google Patents

Color raster phase decomposition method Download PDF

Info

Publication number
CN112113516A
CN112113516A CN202010774161.1A CN202010774161A CN112113516A CN 112113516 A CN112113516 A CN 112113516A CN 202010774161 A CN202010774161 A CN 202010774161A CN 112113516 A CN112113516 A CN 112113516A
Authority
CN
China
Prior art keywords
color
grating
period
main value
phase method
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010774161.1A
Other languages
Chinese (zh)
Other versions
CN112113516B (en
Inventor
周骥
杨承国
侯帅民
侯学东
贾文刚
石宋玮
乌珠克
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Inner Mongolia Nengjian Digital Information Technology Co ltd
Original Assignee
Inner Mongolia Nengjian Digital Information Technology Co ltd
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 Inner Mongolia Nengjian Digital Information Technology Co ltd filed Critical Inner Mongolia Nengjian Digital Information Technology Co ltd
Priority to CN202010774161.1A priority Critical patent/CN112113516B/en
Publication of CN112113516A publication Critical patent/CN112113516A/en
Application granted granted Critical
Publication of CN112113516B publication Critical patent/CN112113516B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B11/00Measuring arrangements characterised by the use of optical techniques
    • G01B11/24Measuring arrangements characterised by the use of optical techniques for measuring contours or curvatures
    • G01B11/25Measuring arrangements characterised by the use of optical techniques for measuring contours or curvatures by projecting a pattern, e.g. one or more lines, moiré fringes on the object
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B11/00Measuring arrangements characterised by the use of optical techniques
    • G01B11/02Measuring arrangements characterised by the use of optical techniques for measuring length, width or thickness
    • G01B11/06Measuring arrangements characterised by the use of optical techniques for measuring length, width or thickness for measuring thickness ; e.g. of sheet material
    • G01B11/0608Height gauges

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Image Analysis (AREA)
  • Length Measuring Devices By Optical Means (AREA)

Abstract

The invention relates to a structured light technology, in particular to a color raster phase demodulation method, which comprises the following steps: mapping color to number according to the collected color grating to generate color code; solving a main value of the periodic stripe grating based on Fourier transform, completing main value enhancement optimization, analyzing a sinusoidal periodic grating signal through a frequency domain, filtering noise, and improving the adaptive capacity of the algorithm environment; analyzing the period of the main value and extracting a period line; calculating the grating period according to the period line, the color code and the main value; the phase is calculated using the period and the main value. The invention solves the defects of the traditional phase solution method, firstly avoids misleading of initial period errors to solution of other periods, and skillfully avoids error propagation; and compared with a black-white grating, the color grating reduces the acquisition noise of the camera and improves the robustness of the algorithm.

Description

Color raster phase decomposition method
Technical Field
The invention relates to a structured light technology, in particular to a color raster phase demodulation method.
Background
The phase can be calculated by a plurality of gratings in the current structured light technology, and the applicable scenes are static measurement, so that the single-grating phase-demodulation method has more application scenes and simple operation compared with the multi-grating phase-demodulation method, and has important significance for industrial landing and energized production and scientific research.
The traditional single-amplitude grating phase solution is mostly an iterative method, after a phase starting point is artificially selected, the next point is expanded one by one according to the adjacent period or the same period of the adjacent points, the method is only suitable for solving the smooth plane projection grating, and the influence on the image with the truncated grating, particularly on the grating with the truncated phase exceeding one period, is particularly great. Other solutions are mostly guidance methods, are developed one by one according to a guidance principle, use a large amount of time cost to exchange for precision, are improved in initial point positioning compared with the first method, but are not innovative in nature, still cannot get rid of error transmission, and do not support high concurrency.
Disclosure of Invention
In view of the problems in the prior art, the invention provides a color grating dephasing method, which solves the problems of low error conduction and efficiency of the traditional algorithm, the problems that the traditional algorithm is influenced by algorithm factors, and the measurement method can only be used in the environment that the measurement surface is smooth and static and a plurality of gratings are shot. The invention solves the problems, enhances the robustness of the algorithm, enriches the application environment of the algorithm, supports dynamic measurement, supports high concurrency and greatly improves the operation efficiency of the algorithm.
The specific technical scheme of the invention is as follows:
the experimental device comprises a monocular camera, a projector and a computer, wherein the projector is used for projecting a color grating image, the monocular camera is used for shooting the color grating image, the computer is used for calculating the phase, the camera is connected with the computer through a USB3.0 data line, the projector is connected with the computer through an HDMI connecting line, and the experimental device is characterized by comprising:
generating a camera image color code according to the color code;
encoding a color projection grating according to a pseudorandom sequence;
solving a main value of the periodic stripe grating based on Fourier transform;
extracting periodic lines according to the main value of the periodic stripe grating;
calculating the grating period according to the period lines, the color codes and the period stripe grating main values;
the phase is resolved according to the period and the period fringe grating principal value.
The above technical solution is further defined as follows:
optionally, the color projection grating is encoded according to a debruijn pseudorandom sequence.
Optionally, the color projection grating is encoded according to a debruijn pseudorandom sequence using three colors of red, green, and blue.
The color projection grating may encode 27 periods.
Optionally, color coding of the camera image is done using a color coding table.
Optionally, the main value of the periodic stripe grating is expressed by using a fourier transform formula as follows:
Figure BDA0002617764530000021
optionally, finding a point on the main value of the periodic stripe grating, querying color codes, recording colors, querying colors of two periods, recording colors, forming a random sequence by the three colors, corresponding to an actual period, traversing the main value of the periodic stripe grating, and solving to obtain the period.
The invention has the following beneficial effects:
1) compared with a black-and-white grating, the color grating is beneficial to the collection of a camera in natural light, and the robustness of the algorithm is improved;
2) the color grating solution phase uses a single picture, is used in a dynamic measurement environment, supports a mobile experiment and improves an algorithm essentially;
3) the color grating de-phasing algorithm supports high concurrency, greatly improves algorithm efficiency, saves time cost, supports real-time data processing, and enhances user experience;
4) the color grating solution phase avoids the transmission of error in a large range, which leads to the use of a large amount of error data;
drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below. It is obvious that the drawings in the following description are only some embodiments of the invention, and that other drawings can be derived from them by a person skilled in the art without inventive effort.
FIG. 1 shows a detection flow diagram of an embodiment of the present invention;
FIG. 2 shows a schematic of the structure of an experiment of the present invention;
fig. 3 is a raster pattern.
Detailed Description
In order to make the objects, features and advantages of the present invention more obvious and understandable, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. It is to be understood that the following description is only a few embodiments of the present invention, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present invention without any inventive step, are within the scope of the present invention.
As shown in fig. 1, the present invention includes:
step 1: and generating a camera image color code according to the color code.
The three colors of red, green and blue are digitally encoded, and an encoding basis is provided for image grating identification.
Step 2: the color projected sinusoidal grating is encoded according to a debruijn pseudorandom sequence.
Pseudo-random sequences are generated according to the following debruijn principle, and color projection sinusoidal gratings are generated according to a coding table.
The debruijn pseudorandom sequence B (k, n) is a cyclic sequence of k elements. All k elements of length n make up the sequence, occurring in its subsequence (in circular form), and only once.
Figure BDA0002617764530000031
Therefore, we generate a length-3 pseudorandom sequence using red, blue and green, where k is 3 and n is 3, and the period of the generated color projection sinusoidal grating is 27
And step 3: and solving the main value of the periodic fringe grating based on Fourier transform.
In 1983, m.takeda et al used fourier transform for measuring three-dimensional surface shapes of objects, and proposed fourier transform profilometry, which uses one-dimensional fast fourier transform for measuring three-dimensional surface shapes of structured light fields. The method comprises the steps of projecting a sinusoidal grating onto the surface of a measured object through a projection system, obtaining deformation stripes modulated by the height distribution of the object through a camera system, sending the deformation stripes into a computer through an image acquisition system for fast Fourier transform, filtering and inverse Fourier transform, and solving the height distribution information of the object.
Fourier transform formula:
Figure BDA0002617764530000032
assuming that the period is 2 pi and the number of nodes is N, h-2 pi/N.
And 4, step 4: and extracting the period line according to the main value.
The (0,2 pi) main value, i.e. wrapped phase, is obtained through step 3, and in order to calculate continuous phase information by unwrapping the wrapped phase, a periodic line of main value variation needs to be extracted.
And 5: and calculating the grating period according to the period line, the color code and the main value.
Finding a point on the main value, inquiring color codes, recording colors, inquiring colors of two periods, recording colors, forming a random sequence by three colors after inquiry, corresponding to an actual period, traversing the main value, and solving to obtain the period.
The algorithm is as follows:
taking a point a on the main value, taking a point a1 at a corresponding position on the periodic line, and recording the corresponding value of a on the color code if a1 is 1; if a1 is not equal to 1, in decision a, if a >0, look forward to take the previous value on the periodic line until the value is 1, otherwise look backward to record the corresponding value of a on the color code. If the last period of the image, or the first period, is the case where the periodic line cannot be found in the half period, the reverse search is required.
Then, based on the color of the two subsequent cycles, if 323, a lookup into the random code starts with a third number, so the point is in the third cycle.
And sequentially unfolding to obtain the period of the whole graph.
Step 6: the phase is resolved according to the period and the period fringe grating principal value.
And (4) sequentially unfolding according to the relation between the main value (wrapping phase) and the period of the periodic stripe grating to obtain the unfolding phase of the shooting grating.
In fig. 3, the code for blue is "1", the code for green is "2", and the code for red is "3". In the encoding example, if the three raster colors in the screenshot are green, green and red, the corresponding period code is "223", the 15 th period is found in the pseudorandom sequence period "313231233113332232111222121", 15 × 2 pi + a of phase unwrapping (a is the wrapping phase), and each point and the corresponding period are sequentially traversed to obtain the unwrapped phase of the whole graph.
In conclusion, the method solves the defects of the traditional phase solution method, firstly avoids misleading of errors in the initial period to solution in other periods, and skillfully avoids error propagation; and compared with a black-white grating, the color grating reduces the acquisition noise of the camera and improves the robustness of the algorithm.

Claims (7)

1. A color raster demodulation phase method, comprising:
generating a camera image color code according to the color code;
encoding a color projection grating according to a pseudorandom sequence;
solving a main value of the periodic stripe grating based on Fourier transform;
extracting a periodic line according to the main value;
calculating the grating period according to the period lines, the color codes and the period stripe grating main values;
the phase is resolved according to the period and the period fringe grating principal value.
2. The color raster demodulation phase method of claim 1, characterized in that: the color projection grating is encoded according to a debruijn pseudorandom sequence.
3. The color raster demodulation phase method of claim 2, characterized in that: and encoding the color projection grating by adopting red, green and blue colors according to the debruijn pseudo-random sequence.
4. The color raster demodulation phase method of claim 3, characterized in that: the period of the color projection grating is 27.
5. The color raster demodulation phase method of claim 1, characterized in that: and completing the color coding of the camera image by using the color coding table.
6. The color raster demodulation phase method of claim 1, characterized in that: the main value of the periodic stripe grating is expressed by a Fourier transform formula as follows:
Figure FDA0002617764520000011
7. the color raster demodulation phase method of claim 1, characterized in that: finding a point on the main value of the periodic stripe grating, inquiring color codes, recording colors, inquiring colors of two periods, recording colors, forming a random sequence by three colors, corresponding to an actual period, traversing the main value of the periodic stripe grating, and solving to obtain the period.
CN202010774161.1A 2020-08-04 2020-08-04 Color raster phase decomposition method Active CN112113516B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010774161.1A CN112113516B (en) 2020-08-04 2020-08-04 Color raster phase decomposition method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010774161.1A CN112113516B (en) 2020-08-04 2020-08-04 Color raster phase decomposition method

Publications (2)

Publication Number Publication Date
CN112113516A true CN112113516A (en) 2020-12-22
CN112113516B CN112113516B (en) 2023-02-03

Family

ID=73799172

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010774161.1A Active CN112113516B (en) 2020-08-04 2020-08-04 Color raster phase decomposition method

Country Status (1)

Country Link
CN (1) CN112113516B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120008150A1 (en) * 2010-04-23 2012-01-12 Nikon Corporation Autofocus system and method
CN102496167A (en) * 2011-12-07 2012-06-13 天津理工大学 Pseudo-color coding method for phase modulated digital image
CN105180904A (en) * 2015-09-21 2015-12-23 大连理工大学 High-speed moving target position and posture measurement method based on coding structured light
CN110057319A (en) * 2019-02-20 2019-07-26 西安理工大学 A kind of high speed three-dimensional measurement method of a wide range of reflectivity changes object
CN110398199A (en) * 2019-07-05 2019-11-01 内蒙古能建数字信息科技有限公司 A kind of track clearance detection method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120008150A1 (en) * 2010-04-23 2012-01-12 Nikon Corporation Autofocus system and method
CN102496167A (en) * 2011-12-07 2012-06-13 天津理工大学 Pseudo-color coding method for phase modulated digital image
CN105180904A (en) * 2015-09-21 2015-12-23 大连理工大学 High-speed moving target position and posture measurement method based on coding structured light
CN110057319A (en) * 2019-02-20 2019-07-26 西安理工大学 A kind of high speed three-dimensional measurement method of a wide range of reflectivity changes object
CN110398199A (en) * 2019-07-05 2019-11-01 内蒙古能建数字信息科技有限公司 A kind of track clearance detection method

Also Published As

Publication number Publication date
CN112113516B (en) 2023-02-03

Similar Documents

Publication Publication Date Title
Zhang Absolute phase retrieval methods for digital fringe projection profilometry: A review
CN107036556B (en) Structured light three-dimensional measurement method based on segmented quantization phase coding
CN110645919B (en) Structured light three-dimensional measurement method based on airspace binary coding
CN111174730B (en) Rapid phase unwrapping method based on phase encoding
CN109341589A (en) A kind of raster image projecting method, three-dimensional rebuilding method and three-dimensional reconstruction system
CN110174079B (en) Three-dimensional reconstruction method based on four-step phase-shift coding type surface structured light
Porras-Aguilar et al. Absolute phase recovery in structured light illumination systems: sinusoidal vs. intensity discrete patterns
Tang et al. Micro-phase measuring profilometry: Its sensitivity analysis and phase unwrapping
CN111947599B (en) Three-dimensional measurement method based on learning fringe phase retrieval and speckle correlation
CN110006365B (en) Phase unwrapping method and device based on two-dimensional lookup table and electronic equipment
An et al. Temporal phase unwrapping based on unequal phase-shifting code
An et al. The absolute phase retrieval based on the rotation of phase-shifting sequence
Hu et al. Accurate and dynamic 3D shape measurement with digital image correlation-assisted phase shifting
An et al. Phase-shifting temporal phase unwrapping algorithm for high-speed fringe projection profilometry
CN113345039B (en) Three-dimensional reconstruction quantization structure optical phase image coding method
CN110428459A (en) A method of the Phase- un- wrapping based on numerical order coding
CN110440714B (en) Phase unwrapping method based on multi-frequency and binary stripes
CN112113516B (en) Color raster phase decomposition method
CN114252026B (en) Three-dimensional measurement method and system for modulating three-dimensional code on periodic edge
CN105180835B (en) The method that quick obtaining unpacks phase in streak reflex measurement
Ding et al. Recovering the absolute phase maps of three selected spatial-frequency fringes with multi-color channels
Wu et al. Self-correction of fringe order jump error induced by system nonlinearity based on phase-coding method
CN111815697A (en) Dynamic three-dimensional measurement method for thermal deformation
CN113310431B (en) Four-frame rapid three-dimensional measurement method based on phase coding
CN112330814B (en) Structured light three-dimensional reconstruction method based on machine learning

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant