8000 Fix docstring for torch.signal.windows.nuttall (#134704) · pytorch/pytorch@79c8867 · GitHub
[go: up one dir, main page]

Skip to content

Commit 79c8867

Browse files
pytorchbotmalfet
andauthored
Fix docstring for torch.signal.windows.nuttall (#134704)
Fix docstring for torch.signal.windows.nuttall (#134512) This partially fixes regression introduced by #124771 but also just improves `z_n` rendering, by using MathML In 2.3 it was [rendered](https://pytorch.org/docs/2.3/generated/torch.signal.windows.nuttall.html#torch.signal.windows.nuttall) as <img width="177" alt="image" src="https://github.com/user-attachments/assets/2c15d1f9-13ad-483f-bb66-41fa3fa4ba9c"> With this change it'll be [rendered](https://docs-preview.pytorch.org/pytorch/pytorch/134512/generated/torch.signal.windows.nuttall.html#torch.signal.windows.nuttall) as ```math z_n = \frac{2 \pi n}{M} ``` Pull Request resolved: #134512 Approved by: https://github.com/kit1980, https://github.com/aorenste, https://github.com/atalman (cherry picked from commit 79b7fff) Co-authored-by: Nikita Shulga <2453524+malfet@users.noreply.github.com>
1 parent 38b96d3 commit 79c8867

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

torch/signal/windows/windows.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -749,7 +749,7 @@ def general_hamming(M,
749749
.. math::
750750
w_n = 1 - 0.36358 \cos{(z_n)} + 0.48917 \cos{(2z_n)} - 0.13659 \cos{(3z_n)} + 0.01064 \cos{(4z_n)}
751751
752-
where ``z_n = 2 \u03c0 n/ M``.
752+
where :math:`z_n = \frac{2 \pi n}{M}`.
753753
""",
754754
"""
755755

0 commit comments

Comments
 (0)
0