---
title: "ClikaRT::nn::L1LossOptions"
sidebar_label: "L1LossOptions"
description: "Settings of L1Loss: chain the setters, or assign the fields."
---

<!-- Generated by tools/doxygen2mdx from Doxygen XML. Do not edit. -->

<span class="api-kind api-kind--struct">struct</span>

**Header:** `ClikaRT/nn/generated/loss.h`

Settings of [`L1Loss`](./L1Loss.md): chain the setters, or assign the fields.

## Member functions

### reduction(ops::Reduction) {#reduction}

<div class="api-signature">

[`L1LossOptions`](./L1LossOptions.md)`&` **`reduction`**([`ops::Reduction`](../ops/index.md#Reduction) `v`)

</div>

Sets [`reduction`](./L1LossOptions.md#reduction), how the elementwise losses reduce.

<div class="api-declared">

Declared in `ClikaRT/nn/generated/loss.h`, line 83

</div>

### reduction() {#reduction-2}

<div class="api-signature">

[`ops::Reduction`](../ops/index.md#Reduction) **`reduction`**() `const`

</div>

Reads [`reduction`](./L1LossOptions.md#reduction).

<div class="api-declared">

Declared in `ClikaRT/nn/generated/loss.h`, line 85

</div>

## Data members

### reduction\_ {#reduction_}

<div class="api-signature">

[`ops::Reduction`](../ops/index.md#Reduction) **`reduction_`** `=` [`ops::Reduction::Mean`](../ops/index.md#Reduction)

</div>

How the elementwise losses reduce. Default [`ops::Reduction::Mean`](../ops/index.md#Reduction).

<div class="api-declared">

Declared in `ClikaRT/nn/generated/loss.h`, line 87

</div>
