init(parameters:)
Initializes the custom layer implementation.
Declaration
init(parameters: [String : Any]) throwsParameters
- parameters:
The contents of the parameter dictionary from the
.mlmodelfile.
Mentioned in
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.