Optical multi-point focusing method based on NSGA2-R algorithm
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- TAIYUAN UNIVERSITY OF TECHNOLOGY
- Filing Date
- 2025-03-03
- Publication Date
- 2026-08-07
AI Technical Summary
然而,这些方法大多只能实现单点聚焦,且优化效率较低,难以满足多点聚焦和大范围扫描的需求
[0019]本发明的有益效果是:本发明提出了一种基于NSGA2-R算法的光学多点聚焦方法,以建立的光学系统为模型,通过动态调整突变率的改进型非支配排序遗传算法(NSGA2-R),实现了在散射介质中的高质量多点聚焦。该方法能够在初始聚焦阶段生成高亮度和均匀性的焦点,并通过动态调整突变率进一步优化聚焦效果,显著提高聚焦效率和均匀性。
Smart Images

Figure CN119986958B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of optical imaging and optical manipulation technology, specifically relating to an optical multi-point focusing method based on the NSGA2-R algorithm, which is used to achieve multi-point focusing through a scattering medium and is applicable to fields such as optical capture, optogenetics, and fluorescence imaging. Background Technology
[0002] Optical focusing and imaging have wide applications in biomedical imaging, optical manipulation, and optical communication. However, the presence of scattering media (such as biological tissue, fog, and frosted glass) can severely interfere with light propagation. Traditional optical focusing methods struggle to achieve multi-point focusing in scattering media, leading to blurred images and low focusing efficiency. In recent years, wavefront shaping techniques based on genetic algorithms (GA) have been proposed to improve focusing quality in scattering media. However, most of these methods can only achieve single-point focusing and have low optimization efficiency, making it difficult to meet the needs of multi-point focusing and large-area scanning. Furthermore, multi-point focusing requires simultaneous optimization of multiple objectives (such as focus intensity and uniformity), which places higher demands on the algorithm's global search capability and optimization efficiency, requirements that current technologies often cannot meet. Summary of the Invention
[0003] The technical problem to be solved by this invention is: how to achieve high-quality multi-point focusing in a scattering medium.
[0004] The technical solution adopted in this invention is: an optical multi-point focusing method based on the NSGA2-R algorithm. The laser emitted by the laser source (1) is conjugated to the spatial light modulator (SLM). The spatial light modulator (5) modulates the laser irradiated on it and then conjugates it to the rear plane of the first microscope objective (9). The first microscope objective (9) focuses the laser onto the front surface of the scattering medium (10). The laser passing through the scattering medium (10) is received by the second microscope objective (11). After passing through the second microscope objective (11), the laser is received by the camera (12). The computer (13) connected to the camera (12) and the spatial light modulator (5) generates a wavefront phase mask through the NSGA2-R algorithm on it. The spatial light modulator (5) modulates the laser using the wavefront phase mask, and the camera (12) obtains the optimal laser focus intensity and uniformity of the laser multi-point focusing.
[0005] The computer (13) connected to the camera (12) and the spatial light modulator (5) generates a wavefront phase mask using the NSGA2-R algorithm. The spatial light modulator (5) modulates the laser using the wavefront phase mask, including the following:
[0006] Step 1: Initially, the computer (13) generates a set of random wavefront phase masks as the initial population of the NSGA2-R algorithm. Each wavefront phase mask represents a wavefront modulation scheme. Each wavefront phase mask generates a set number of focal points on the camera (12). The set number is greater than or equal to 3. The camera (12) feeds back the number of focal points and the intensity of the received laser to the computer (13).
[0007] Step 2: The NSGA2-R algorithm establishes the focus enhancement function f1 and the uniformity coefficient function f2 between the focus points, evaluates the performance of the wavefront phase mask, and inputs the number of focus points and focus intensity fed back by the camera (12) into the focus enhancement function f1 and the uniformity coefficient function f2 between the focus points. The larger the value of the focus enhancement function f1, the better the performance of the wavefront phase mask. The smaller the value of the uniformity coefficient function f2 between the focus points, the better the performance of the wavefront phase mask.
[0008] Step 3: The NSGA2-R algorithm performs non-dominated sorting and crowding distance calculation on the population based on the performance evaluation results of the wavefront phase mask, and selects excellent wavefront phase masks. Specifically, a rectangular coordinate system is established with the focal enhancement function f1 value of the focal point as the x-axis and the uniformity coefficient function f2 value between focal points as the y-axis, with the origin being that both the focal enhancement function f1 value and the uniformity coefficient function f2 value between focal points are 0. The distance between the coordinate points corresponding to the uniformity coefficient function f2 value between focal points of the wavefront phase mask and the coordinate points corresponding to the uniformity coefficient function f2 value between focal points is used as the crowding distance. Excellent wavefront phase masks are selected based on the performance of the wavefront phase mask and the crowding distance.
[0009] Step 4: The NSGA2-R algorithm performs a crossover operation on the selected wavefront phase masks, mapping a phase wavefront mask to a chromosome in the NSGA2-R algorithm. The phase of a single pixel on the SLM corresponds to the gene of the chromosome. The number of pixels and the number of genes are made consistent. Half of the gene count of any two chromosomes are crossed. A multi-point crossover method is adopted. At the same time, a dynamic mutation rate R is introduced. The mutation rate is dynamically adjusted according to the number of iterations, thereby dynamically changing the phase of the wavefront phase mask to balance the global search capability and the local optimization capability. A new population is generated to obtain a new set of wavefront phase masks. The new wavefront phase masks are loaded onto the spatial light modulator (5) to modulate the laser. The camera (12) feeds back the number of focal points and the focal intensity of the received laser to the computer (13).
[0010] Step 5: Repeat steps 2 to 4, each repetition being one iteration. Continue this process until the preset number of iterations is reached, or the focus intensity and uniformity no longer significantly improve, thus obtaining the optimal wavefront phase mask. The statement that the focus intensity no longer significantly improves means that the absolute value of the difference between the uniformity coefficient function f2 between the focal points before and after the iteration is less than the set value of the focus intensity. The statement that the uniformity no longer significantly improves means that the value of the uniformity coefficient function f2 between the focal points before and after the iteration is less than the set value of the uniformity. The statement that the laser emitted by the laser source (1) is conjugated to the spatial light modulator (5) means that after the laser emitted by the laser source (1) passes through the half-wave plate (2), it is conjugated to the spatial light modulator (5) in free space through the conjugation system composed of the first lens (3) and the second lens (4). The statement that it is conjugated to the rear plane of the first microscope objective (9) means that the laser modulated by the spatial light modulator (5) passes through the third lens (6), the aperture stop (7), and the fourth lens (8) in sequence, and is conjugated to the rear plane of the first microscope objective (9).
[0011] The focus enhancement function f1 of the focal point is
[0012]
[0013] Where M is the total number of focal points, I avg Let I be the average intensity of the M focal points. m Let f2 be the intensity of the m-th focal point; the uniformity coefficient function f2 between the focal points is...
[0014]
[0015] Where, σ m denoted as the standard deviation of the focal intensity.
[0016] The formula for calculating the dynamic mutation rate R is as follows:
[0017] R (n) =R0×(R end / R0) n / D
[0018] Where R0 is the initial mutation rate, R end denoted as the final mutation rate, D as the decay factor, and n as the number of iterations. The multi-point crossover method maintains the basic structure of the wavefront phase mask unchanged during the crossover process, performing crossover combinations only on local regions of the wavefront phase mask.
[0019] The beneficial effects of this invention are as follows: This invention proposes an optical multi-point focusing method based on the NSGA2-R algorithm. Using an established optical system as a model, a modified non-dominated sorting genetic algorithm (NSGA2-R) with dynamically adjusted mutation rate is used to achieve high-quality multi-point focusing in a scattering medium. This method can generate a high-brightness and uniform focus in the initial focusing stage, and further optimize the focusing effect by dynamically adjusting the mutation rate, significantly improving focusing efficiency and uniformity.
[0020] This invention features high focusing efficiency: the NSGA2-R algorithm with dynamic mutation rate significantly improves the efficiency and uniformity of multi-point focusing. It is also highly adaptable: suitable for various scattering media environments and has low requirements for the optical system. Furthermore, it possesses multi-point focusing capability: capable of simultaneously generating multiple high-brightness focal points, suitable for applications such as optical capture and fluorescence imaging. Attached Figure Description
[0021] Figure 1 This is a model diagram of the optical system of the present invention;
[0022] Figure 2 This is a flowchart of the process for obtaining the optimal wavefront phase mask according to the present invention;
[0023] Figure 3 This is a schematic diagram of the crossover and variation principle of the present invention;
[0024] Figure 4 This is a multi-point focusing effect diagram;
[0025] Figure 5 It shows the curves of focal intensity enhancement and uniformity coefficient as a function of the number of iterations. Detailed Implementation
[0026] To better understand the technology of this invention, the following description, in conjunction with the accompanying drawings, further illustrates the invention:
[0027] like Figure 1 As shown, the optical experimental system of the present invention includes the following main components:
[0028] Laser source 1 uses a continuous wave laser with a wavelength of 632.8nm to provide a stable light source. After the laser emitted by laser source 1 passes through half-wave plate 2, it is conjugated to spatial light modulator 5 in free space by a conjugate system composed of first lens 3 and second lens 4, and illuminates a 1080×1080 pixel area on spatial light modulator 5. Computer 13 generates a set of random wavefront phase masks (including phase information capable of modulating the laser, and the size of the wavefront phase mask is consistent with that of the spatial light modulator) as an initial population. Each mask (wavefront phase mask) represents a possible wavefront modulation scheme. The wavefront phase mask is loaded onto the spatial light modulator 5 for the spatial light modulator 5 to modulate the laser. The modulated laser passes sequentially through the third lens 6, the aperture stop 7, and the fourth lens 8, and is conjugate to the rear plane of the first microscope objective 9. The first microscope objective 9 focuses the laser onto the front surface of the scattering medium 10. The aperture stop 7 filters out the first-order diffraction light. After passing through the scattering medium 8, the laser is received by the second microscope objective 11 and then by the camera 12. The camera 12 extracts the intensity information of the speckle as a feedback signal and is received by the computer 13. The camera 12 measures the intensity and uniformity of the laser focus after passing through the scattering medium 10.
[0029] like Figure 2 As shown, the optimization process of the NSGA2-R algorithm is as follows:
[0030] Initial Population: Computer 13 generates a set of wavefront phase masks as the initial population and loads them onto the spatial light modulator (SLM). Each mask contains 1080×1080 pixels, or 108×108 modulation units, with one modulation unit corresponding to 10×10 pixels on the SLM. The number of wavefront phase masks in the initial population is N. The randomly generated initial population provides sufficient diversity for the algorithm, ensuring that the optimization process covers a wider solution space. A diverse initial population helps avoid the algorithm getting trapped in local optima, thereby improving global optimization capabilities.
[0031] Multi-objective optimization function construction: Computer 13 receives laser focus intensity values from camera 12 and constructs a feedback function including a focus intensity enhancement function f1 and a uniformity coefficient function f2 to evaluate the performance of each wavefront phase mask. The optimization function is as follows:
[0032] (1) Intensity enhancement function f1 at the focal point:
[0033]
[0034] Among them I avg Let I be the average intensity of M focal points, where M is the number of focal points. m Let be the intensity of the m-th focus. The goal of this function is to maximize the total intensity of all focus points, thereby improving focusing efficiency.
[0035] (2) Uniformity coefficient function f2 between focal points:
[0036]
[0037] In the formula, M represents the number of foci, and σ m I is the standard deviation of the focal intensity. m Let be the intensity of the m-th focus. The goal of this function is to minimize the inhomogeneity of focus intensities, ensuring that all focuses have similar intensities.
[0038] By simultaneously optimizing focal intensity and uniformity, the NSGA2-R algorithm achieves high-quality multi-point focusing in scattering media. The optimization function considers not only the total intensity of the focal points but also the uniformity between them, thus enabling stable multi-point focusing in complex scattering environments.
[0039] Non-dominated sorting: The computer performs non-dominated sorting on the initial population based on the results of the optimization function, and selects the best wavefront phase masks.
[0040] Crowding distance calculation: The computer calculates the crowding distance for each wavefront phase mask to ensure population diversity. Crossover and mutation operations: The computer 13 filters the population through steps 3 and 4, and then performs pairwise crossover and dynamic mutation operations on the wavefront phase masks within the population, such as... Figure 3 As shown, a phase wavefront mask is mapped to a chromosome in the NSGA2-R algorithm. The phase of a single pixel on the SLM corresponds to a gene of the chromosome. The number of pixels and the number of genes are made consistent. Half of the genes in any two chromosomes are crossed to generate a new chromosome. The genes on the chromosome are then mutated from "1" to "0" or from "0" to "1". After these two processes are completed, a brand new chromosome is generated, which is a brand new population of wavefront phase masks. The number of phase masks is the same as the number before the crossover and mutation operation.
[0041] Iterative optimization: Repeating the above three steps constitutes one iteration of optimization. This process is repeated continuously until a preset number of iterations is reached or the focus intensity and uniformity no longer significantly improve, resulting in the optimal phase mask. The computer 13 loads the optimal wavefront phase mask onto the spatial light modulator 5 for modulation of the laser by the spatial light modulator 5. The modulated laser sequentially passes through the third lens 6, the aperture stop 7, and the fourth lens 8, conjugating to the rear plane of the first microscope objective 9. The first microscope objective 9 concentrates the laser onto the front surface of the scattering medium 10, where the aperture stop 7 filters out the first-order diffraction light. After passing through the scattering medium 8, the laser is received by the second microscope objective 11 and then by the camera 12. The camera 12 extracts the speckle intensity information as a feedback signal, which is received by the computer 13. The camera 12 measures the focus intensity and uniformity of the laser after passing through the scattering medium 10.
[0042] The present invention will be further described in detail below with reference to the implementation scheme:
[0043] Implementation Plan 1:
[0044] This implementation scheme aims to achieve high-quality multi-point focusing through the scattering medium using the NSGA2-R algorithm, verify the optimization capability of this method in terms of focus intensity and uniformity, and compare it with the traditional method (GA algorithm).
[0045] Prior conditions: Laser source 1 uses a continuous wave laser with a wavelength of 632.8 nm to provide a stable light source; the laser emitted from laser source 1 passes through half-wave plate 2 and is conjugated in free space by a conjugate system composed of first lens 3 and second lens 4 to spatial light modulator 5, illuminating a 1080×1080 pixel area on spatial light modulator 5. Computer 13 generates a set of random wavefront phase masks (including phase information capable of modulating the laser, and the size of the wavefront phase mask is consistent with that of the spatial light modulator) as an initial population. Each mask represents a possible wavefront modulation scheme, and the wavefront phase mask is used to load onto spatial light modulator 5 for modulation of the laser by spatial light modulator 5. The modulated laser passes sequentially through third lens 6, aperture stop 7, and fourth lens 8, and is conjugated to the rear plane of first microscope objective 9. First microscope objective 9 concentrates the laser onto the front surface of scattering medium 10. In the scattering medium 8, the aperture stop 7 filters out the first-order diffracted light; after passing through the scattering medium 8, the laser light is received by the second microscope objective 11, and then by the camera 12. The camera 12 extracts the intensity information of the speckle as a feedback signal, which is received by the computer 13. The camera 12 measures the intensity and uniformity of the laser focus after passing through the scattering medium 10; the parameter settings in the NSGA2-R algorithm are: population size N = 50, number of iterations n = 600, number of focal points M = 16, and the initial mutation rate R0 in the dynamic mutation rate R = 0.01, and the final mutation rate R = R end The value is 0.002, the attenuation factor D is 250, and the phase mask resolution is 1080×1080 pixels.
[0046] Multi-point focus contrast effect, such as Figure 4 As shown, Figure 4 In (a), the focus map of 16 points is shown under the NSGA2-R algorithm. It can be seen that the intensity uniformity of each focus is good. Figure 4 In (b), the image shows a focused image of 16 points using the GA algorithm, which demonstrates poor focus uniformity. These images were all obtained from camera 12.
[0047] In summary, it can be seen that the NASGA2-R algorithm outperforms the GA algorithm in multi-point focusing.
[0048] Implementation Plan Two:
[0049] This implementation scheme aims to verify the superior optical multi-point focusing performance of the NSGA2-R algorithm by using the curves showing the changes in focus intensity enhancement and uniformity coefficient with the number of iterations.
[0050] Prior conditions: Laser source 1 uses a continuous wave laser with a wavelength of 632.8 nm to provide a stable light source; the laser emitted from laser source 1 passes through half-wave plate 2 and is conjugated in free space by a conjugate system composed of first lens 3 and second lens 4 to spatial light modulator 5, illuminating a 1080×1080 pixel area on spatial light modulator 5. Computer 13 generates a set of random wavefront phase masks (including phase information capable of modulating the laser, and the size of the wavefront phase mask is consistent with that of the spatial light modulator) as an initial population. Each mask represents a possible wavefront modulation scheme, and the wavefront phase mask is used to load onto spatial light modulator 5 for modulation of the laser by spatial light modulator 5. The modulated laser passes sequentially through third lens 6, aperture stop 7, and fourth lens 8, and is conjugated to the rear plane of first microscope objective 9. First microscope objective 9 concentrates the laser onto the front surface of scattering medium 10. In the scattering medium 8, the aperture stop 7 filters out the first-order diffracted light; after passing through the scattering medium 8, the laser light is received by the second microscope objective 11, and then by the camera 12. The camera 12 extracts the intensity information of the speckle as a feedback signal, which is received by the computer 13. The camera 12 measures the intensity and uniformity of the laser focus after passing through the scattering medium 10; the parameter settings in the NSGA2-R algorithm are: population size N = 50, iteration number n = 600, number of focal points M = 8, and the initial mutation rate R0 in the dynamic mutation rate R = 0.01, and the final mutation rate R = R end The value is 0.002, the attenuation factor D is 250, and the phase mask resolution is 1080×1080 pixels.
[0051] The curves showing the changes in focal intensity enhancement and uniformity coefficient with the number of iterations are as follows: Figure 5 As shown, Figure 5 (a) shows the focal intensity enhancement curve under the NSGA2-R algorithm. Figure 5 (b) shows the focal intensity uniformity coefficient under the NSGA2-R algorithm; as the iteration progresses, the focal intensity enhancement increases, while the focal intensity uniformity coefficient remains at 100; after 300 iterations, the focal intensity enhancement reaches 551, at which point the focal intensity uniformity coefficient decreases; after the iteration optimization is completed, the focal enhancement reaches a maximum value of 583, while the uniformity coefficient is only 1.5. These images were all obtained by computer 13.
[0052] In summary, after iterative optimization, the focal point can maintain high intensity enhancement and uniformity.
Claims
1. An optical multi-point focusing method based on the NSGA2-R algorithm, characterized in that: The laser emitted from the laser source (1) is conjugated to the spatial light modulator (5). The spatial light modulator (5) modulates the laser irradiated onto it and then conjugates it to the rear plane of the first microscope objective (9). The first microscope objective (9) focuses the laser onto the front surface of the scattering medium (10). The laser passing through the scattering medium (10) is received by the second microscope objective (11). After passing through the second microscope objective (11), the laser is received by the camera (12). The computer (13) connected to the camera (12) and the spatial light modulator (5) generates a wavefront phase mask using the NSGA2-R algorithm. The spatial light modulator (5) modulates the laser using the wavefront phase mask, and the camera (12) obtains the optimal laser focus intensity and uniformity for multi-point laser focusing. The computer (13) connected to the camera (12) and the spatial light modulator (5) generates a wavefront phase mask using the NSGA2-R algorithm. The spatial light modulator (5) modulates the laser using the wavefront phase mask, including the following: Step 1: Initially, the computer (13) generates a set of random wavefront phase masks as the initial population of the NSGA2-R algorithm. Each wavefront phase mask represents a wavefront modulation scheme. Each wavefront phase mask generates a set number of focal points on the camera (12). The set number is greater than or equal to 3. The camera (12) feeds back the number of focal points and the intensity of the received laser to the computer (13). Step 2: The NSGA2-R algorithm establishes the focus enhancement function f1 and the uniformity coefficient function f2 between the focal points, evaluates the performance of the wavefront phase mask, and inputs the number and intensity of focal points fed back by the camera (12) into the focus enhancement function f1 and the uniformity coefficient function f2 between the focal points. The larger the value of the focus enhancement function f1, the better the performance of the wavefront phase mask; the smaller the value of the uniformity coefficient function f2, the better the performance of the wavefront phase mask. The focus enhancement function f1 of the focal point is... Where M is the total number of focal points, I avg Let I be the average intensity of the M focal points. m Let be the intensity of the m-th focal point; The uniformity coefficient function f2 between the focal points is Where, σ m The standard deviation of the focal intensity; Step 3: The NSGA2-R algorithm performs non-dominated sorting and crowding distance calculation on the population based on the performance evaluation results of the wavefront phase mask, and selects excellent wavefront phase masks. Specifically, a rectangular coordinate system is established with the focal enhancement function f1 value of the focal point as the x-axis and the uniformity coefficient function f2 value between focal points as the y-axis, with the origin being that both the focal enhancement function f1 value and the uniformity coefficient function f2 value between focal points are 0. The distance between the coordinate points corresponding to the uniformity coefficient function f2 value between focal points of the wavefront phase mask and the coordinate points corresponding to the uniformity coefficient function f2 value between focal points is used as the crowding distance. Excellent wavefront phase masks are selected based on the performance of the wavefront phase mask and the crowding distance. Step 4: The NSGA2-R algorithm performs a crossover operation on the selected wavefront phase masks, mapping a phase wavefront mask to a chromosome in the NSGA2-R algorithm. The phase of a single pixel on the SLM corresponds to the gene of the chromosome. The number of pixels and the number of genes are made consistent. Half of the gene count of any two chromosomes are crossed. A multi-point crossover method is adopted. At the same time, a dynamic mutation rate R is introduced. The mutation rate is dynamically adjusted according to the number of iterations, thereby dynamically changing the phase of the wavefront phase mask to balance the global search capability and the local optimization capability. A new population is generated to obtain a new set of wavefront phase masks. The new wavefront phase masks are loaded onto the spatial light modulator (5) to modulate the laser. The camera (12) feeds back the number of focal points and the focal intensity of the received laser to the computer (13). Step 5: Repeat steps 2 to 4, each repetition constituting one iteration. Continue this process until the preset number of iterations is reached, or the focal intensity and uniformity no longer significantly improve, thus obtaining the optimal wavefront phase mask. The statement that the focal intensity no longer significantly improves means that the absolute value of the difference between the uniformity coefficient function f2 between the focal points before and after the iteration is less than the set value of the focal intensity. The statement that the uniformity no longer significantly improves means that the value of the uniformity coefficient function f2 between the focal points before and after the iteration is less than the set value of the uniformity.
2. The optical multi-point focusing method based on the NSGA2-R algorithm according to claim 1, characterized in that: The laser emitted by the laser source (1) being conjugated to the spatial light modulator (5) means that after the laser emitted by the laser source (1) passes through the half-wave plate (2), it is conjugated to the spatial light modulator (5) in free space through the conjugation system composed of the first lens (3) and the second lens (4); the conjugation to the rear plane of the first microscope objective (9) means that the laser modulated by the spatial light modulator (5) passes through the third lens (6), the aperture stop (7), and the fourth lens (8) in sequence, and is conjugated to the rear plane of the first microscope objective (9).
3. The optical multi-point focusing method based on the NSGA2-R algorithm according to claim 1, characterized in that: The formula for calculating the dynamic mutation rate R is as follows: R (n) =R0×(R end / R0) n / D Where R0 is the initial mutation rate, R end denoted as the final mutation rate, D as the decay factor, and n as the number of iterations.
4. The optical multi-point focusing method based on the NSGA2-R algorithm according to claim 1, characterized in that: The multi-point crossover method maintains the basic structure of the wavefront phase mask unchanged during the crossover process, and only crossover combinations are performed on local regions of the wavefront phase mask.
Citation Information
Patent Citations
Device for carrying out laser anti-vibration focusing by utilizing strong scattering medium and use method
CN116068784A
Controllable sparse illumination method through scattering medium
CN119002099A