---
title: Adding custom functions to a shader graph
framework: metalperformanceshadersgraph
role: sampleCode
role_heading: Sample Code
path: metalperformanceshadersgraph/adding-custom-functions-to-a-shader-graph
---

# Adding custom functions to a shader graph

Run your own graph functions on the GPU by building the function programmatically.

## Overview

Overview note: This sample code project is associated with WWDC20 session 10677: Build Customized ML Models with the Metal Performance Shaders Graph. Configure the sample code project This sample requires the following system and software configuration: macOS 11 or later iOS 14 or later Xcode 12 or later

## See Also

### Essentials

- [Training a neural network using MPSGraph](metalperformanceshadersgraph/training-a-neural-network-using-mps-graph.md)
- [Filtering images with MPSGraph FFT operations](metalperformanceshadersgraph/filtering-images-with-mpsgraph-fft-operations.md)
