Skip to content

Commit

Permalink
Fix wavelength parsing.
Browse files Browse the repository at this point in the history
* Add downsample option before Hugging Face upload.

* Remove prints.

* Add option to use waveprop in simulating PSF, improve ROI extraction API.

* Improve load_data interface.

* Add one-shot method for ADMM and GD.

* Refactor is_torch to use_torch.

* Add option to center mask.

* Height map as result for phase mask.

* Make normalize explicit.

* Fix top_left naming.

* Update CHANGELOG.

* Fix mask tests.

* Fix psf shape for torch array.
  • Loading branch information
ebezzam authored Aug 21, 2024
1 parent b439e08 commit 87beb5c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ Changed
Bugfix
~~~~~~

- Wavelength input to ``compute_psf`` for Mask class.
- Computation of average metric in batches.
- Support for grayscale PSF for RealFFTConvolve2D.
- Calling model.eval() before inference, and model.train() before training.
Expand Down
2 changes: 1 addition & 1 deletion lensless/hardware/mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ def compute_psf(self, distance_sensor=None, wavelength=None, intensity=True):

if self.use_torch:
psf = torch.zeros(
tuple(self.resolution) + (len(self.psf_wavelength),),
tuple(self.resolution) + (len(wavelength),),
dtype=torch.complex64,
device=self.torch_device,
)
Expand Down

0 comments on commit 87beb5c

Please sign in to comment.