Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MuReNNDirect: Conv1D should be before abs2 #37

Closed
lostanlen opened this issue Apr 2, 2024 · 1 comment
Closed

MuReNNDirect: Conv1D should be before abs2 #37

lostanlen opened this issue Apr 2, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@lostanlen
Copy link
Contributor

compare with waspaa paper

    def forward(self, x):
        x = x.reshape(x.shape[0], 1, x.shape[-1])
        _, x_levels = self.tfm.forward(x)
        Ux = []
        
        for j_psi in range(1+self.J_psi):
            x_level = x_levels[j_psi].type(torch.complex64) / (2**j_psi)
            Wx_real = self.psis[j_psi](x_level.real)
            Wx_imag = self.psis[j_psi](x_level.imag)
            Ux_j = Wx_real * Wx_real + Wx_imag * Wx_imag
            Ux_j = torch.real(Ux_j)
            if j_psi == 0:
                N_j = Ux_j.shape[-1]
            else:
                Ux_j = Ux_j[:, :, :N_j]
            Ux.append(Ux_j)

        Ux = torch.cat(Ux, axis=1)

https://github.com/lostanlen/lostanlen2023waspaa/blob/main/student.py

@lostanlen lostanlen added the bug Something isn't working label Apr 2, 2024
@lostanlen lostanlen changed the title MuReNNDirect: Conv1D before abs2 MuReNNDirect: Conv1D should be before abs2 Apr 2, 2024
@lostanlen
Copy link
Contributor Author

fixed by #38

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant