<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: 14.0.0 -",
    "macOS: 11.0.0 -",
    "tvOS: 14.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 7.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/BNNSActivationFunctionCELU",
  "metadataVersion" : "0.1.0",
  "role" : "Global Variable",
  "symbol" : {
    "kind" : "Global Variable",
    "modules" : [
      "Accelerate"
    ],
    "preciseIdentifier" : "c:@EA@BNNSActivationFunction@BNNSActivationFunctionCELU"
  },
  "title" : "BNNSActivationFunctionCELU"
}
-->

# BNNSActivationFunctionCELU

An activation function that evaluates the continuously differentiable exponential linear units (CELU) on its input.

```
var BNNSActivationFunctionCELU: BNNSActivationFunction { get }
```

## Discussion

This constant defines an activation function that returns values using the following operation:

```
if x < 0
    alpha*(exp(x/alpha) - 1) 
else
    x
```

The following illustrates the output that the activation function generates from inputs in the range `-10...10` and an `alpha` of `1`:

![Graph that shows input values for the activation function on horizontal axis and its output values on vertical axis. ](images/com.apple.accelerate/media-3560467@2x.png)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)