<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: 17.0.0 -",
    "macOS: 14.0.0 -",
    "tvOS: 17.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 11.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CreateMLComponents",
  "identifier" : "/documentation/CreateMLComponents/OptimizationError",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "Create ML Components"
    ],
    "preciseIdentifier" : "s:18CreateMLComponents17OptimizationErrorO"
  },
  "title" : "OptimizationError"
}
-->

# OptimizationError

An optimization error.

```
enum OptimizationError
```

## Topics

### Analyzing the error

[`case numericOverflow`](/documentation/CreateMLComponents/OptimizationError/numericOverflow)

Numerical overflow. Step size parameter may be too large.

[`case numericUnderflow`](/documentation/CreateMLComponents/OptimizationError/numericUnderflow)

Numerical underflow (not enough progress).

[`case unsupportedPlatform`](/documentation/CreateMLComponents/OptimizationError/unsupportedPlatform)

The optimization operation is not supported on this platform.

### Getting the debug description

[`var debugDescription: String`](/documentation/CreateMLComponents/OptimizationError/debugDescription)

A text representation of the error.

### Default Implementations

[CustomDebugStringConvertible Implementations](/documentation/CreateMLComponents/OptimizationError/CustomDebugStringConvertible-Implementations)

## Relationships

### Conforms To

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

[`Sendable`](/documentation/Swift/Sendable)

[`Copyable`](/documentation/Swift/Copyable)

[`LocalizedError`](/documentation/Foundation/LocalizedError)

[`Escapable`](/documentation/Swift/Escapable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Equatable`](/documentation/Swift/Equatable)

[`Hashable`](/documentation/Swift/Hashable)

[`Error`](/documentation/Swift/Error)

---

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)