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

# MLCScatterLayer

A layer that updates the output at an index you specify.

```
class MLCScatterLayer
```

## Topics

### Creating Scatter Layers

[`init(dimension:reductionType:)`](/documentation/MLCompute/MLCScatterLayer/init(dimension:reductionType:))

Creates a scatter layer with the dimension and reduction type you specify.

### Inspecting Scatter Layers

[`dimension`](/documentation/MLCompute/MLCScatterLayer/dimension)

The dimension to index.

[`reductionType`](/documentation/MLCompute/MLCScatterLayer/reductionType)

The reduction type that applies to all values in the source tensor.



---

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)