Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implementations of the Scalable Angular Spectrum Method

License

NotificationsYou must be signed in to change notification settings

bionanoimaging/Scalable-Angular-Spectrum-Method-SAS

Repository files navigation

Implementations of the Scalable Angular Spectrum (SAS) method for optical wave propagation in Python + PyTorch and Julia Lang.The SAS allows to propagate optical waves accurately over long distances and high magnifications.It features a much higher speed than the Angular Spectrum (AS) method and is more precise than the single-step Fresnel (SFT-Fr) method.It's implementation essentially consists of three FFTs and some phase factors.

This image compares the three methods for accuracy.

The calculation time for Fresnel was 0.04s, the one for SAS around 0.12s. But AS takes around 6s because of large padding!

Publication and Citation

For more details about the mathematics and physics behind this method, see thisOPTICA publication.Please consider citing this, if you find it useful:

@article{Heintzmann:23,author = {Rainer Heintzmann and Lars Loetgering and Felix Wechsler},journal = {Optica},keywords = {Fourier transforms; Inverse design; Phase retrieval; Spatial frequency; Synthetic aperture radar; Wave propagation},number = {11},pages = {1407--1416},publisher = {Optica Publishing Group},title = {Scalable angular spectrum propagation},volume = {10},month = {Nov},year = {2023},url = {https://opg.optica.org/optica/abstract.cfm?URI=optica-10-11-1407},doi = {10.1364/OPTICA.497809}}

License

Check the conditions of thelicense.

Julia Code

Tested withJulia 1.9. Download the software and install it on your computer.Open the REPL and type (type really a] to enter the package manager. Delete the] to go back to REPL):

julia> ]add Plutojulia>using Pluto

Pluto.jl is an interactive notebook environment.Download the fileSAS_examples.jl. From within Pluto, open this file.Everything should go fine from now on.

Reproducibility

Pluto notebooks are highly reproducible because of the pinned versions of all dependencies. So running this notebook with Julia 1.9.1 is reproducible. You do not have to handle the versions yourself. Everything is done by Pluto.jl.

Python

Implementation in Python andPyTorch. Hence, it can be used within neural networks and automatic differentiation.See thisJupyter notebook.Install

pip install numpy matplotlib torch notebook

to run the Python notebook.

Implementations

There is an efficient implementation of the Angular Spectrum method and the Scalable Angular Spectrum method inWaveOpticsPropagation.jl.There is one JAX implementation inchromatix.

Bugs, Issues

Please feel free to file issues and bugs here on GitHub! Also, if you have any question regarding the paper, post it here too!

About

Implementations of the Scalable Angular Spectrum Method

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp