Shortcuts

Struct SoftshrinkOptions

Page Contents

Struct Documentation

struct torch::nn::SoftshrinkOptions

Options for the Softshrink module.

Example:

Softshrink model(SoftshrinkOptions(42.42));

Public Functions

SoftshrinkOptions(double lambda = 0.5)
auto lambda(const double &new_lambda) -> decltype(*this)

the lambda value for the Softshrink formulation. Default: 0.5

auto lambda(double &&new_lambda) -> decltype(*this)
const double &lambda() const noexcept
double &lambda() 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