pytorch-complex
pytorch-complex copied to clipboard
Mistake in function of Hyperbolic Tangent of Complex Number aka cTanh
https://github.com/soumickmj/pytorch-complex/blob/f5d0c3511a3f3c7cb7f138ee7f42a699d3f8209a/torchcomplex/nn/functional.py#L334
Hi there,
firstly thanks for your contribution in complex-valued cnn, but it seems that tanh function regarding complex number was defined wrong in your code, it should be
imag = torch.sin(2 * b) / denominator
Best