This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
]q (X external_idqX commandqX tsqe.K .}q (K }q(X __id__qK X external_idqX pythonqX tsqcdatetime | |
datetime | |
qC | |
qqRq X commandq | |
X testqX __version__qK uK}q (hKhhhhC | |
}qqRqh | |
X __version__qhK uK}q(hKhhhhC | |
9zqqRqh | |
X print(__version__)qhK uK}q(hKhhhhC | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import timeit | |
import numpy as np | |
from numpy.fft import fftshift, ifftshift, fft2 | |
x, y = np.linspace(-1, 1, 128), np.linspace(-1, 1, 128) | |
xx, yy = np.meshgrid(x, y) | |
rho, phi = np.sqrt(xx**2 + yy**2), np.arctan2(yy, xx) | |
phase_arr = rho ** 2 * np.sin(phi) | |
complex_arr = np.exp(1j * 2 * np.pi * phase_arr) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def matrix_dft(f, alpha, npix, shift=None, unitary=False): | |
if np.isscalar(alpha): | |
ax = ay = alpha | |
else: | |
ax = ay = np.asarray(alpha) | |
f = np.asarray(f) | |
m, n = f.shape | |
if np.isscalar(npix): |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
OlderNewer