/Computer-Generated-Hologram

🎞数字全息术与计算机生成全息的计算与仿真框架【This library introduces the current production process of computer holography, and uses MATLAB and Python to record and reproduce holograms. In the future, I will build a computer hologram simulation framework or a simulation application program.】

Primary LanguagePython

Computer-Generated-Hologram

✨This library introduces the current production process of computer holography, and uses MATLAB and Python to record and reproduce holograms. In the future, I will build a computer hologram simulation framework or a simulation application program.

Introduction

CGH stands for computer-generated holograms (CGH). Holograms are unique in their ability to record both the intensity and phase of information.

More Resource to learn holography 👉 Awesome Holography👈

Summary of CGH Tips: Tips

Types of CGH

  • Point-based methods
  • Polygon-based methods
  • Layer-based methods
  • Ray-tracing
  • Geometric primitives & basis functions
  • Holographic Stereograms

Phase Optimization Methods

Overview

  • Iterative Method
    • GS,GSW,Fienup,AA
    • Error Diffusion Method
  • Non-Iterative Method
    • Random Phase
    • Sample Method
      • Sampled-Phase-only Hologram
      • Complementary phase-only hologram
      • Adaptive Down-Sampling Mask
    • Patterned Phase-Only Hologram and Quadratic Phase
    • Double-Phase Method
    • Non-Random Phase-Free Method
  • Direct Computation
    • Direct Search Algorithm
    • Simulated Annealing Algorithm
    • Genetic Algorithm
  • Combination of iteration and non-iteration
  • Wirtinger Flow
  • Deep Learning

Iterative Method

The iterative algorithm usually starts from an approximation of the target hologram, and continuously optimizes the approximate hologram through a series of repeated operations until the reconstructed image obtained by the approximation meets certain error requirements.

GS-Base Algorithm

According to the amplitude distribution of the hologram plane and the reconstructed image plane, the phase information of the light field in the hologram plane can be obtained by iterating the forward and reverse light wave transmission and the restrictions imposed on the two planes.

Algorithm Paper Link
GS(Gerchberg-Saxton) Algorithm 👉Paper Code
Fienup Algorithm 👉Paper Code
Error Diffusion Method

The error diffusion algorithm iterates between the pixels of the hologram plane in turn, rather than between the hologram plane and the object image plane,Without any information of the object image, only the complex amplitude hologram itself can be directly operated on it and a pure phase hologram can be calculated.

Algorithm Paper Link
Error Diffusion Algorithm 👉Paper Code

Complex Amplitude Modulation

  • Double-Phase hologram (DPH):Code | Paper
  • Hologram bleaching
  • Double-constraint iterative method

Propagation Field

Fresnel diffraction method

  • Based on single Fourier transform and Convolution calculation.
  • Fresnel diffraction propagator is implemented Here.

Angular spectrum method

  • Angular spectrum propagator is implemented Here.

CGH Examples

CGH Type Document Link
Circuitous Phase Type Hologram/Fourier Hologram 👉Doc Code
Kinoform【POH】 👉Doc Code
Fresnel Hologram【AOH】 👉Doc Code
Off Axis Interference Hologram【AOH】 👉Doc Code
Layer_Based Hologram【POH】 👉Doc Code

Usage

Working on a hologram simulation API.

git clone https://github.com/JackHCC/Computer-Generated-Hologram.git
cd Computer-Generated-Hologram
pip install requirements.txt

Experiment

Go 👉Here👈 to try generating CGH!

You can get some awesome holograms and images!

Contact

If you have any questions or good ideas, please contact: jackcc0701@163.com

References

  • Hao-zhen BU, Shu-ming JIAO. Review of computer-generated phase-only hologram optimization algorithm[J]. Chinese Journal of Liquid Crystals and Displays, 2021, 36(6):810-826. DOI: 10.37188/CJLCD.2021-0035.
  • Pi, D., Liu, J. & Wang, Y. Review of computer-generated hologram algorithms for color dynamic holographic three-dimensional display. Light Sci Appl 11, 231 (2022).
  • David Blinder, Tobias Birnbaum, Tomoyoshi Ito, Tomoyoshi Shimobaba. The state-of-the-art in computer generated holography for 3D display[J]. Light: Advanced Manufacturing 3, 35(2022).