# US 2025/0165757 A1 · Approximation method of softmax function and neural network utilizing the same

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

- Number: US 2025/0165757 A1
- Document ID: US20250165757A1
- Status: Published application
- Kind: A1
- Application number: 18/518,178
- Filed: 2023-11-22
- Published: 2025-05-22
- Earliest claimed: 2023-11-22
- Assignees: Kneron (Taiwan) Co., Ltd.
- Applicants: Kneron (Taiwan) Co., Ltd.
- Inventors: Chi-Sheng WU
- Web page: https://patentgrep.com/patent/US20250165757A1

## CPC

- G06N 3/048: Activation functions
- G06N 3/045: Combinations of networks
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

An approximation method of softmax function which converts an input value of k-dimensional vector into an output value of m-dimensional vector, comprises: an exponential function approximation computing step performing a Leaky ReLU computation on one input value of k-dimensional vector to obtain a Leaky ReLU computation value and performing a polynomial function computation of a certain order based on the Leaky ReLU computation value to obtain an exponential approximation value, the exponential function approximation computing step repeated for another input value of k-dimensional vector to obtain another exponential approximation value; an addition computing step adding the exponential approximation values to obtain a sum value; and a division computing step dividing at least one of the exponential approximation values obtained in the exponential function approximation computing step by the sum value to obtain an output value of m-dimensional vector.

## Claims

### Claim 1

An approximation method of softmax function, converting one or more input values of a k-dimensional vector into one or more output values of an m-dimensional vector, comprising:
an exponential function approximation computing step performing a Leaky Rectified Linear Unit (Leaky ReLU) computation on one of the input values of the k-dimensional vector to obtain a Leaky ReLU computation value and performing a polynomial function computation of a certain order based on the Leaky ReLU computation value to obtain an exponential approximation value, wherein the exponential function approximation computing step is repeated for another one of the input values of the k-dimensional vector to obtain another exponential approximation value;
an addition computing step adding the exponential approximation value and the another exponential approximation value to obtain a sum value; and
a division computing step dividing at least one of the exponential approximation values obtained in the exponential function approximation computing step by the sum value to obtain one of the output values of the m-dimensional vector.

### Claim 2 (depends on 1)

The method of claim 1, wherein in the exponential function approximation computing step, a Clamp function computation is performed on the input value before the exponential function approximation computing step is performed.

### Claim 3 (depends on 2)

The method of claim 2, wherein in the addition computing step, the sum value is further added with a protection value to ensure that an absolute value of the sum value is greater than zero.

### Claim 4 (depends on 1)

The method of claim 1, wherein the polynomial function computation of a certain order is a polynomial function computation of second-order to fifth-order.

### Claim 5 (depends on 1)

The method of claim 1, wherein the exponential function approximation computing step is repeated until the Leaky Rectified Linear Unit (Leaky ReLU) computation is performed on each of the input values to obtain the corresponding Leaky ReLU computation value, and the polynomial function computation of a certain order is performed based on the corresponding Leaky ReLU computation value to obtain the corresponding exponential approximation value, the addition computing step adds up all the corresponding exponential approximation values to obtain the sum value, and the division computing step divides each of the corresponding exponential approximation values by the sum value to obtain a plurality of the output values of the m-dimensional vector corresponding to the k-dimensional vector.

### Claim 6 (depends on 1)

The method of claim 1, wherein the input value is a numerical value in the form of an integer.

### Claim 7

A neural network, the neural network having a classifier which has a softmax function computing module, the softmax function computing module converting one or more input values of a k-dimensional vector into one or more output values of a m-dimensional vector, the softmax function computing module including: an exponential function approximation computing unit performing a Leaky Rectified Linear Unit (Leaky ReLU) computation on one of the input values of the k-dimensional vector to obtain a Leaky ReLU computation value and performing a polynomial function computation of a certain order based on the Leaky ReLU computation value to obtain an exponential approximation value, wherein the exponential function approximation computing unit further repeatedly processes another one of the input values of the k-dimensional vector to obtain another exponential approximation value;
an addition computing unit adding the exponential approximation value and the another exponential approximation value to obtain a sum value; and
a division computing unit dividing at least one of the exponential approximation values by the sum value to obtain one of the output values of the m-dimensional vector.

### Claim 8 (depends on 7)

The neural network of claim 7, wherein the exponential function approximation computing unit performs a Clamp function computation on the input value before performing the Leaky Rectified Linear Unit (Leaky ReLU) computation on the input value.

### Claim 9 (depends on 8)

The neural network of claim 8, wherein the addition computing unit further adds the sum value with a protection value to ensure that an absolute value of the sum value is greater than zero.

### Claim 10 (depends on 7)

The neural network of claim 7, wherein the polynomial function computation of a certain order is a polynomial function computation of second-order to fifth-order.

### Claim 11 (depends on 7)

The neural network of claim 7, wherein the exponential function approximation computing unit repeatedly performs the Leaky Rectified Linear Unit (Leaky ReLU) computation on each of the input values to obtain the corresponding Leaky ReLU computation value, and the polynomial function computation of a certain order is performed based on the corresponding Leaky ReLU computation value to obtain the corresponding exponential approximation value, the addition computing unit adds up all the corresponding exponential approximation values to obtain a sum value, and the division computing unit divides each of the corresponding exponential approximation values by the sum value to obtain a plurality of the output values of the m-dimensional vector corresponding to the k-dimensional vector.

### Claim 12 (depends on 7)

The neural network of claim 7, wherein the input value is a numerical value in the form of an integer.
