Shortcuts

Struct LeakyReLUOptions

Page Contents

Struct Documentation

struct torch::nn::LeakyReLUOptions

Options for the LeakyReLU module.

Example:

LeakyReLU model(LeakyReLUOptions().negative_slope(0.42).inplace(true));

Public Functions

auto negative_slope(const double &new_negative_slope) -> decltype(*this)

Controls the angle of the negative slope. Default: 1e-2.

auto negative_slope(double &&new_negative_slope) -> decltype(*this)
const double &negative_slope() const noexcept
double &negative_slope() noexcept
auto inplace(const bool &new_inplace) -> decltype(*this)

can optionally do the operation in-place. Default: False

auto inplace(bool &&new_inplace) -> decltype(*this)
const bool &inplace() const noexcept
bool &inplace() noexcept

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources