Skip to content

Commit

Permalink
complex-curvture
Browse files Browse the repository at this point in the history
  • Loading branch information
FattanePourakpour committed Nov 1, 2024
1 parent 497c20a commit 7d27310
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion histomicstk/features/compute_fsd_features.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,8 @@ def _FSDs(X, Y, K, Intervals):
# make curvature cumulative
Curvature = Curvature - Curvature[0]
# calculate FFT
fX = np.fft.fft(Curvature).T
z = 1 * np.cos(Curvature) + 1j * np.sin(Curvature)
fX = np.fft.fft(z).T
# spectral energy
fX = fX * fX.conj()
fX = (fX / fX.sum()) if fX.sum() else fX
Expand Down

0 comments on commit 7d27310

Please sign in to comment.