<!--
{
  "availability" : [
    "iOS: 16.3.0 -",
    "iPadOS: 16.3.0 -",
    "macCatalyst: 16.3.0 -",
    "macOS: 13.2.0 -",
    "tvOS: 16.3.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MetalPerformanceShadersGraph",
  "identifier" : "/documentation/MetalPerformanceShadersGraph/MPSGraphExecutable/getOutputTypes(with:inputTypes:compilationDescriptor:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Metal Performance Shaders Graph"
    ],
    "preciseIdentifier" : "c:objc(cs)MPSGraphExecutable(im)getOutputTypesWithDevice:inputTypes:compilationDescriptor:"
  },
  "title" : "getOutputTypes(with:inputTypes:compilationDescriptor:)"
}
-->

# getOutputTypes(with:inputTypes:compilationDescriptor:)

Get output shapes for a specialized executable.

```
func getOutputTypes(with device: MPSGraphDevice?, inputTypes: [MPSGraphType], compilationDescriptor: MPSGraphCompilationDescriptor?) -> [MPSGraphShapedType]?
```

## Parameters

`device`

Optional MPSGraph device to compile with

`inputTypes`

Input types expected to be passed to the executable.

`compilationDescriptor`

CompilationDescriptor to be used to specialize, since the executable was created with a compilationDescriptor already this one overrides those settings to the extent it can.

## Discussion

In case specialization has not been done yet then calling this function will specialize for the given input shapes.

---

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)