---
title: "init(parameters:)"
framework: coreml
role: symbol
role_heading: Initializer
path: "coreml/mlcustomlayer/init(parameters:)"
---

# init(parameters:)

Initializes the custom layer implementation.

## Declaration

```swift
init(parameters: [String : Any]) throws
```

## Parameters

- `parameters`: The contents of the parameter dictionary from the .mlmodel file.

## Mentioned in

Creating and Integrating a Model with Custom Layers

## Discussion

Discussion Implement this method to initialize your custom layer. It is called once, at load time. Use the parameters to configure the custom layer as needed. If the layer cannot be initialized, your implementation should throw a customLayer error.
