# US 2025/0378337 A1 · Device and method for training a variational autoencoder

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2025/0378337 A1
- Document ID: US20250378337A1
- Status: Published application
- Kind: A1
- Application number: 19/231,620
- Filed: 2025-06-09
- Published: 2025-12-11
- Earliest claimed: 2024-06-11
- Applicants: Robert Bosch GmbH
- Inventors: Maxim Dolgov; Faris Janjos; Lars Rosenbaum
- Web page: https://patentgrep.com/patent/US20250378337A1

## CPC

- G06F 16/906: Clustering; Classification
- G06N 3/084: Backpropagation, e.g. using gradient descent
- G06N 3/00: Computing arrangements based on biological models
- G06N 3/045: Combinations of networks
- G06N 3/0455: Auto-encoder networks; Encoder-decoder networks
- G06N 3/047: Probabilistic or stochastic networks
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

Computer-implemented method for training a machine learning system. The machine learning system is configured to accept a sensor signal as input for anomaly detection and/or for sampling a trajectory of a traffic participant and/or for sampling of sensor signals and/or for determining a value characterizing a likelihood of a sensor signal with respect to a training dataset. The training includes: determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution; determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution; determining an output signal.

## Claims

### Claim 1

A computer-implemented method for training a machine learning system, wherein the machine learning system is configured to accept a sensor signal as input for anomaly detection and/or the machine learning system is configured for sampling a trajectory of a traffic participant, and/or the machine learning system is configured for sampling of sensor signals and/or the machine learning system is configured for determining a value characterizing a likelihood of a sensor signal with respect to a training dataset, wherein training comprises the following steps:
determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution;
determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution;
determining an output signal, wherein the output signal is determined by providing a randomly sampled sigma point of the plurality of sigma points to a decoder of the machine learning system;
adapting the machine learning system based on a loss value, wherein the loss value is obtained from a loss function that includes a term that characterizes a difference between the training sensor signal and the output signal;
wherein: (i) the loss function includes a further term characterizing a difference of the output signal and a value sampled at random from a Normal distribution, or (ii) the term characterizes a likelihood of the output signal with respect to the Normal distribution;
wherein further a mean of the Normal distribution is obtained by forward propagating the first intermediate representation through the decoder; and
wherein a covariance matrix is determined by multiplying a Jacobian of the mean of the Normal distribution with the second representation and multiplying the result with a transpose of the Jacobian.

### Claim 2 (depends on 1)

The method according to claim 1, wherein each sigma point in the plurality of sigma points is a mean-centered symmetric point.

### Claim 3 (depends on 2)

The method according to claim 2, wherein the mean is characterized by the first intermediate representation.

### Claim 4 (depends on 2)

The method according to claim 2, wherein the plurality of sigma points is determined according to the following formulae:
χ
0
=
μ
,
χ
i
=
μ
+
(
κ
+
n
)
∑
,
χ
i
+
n
=
μ
-
(
κ
+
n
)
∑
,
wherein K>−n is a predefined real constant, n is a dimensionality of the latent space, μ is the first representation and Σ is the second representation.

### Claim 5 (depends on 1)

The method according to claim 1, wherein the second intermediate representation characterizes a full covariant matrix of the latent distribution.

### Claim 6 (depends on 1)

The method according to claim 1, wherein the loss function is characterized by the following formulae:
ℒ
UAE
=
E
x
i
∼
p
data
[
ℒ
REC
+
β
·
ℒ
KL
]
+
ℒ
ext
,
ℒ
REC
=

x
i
-
D
⁡
(
z
)

2
2
,
z
∼
{
χ
i
(
μ
,
∑
)
}
i
=
0
2
⁢
n
,
ℒ
KL
=

μ

2
2
+
tr
⁡
(
∑
)
-
n
-
log
⁢
det
∑
,
ℒ
ext
=
E
x
^
∼
N
⁡
(
μ
^
,
∑
^
)
[
x
i
-
x
^
]
⁢
or
⁢
ℒ
ext
=
log
(
N
⁡
(
x
i
❘
μ
^
,
∑
^
)
,
μ
^
=
D
⁡
(
μ
)
,
∑
^
=
(
∇
μ
D
⁡
(
μ
)
)
⁢
∑
(
∇
μ
D
⁡
(
μ
)
)
T
wherein xi is the training sensor signal, pdata is an empirical distribution, D is the decoder of the machine learning system, Z is a randomly sampled sigma point of the plurality of sigma points
{
χ
i
(
μ
,
∑
)
}
i
=
0
2
⁢
n
,
μ is the first representation, Σ is the second representation, {circumflex over (μ)} is the mean of the Normal distribution, and {circumflex over (Σ)} is the covariance matrix of the Normal distribution.

### Claim 7 (depends on 6)

The method according to claim 6, wherein the loss function further includes a regularization term characterized by the formula:
ℒ
REG
=
λ
max
(
∑
)
⁢

∇
z
D
⁡
(
z
)

2
2
,
wherein λmax is a largest eigen value of Σ and ∇zD(z) is a gradient of the loss function with respect to z.

### Claim 8

A computer-implemented method for determining, whether a sensor signal is anomalous or normal, the method comprising the following steps:
obtaining a machine learning system that is configured for anomaly detection and that has been trained by:
determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution,
determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution,
determining an output signal, wherein the output signal is determined by providing a randomly sampled sigma point of the plurality of sigma points to a decoder of the machine learning system,
adapting the machine learning system based on a loss value, wherein the loss value is obtained from a loss function that includes a term that characterizes a difference between the training sensor signal and the output signal,
wherein: (i) the loss function includes a further term characterizing a difference of the output signal and a value sampled at random from a Normal distribution, or (ii) the term characterizes a likelihood of the output signal with respect to the Normal distribution,
wherein further a mean of the Normal distribution is obtained by forward propagating the first intermediate representation through the decoder, and
wherein a covariance matrix is determined by multiplying a Jacobian of the mean of the Normal distribution with the second representation and multiplying the result with a transpose of the Jacobian;
providing the sensor signal to the encoder of the machine learning system to determine a first intermediate representation;
determining an output signal by providing the first intermediate representation as input to the decoder of the machine learning system;
determining the sensor signal as anomalous when a difference between the output signal and the sensor signal exceeds a predefined threshold, and otherwise determine the sensor signal as normal.

### Claim 9

A computer-implemented method for sampling a trajectory of a traffic participant and/or a sampling sensor signal comprising the following steps:
obtaining a machine learning that is configured for trajectory sampling and/or sampling a sensor signal, and the machine learning system has been trained by:
determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution,
determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution,
determining an output signal, wherein the output signal is determined by providing a randomly sampled sigma point of the plurality of sigma points to a decoder of the machine learning system,
adapting the machine learning system based on a loss value, wherein the loss value is obtained from a loss function that includes a term that characterizes a difference between the training sensor signal and the output signal,
wherein: (i) the loss function includes a further term characterizing a difference of the output signal and a value sampled at random from a Normal distribution, or (ii) the term characterizes a likelihood of the output signal with respect to the Normal distribution,
wherein further a mean of the Normal distribution is obtained by forward propagating the first intermediate representation through the decoder, and
wherein a covariance matrix is determined by multiplying a Jacobian of the mean of the Normal distribution with the second representation and multiplying the result with a transpose of the Jacobian;
randomly drawing a value from the latent space characterized by the machine learning system; and
determining an output signal characterizing a trajectory and/or a sampled sensor signal by providing the randomly drawn value to the decoder of the machine learning system.

### Claim 10

A training system which is configured to carry out a training method for training a machine learning system, wherein the machine learning system is configured to accept a sensor signal as input for anomaly detection and/or the machine learning system is configured for sampling a trajectory of a traffic participant, and/or the machine learning system is configured for sampling of sensor signals and/or the machine learning system is configured for determining a value characterizing a likelihood of a sensor signal with respect to a training dataset, the training method comprising the following steps:
determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution;
determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution;
determining an output signal, wherein the output signal is determined by providing a randomly sampled sigma point of the plurality of sigma points to a decoder of the machine learning system;
adapting the machine learning system based on a loss value, wherein the loss value is obtained from a loss function that includes a term that characterizes a difference between the training sensor signal and the output signal;
wherein: (i) the loss function includes a further term characterizing a difference of the output signal and a value sampled at random from a Normal distribution, or (ii) the term characterizes a likelihood of the output signal with respect to the Normal distribution;
wherein further a mean of the Normal distribution is obtained by forward propagating the first intermediate representation through the decoder; and
wherein a covariance matrix is determined by multiplying a Jacobian of the mean of the Normal distribution with the second representation and multiplying the result with a transpose of the Jacobian.

### Claim 11

A control system configured to determine, whether a sensor signal is anomalous or normal, the control system being configured to:
obtain a machine learning system that is configured for anomaly detection and that has been trained by:
determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution,
determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution,
determining an output signal, wherein the output signal is determined by providing a randomly sampled sigma point of the plurality of sigma points to a decoder of the machine learning system,
adapting the machine learning system based on a loss value, wherein the loss value is obtained from a loss function that includes a term that characterizes a difference between the training sensor signal and the output signal,
wherein: (i) the loss function includes a further term characterizing a difference of the output signal and a value sampled at random from a Normal distribution, or (ii) the term characterizes a likelihood of the output signal with respect to the Normal distribution,
wherein further a mean of the Normal distribution is obtained by forward propagating the first intermediate representation through the decoder, and
wherein a covariance matrix is determined by multiplying a Jacobian of the mean of the Normal distribution with the second representation and multiplying the result with a transpose of the Jacobian;
provide the sensor signal to the encoder of the machine learning system to determine a first intermediate representation;
determine an output signal by providing the first intermediate representation as input to the decoder of the machine learning system;
determine the sensor signal as anomalous when a difference between the output signal and the sensor signal exceeds a predefined threshold, and otherwise determine the sensor signal as normal,
wherein the control system determines a control signal based the output signal, wherein the control signal is configured to control an actuator and/or a display.

### Claim 12

A non-transitory machine-readable storage medium on which is stored a computer program for training a machine learning system, wherein the machine learning system is configured to accept a sensor signal as input for anomaly detection and/or the machine learning system is configured for sampling a trajectory of a traffic participant, and/or the machine learning system is configured for sampling of sensor signals and/or the machine learning system is configured for determining a value characterizing a likelihood of a sensor signal with respect to a training dataset, wherein computer program, when executed by one or more processors, causing the one or more processors to perform the following steps:
determining, by an encoder of the machine learning system and based on a training sensor signal, a first intermediate representation characterizing a mean of a latent distribution of a latent space and a second intermediate representation characterizing a variance and/or covariance of the latent distribution;
determining, based on the first intermediate representation and the second intermediate representation, a plurality of sigma points with respect to the latent distribution;
determining an output signal, wherein the output signal is determined by providing a randomly sampled sigma point of the plurality of sigma points to a decoder of the machine learning system;
adapting the machine learning system based on a loss value, wherein the loss value is obtained from a loss function that includes a term that characterizes a difference between the training sensor signal and the output signal;
wherein: (i) the loss function includes a further term characterizing a difference of the output signal and a value sampled at random from a Normal distribution, or (ii) the term characterizes a likelihood of the output signal with respect to the Normal distribution;
wherein further a mean of the Normal distribution is obtained by forward propagating the first intermediate representation through the decoder; and
wherein a covariance matrix is determined by multiplying a Jacobian of the mean of the Normal distribution with the second representation and multiplying the result with a transpose of the Jacobian.
