torch.nn.functional.glu
-
torch.nn.functional.glu(input, dim=- 1) → Tensor[source] -
Функция «gated linear unit». Вычисляет:
где
inputделится пополам вдольdimдля формированияaиb, — функция сигмоиды, а — поэлементное произведение матриц.
© 2024, PyTorch Contributors
PyTorch has a BSD-style license, as found in the LICENSE file.
https://pytorch.org/docs/1.13/generated/torch.nn.functional.glu.html