# MachineLearningContext

> Represents a machine learning context used for lifetime control and pooling of the compiled MachineLearningOperator.

## Definition

* **Type:** Class
* **Namespace:** [UnityEngine.Rendering](/engine/6000.6/script-reference/unityengine/rendering.md)
* **Assembly:** UnityEngine.CoreModule
* **Implements:** [IDisposable](https://learn.microsoft.com/dotnet/api/system.idisposable)

```csharp
public class MachineLearningContext : IDisposable
```

## Constructors

| Constructor                                                                                                      | Description                            |
| ---------------------------------------------------------------------------------------------------------------- | -------------------------------------- |
| [MachineLearningContext()](/engine/6000.6/script-reference/unityengine/rendering/machinelearningcontext/ctor.md) | Create a new machine learning context. |

## Methods

| Method                                                                                             | Description                                                                                                                                                        |
| -------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| [Dispose](/engine/6000.6/script-reference/unityengine/rendering/machinelearningcontext/dispose.md) | Disposes the [MachineLearningContext](/engine/6000.6/script-reference/unityengine/rendering/machinelearningcontext.md) instance and all pooled compiled operators. |
