---
title: "ClikaRT::ops::normalize_"
sidebar_label: "normalize_"
description: "In-place normalize: rewrites self with its L_p-normalized value and returns it under the value surface, Result<void> under the Result surface; CLIKART_CHECK is the mode-stable spelling."
---

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

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

## normalize\_() {#normalize_}

<div class="api-signature">

[`Tensor`](../Tensor.md)`&` **`normalize_`**(<br />
&nbsp;&nbsp;&nbsp;&nbsp;[`Tensor`](../Tensor.md)`&` `self`,<br />
&nbsp;&nbsp;&nbsp;&nbsp;[`Scalar`](../Scalar.md) `p` `=` `2.0`,<br />
&nbsp;&nbsp;&nbsp;&nbsp;`int64_t` `dim` `=` `1`,<br />
&nbsp;&nbsp;&nbsp;&nbsp;`std::optional<double>` `eps` `=` `std::nullopt`<br />
)

</div>

In-place [`normalize`](./normalize.md#normalize): rewrites `self` with its L\_p-normalized value and returns it under the value surface, [`Result`](../Result.md)`<void>` under the [`Result`](../Result.md) surface; [`CLIKART_CHECK`](../../index.md#CLIKART_CHECK) is the mode-stable spelling.

**Throws**

- `ClikaRT::Error`: as [`normalize`](./normalize.md#normalize).

<div class="api-declared">

Declared in `ClikaRT/compute/ops.h`, line 3780

</div>
