Update modeling_super_linear.py
Browse files- modeling_super_linear.py +1 -1
modeling_super_linear.py
CHANGED
|
@@ -599,7 +599,7 @@ class SuperLinearForCausalLM(PreTrainedModel, GenerationMixin):
|
|
| 599 |
|
| 600 |
def fourier_downsample_dim1(self,x, target_len: int):
|
| 601 |
|
| 602 |
-
|
| 603 |
# 1. Forward real FFT along dim-1
|
| 604 |
X = torch.fft.rfft(x, dim=1) # shape (..., L//2 + 1, ...)
|
| 605 |
|
|
|
|
| 599 |
|
| 600 |
def fourier_downsample_dim1(self,x, target_len: int):
|
| 601 |
|
| 602 |
+
L = x.size(1)
|
| 603 |
# 1. Forward real FFT along dim-1
|
| 604 |
X = torch.fft.rfft(x, dim=1) # shape (..., L//2 + 1, ...)
|
| 605 |
|