<!--
{
  "availability" : [
    "iOS: 14.0.0 - 17.4.0",
    "iPadOS: 14.0.0 - 17.4.0",
    "macCatalyst: 14.0.0 - 17.4.0",
    "macOS: 11.0.0 - 14.3.0",
    "tvOS: 14.0.0 - 17.4.0"
  ],
  "documentType" : "symbol",
  "framework" : "MLCompute",
  "identifier" : "/documentation/MLCompute/MLCActivationDescriptor",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "ML Compute"
    ],
    "preciseIdentifier" : "c:objc(cs)MLCActivationDescriptor"
  },
  "title" : "MLCActivationDescriptor"
}
-->

# MLCActivationDescriptor

A configuration object you use to create an activation layer.

```
class MLCActivationDescriptor
```

## Overview

The framework provides the following activation descriptor initializers to create the associated descriptors:

- [`init(type:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:)): Absolute, GELU, Identity, LogSigmoid, Parametric Soft Sign, SELU, Sigmoid, TanhShrink
- [`init(type:a:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:a:)): CELU, HardShrink, Parametric ELU, ReLU, SoftShrink
- [`init(type:a:b:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:a:b:)): Hard Sigmoid, Hyperbolic tangent (TanH), Linear, Parametric Soft Plus, ReLUN, Threshold

## Topics

### Creating Activation Descriptors

[`init(type:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:))

Creates an activation descriptor with the activation type you specify.

[`init(type:a:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:a:))

Creates an activation descriptor with the activation type and parameter a that you specify.

[`init(type:a:b:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:a:b:))

Creates an activation descriptor with the activation type and parameters a and b that you specify.

[`init(type:a:b:c:)`](/documentation/MLCompute/MLCActivationDescriptor/init(type:a:b:c:))

Creates an activation descriptor with the activation type and parameters a, b, and c that you specify.

[`MLCActivationType`](/documentation/MLCompute/MLCActivationType)

An activation type that you specify for an activation descriptor.

### Inspecting Activation Descriptors

[`activationType`](/documentation/MLCompute/MLCActivationDescriptor/activationType)

The type of activation function.

[`a`](/documentation/MLCompute/MLCActivationDescriptor/a)

The parameter a to the activation function.

[`b`](/documentation/MLCompute/MLCActivationDescriptor/b)

The parameter b to the activation function.

[`c`](/documentation/MLCompute/MLCActivationDescriptor/c)

The parameter c to the activation function.



---

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)