pytorch/torch/_refs
Yidi Wu 9ec9f4740c [export] fix stft decomp and making it consistent with cpp impl. (#149232)
Summary: We change the fake impl of stft to follow more closely with its cpp implementation [here](https://github.com/pytorch/pytorch/blob/main/aten/src/ATen/native/SpectralOps.cpp#L951-L963)

where  " n_frames = 1 + (len - n_fft) / hop_length;" is also an integer division.

Test Plan: Existing tests and buck2 build --flagfile fbcode//mode/dev fbcode//executorch/examples/models/fb/llama4:speech_transform.pte

Differential Revision: D71209142

edit: we kept the original path un-changed.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/149232
Approved by: https://github.com/jackzhxng
2025-03-19 18:40:35 +00:00
..
linalg PEP585: More UP006 fixes (#146392) 2025-02-20 06:18:13 +00:00
nn PEP585: More UP006 fixes (#146392) 2025-02-20 06:18:13 +00:00
special [Inductor][CPP] fix torch logit decomposition (#145576) 2025-01-27 19:37:51 +00:00
__init__.py [export] fix stft decomp and making it consistent with cpp impl. (#149232) 2025-03-19 18:40:35 +00:00
_conversions.py [BE][Easy][14/19] enforce style for empty lines in import segments in torch/_[a-c]*/ and torch/_[e-h]*/ and torch/_[j-z]*/ (#129765) 2024-07-31 10:42:50 +00:00
fft.py PEP585 update - torch/_C torch/_decomp torch/_lazy torch/_library torch/_numpy torch/_prims torch/_refs torch/_strobelight (#145102) 2025-01-18 20:47:12 +00:00