Skip to content
fn

pow_storage

→Storage
int pow_storage(const int & base, const int & expo, int numel, Dtype dt, Device device)

Element-wise power: returns base ** expo.

Parameters

base, expoconst Storage&
Base and exponent buffers. Both must have numel elements.
numelstd::size_t
Number of elements.
dtDtype
Element dtype.
deviceDevice
Target device.

Returns

Storage

New storage holding \text{base}^{\text{expo}}.