Skip to main content

ClikaRT::nn::BCEWithLogitsLoss

class

Header: ClikaRT/nn/generated/loss.h
Inherits: ClikaRT::nn::Module

Binary cross entropy over logits: the sigmoid fused with the loss in one stable pass. The module form of ClikaRT::ops::binary_cross_entropy_with_logits, which documents the full contract (shapes, dtypes, errors); construct once, then call it like a function.

Member functions​

BCEWithLogitsLoss()​

explicit BCEWithLogitsLoss(BCEWithLogitsLossOptions options = {})

Constructs the module from options (every default when omitted).

Declared in ClikaRT/nn/generated/loss.h, line 538

forward()​

Tensor forward(Tensor input, Tensor target) const

forward_impl, unwrapped: raises ClikaRT::Error on failure.

Declared in ClikaRT/nn/generated/loss.h, line 555

operator()()​

Tensor operator()(Tensor input, Tensor target) const

Same as forward.

Declared in ClikaRT/nn/generated/loss.h, line 559

options()​

const BCEWithLogitsLossOptions& options() const

The settings this module was constructed with.

Declared in ClikaRT/nn/generated/loss.h, line 563