mirror of
https://github.com/cdtools-developers/cdtools.git
synced 2026-10-26 18:01:36 +01:00
Merge branch 'fix_oversampling_pix_size' into savenload
This commit is contained in:
commit
30da2ceeda
1 file changed
+2
-1
@@ -404,6 +404,7 @@ class FancyPtycho(CDIModel):
|
||||
dataset.patterns.shape[-2:], dtype=t.float32)
|
||||
|
||||
if probe_fourier_crop is not None:
|
||||
initial_probe_shape = np.array(probe.shape)
|
||||
probe = tools.propagators.far_field(probe)
|
||||
probe = probe[probe_fourier_crop : probe.shape[-2]
|
||||
- probe_fourier_crop,
|
||||
@@ -411,7 +412,7 @@ class FancyPtycho(CDIModel):
|
||||
- probe_fourier_crop]
|
||||
probe = tools.propagators.inverse_far_field(probe)
|
||||
|
||||
scale_factor = np.array(det_shape) / np.array(probe.shape)
|
||||
scale_factor = initial_probe_shape / np.array(probe.shape)
|
||||
probe_basis = obj_basis * scale_factor[None,:]
|
||||
else:
|
||||
probe_basis = obj_basis.clone()
|
||||
|
||||
Reference in new issue
Block a user