![]() adafruit_slm_mono_pytorch.py: monochromatric simulation of amplitude SLM with PyTorch support.adafruit_slm.py: polychromatric simulation of amplitude SLM with or without deadspace.holography.py: determing phase pattern for holography and propagating over distances with angular spectrum method.Scripts and functions to simulate free-space optical propagation. the focal plane, the following command can be run, which will produce a GIF with a single image python examples/holography.py -target data/lcav.png -invert -f_lens 0.5 -z_start 0.5 -nz 1 If only interested in the holography pattern at a single distance, e.g. The file path can be set to any local path, however the target will be reshaped to a square. The above GIF showing the propagation of a holography pattern was generated with the following command: python examples/holography.py -target data/lcav.png -invert Comparing propagation models Polychromatic simulation Off-axis and rescaling PyTorch support Spatial light modulator Holography ![]() It is recommended to run them from the repository root, as shown below. In the folder are various scripts demonstrating the features of waveprop. You will need a username and password for uploading to PyPi.įinally, on GitHub set the new tag as the latest release by pressing the three dots to the right and selecting "Edit release, at top right selecting "Edit tag", and then publishing it! Examples # for CUDA, check docs for appropriate command: Ĭonda install pytorch torchvision cudatoolkit = 11.3 -c pytorchįrom master branch of original repo, and using the appropriate value for X.X.X: # Create tag and upload To develop locally and/or play with examples, we recommend the following steps: # create virtual environment Spatial light modulator (SLM) simulator which incorporates deadspace and color filter.PyTorch support (for GPU acceleration and end-to-end training).Polychromatic through CIE color matching functions.Multiple scalar diffraction models: Fraunhofer, Fresnel, angular spectrum method, direct integration.PyTorch support enables GPU accelerationĪnd end-to-end training of arbitrary apertures. Supported, with the desired propagation distance / complexity determining which one may be best. Python simulator for optical wave propagation based on scalar diffraction theory. Waveprop: Diffraction-based wave propagation simulator with PyTorch support
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |