---
title: "init(MTLBuffer:shape:dataType:rowBytes:)"
framework: metalperformanceshadersgraph
role: symbol
role_heading: Initializer
path: "metalperformanceshadersgraph/mpsgraphtensordata/init(mtlbuffer:shape:datatype:rowbytes:)"
---

# init(MTLBuffer:shape:dataType:rowBytes:)

## Declaration

```swift
init(MTLBuffer buffer: any MTLBuffer, shape: [NSNumber], dataType: MPSDataType, rowBytes: Int)
```
