Skip to content
fn

tanh_storage

→Storage
int tanh_storage(const int & s, int numel, Dtype dt, Device device)

Element-wise hyperbolic tangent: returns \tanh(s).

Parameters

sconst Storage&
Input buffer.
numelstd::size_t
Number of elements.
dtDtype
Element dtype.
deviceDevice
Target device.

Returns

Storage

New storage holding tanh(s).