Skip to content

Commit 61f4788

Browse files
committed
address rabbit review
1 parent 37c8e0f commit 61f4788

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

dascore/transform/fourier.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -403,8 +403,6 @@ def stft(
403403
If True, detrend each time window before performing fourier transform.
404404
This can lead to nicer looking spectrograms, but means the istft is
405405
no longer possible.
406-
psd
407-
If True, return the power spectral density (PSD).
408406
**kwargs
409407
Used to specify window length in data units, percent, or samples.
410408
@@ -517,7 +515,7 @@ def _get_istft_coord(coords, frequency_axis, time_axis):
517515
new_dims = list(dims)
518516
new_dims[frequency_axis] = dims[time_axis]
519517
new_dims.pop(time_axis)
520-
return get_coord_manager(coords=coord_map, dims=new_dims), time
518+
return get_coord_manager(coords=coord_map, dims=tuple(new_dims)), time
521519

522520

523521
def _get_short_time_fft(patch) -> ShortTimeFFT:
@@ -571,6 +569,7 @@ def istft(
571569
patch.data / dc.to_float(coord.step), t_axis=time_axis, f_axis=frequency_axis
572570
)
573571
# Trim data array to remove effect of padding.
572+
# Note: after ISTFT, `frequency_axis` now indexes the restored time axis.
574573
index = broadcast_for_index(
575574
data_untrimmed.ndim, frequency_axis, slice(0, len(coord))
576575
)

environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ channels:
44
dependencies:
55
- pytest
66
- numpy>=1.24
7-
- pydantic>2.1
7+
- pydantic>=2.1
88
- pip
99
- pandas>=2.0
1010
- pooch>=1.2

0 commit comments

Comments
 (0)