<!--
{
  "availability" : [
    "iOS: 11.0.0 -",
    "iPadOS: 11.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.13.0 -",
    "tvOS: 11.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Vision",
  "identifier" : "/documentation/Vision/VNCoreMLRequest",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "Vision"
    ],
    "preciseIdentifier" : "c:objc(cs)VNCoreMLRequest"
  },
  "title" : "VNCoreMLRequest"
}
-->

# VNCoreMLRequest

An image-analysis request that uses a Core ML model to process images.

```
class VNCoreMLRequest
```

## Overview

The results array of a Core ML-based image analysis request contains a different observation type, depending on the kind of <doc://com.apple.documentation/documentation/CoreML/MLModel> object you use:

- If the model predicts a single feature, the model’s <doc://com.apple.documentation/documentation/CoreML/MLModel/modelDescription> object has a non-`nil` value for <doc://com.apple.documentation/documentation/CoreML/MLModelDescription/predictedFeatureName> and Vision treats the model as a classifier. The results are [`VNClassificationObservation`](/documentation/Vision/VNClassificationObservation) objects.
- If the model’s outputs include at least one output with a feature type of <doc://com.apple.documentation/documentation/CoreML/MLFeatureType/image>, Vision treats that model as an image-to-image model. The results are [`VNPixelBufferObservation`](/documentation/Vision/VNPixelBufferObservation) objects.
- Otherwise, Vision treats the model as a general predictor model. The results are [`VNCoreMLFeatureValueObservation`](/documentation/Vision/VNCoreMLFeatureValueObservation) objects.

> Note:
> Vision forwards all ``doc://Vision/documentation/Vision/VNObservation/confidence`` values from Core ML models as-is and doesn’t normalize them to `[0, 1]`.

## Topics

### Initializing with a Core ML Model

[`init(model:)`](/documentation/Vision/VNCoreMLRequest/init(model:))

Creates a model container to use with an image analysis request based on the model you provide.

[`init(model:completionHandler:)`](/documentation/Vision/VNCoreMLRequest/init(model:completionHandler:))

Creates a model container to use with an image analysis request based on the model you provide, with an optional completion handler.

[`model`](/documentation/Vision/VNCoreMLRequest/model)

The model to base the image analysis request on.

[`VNCoreMLModel`](/documentation/Vision/VNCoreMLModel)

A container for the model to use with Vision requests.

### Configuring Image Options

[`imageCropAndScaleOption`](/documentation/Vision/VNCoreMLRequest/imageCropAndScaleOption)

An optional setting that tells the Vision algorithm how to scale an input image.

[`VNImageCropAndScaleOption`](/documentation/Vision/VNImageCropAndScaleOption)

Options that define how Vision crops and scales an input-image.

### Identifying Request Revisions

[`VNCoreMLRequestRevision1`](/documentation/Vision/VNCoreMLRequestRevision1)

A constant for specifying revision 1 of a Core ML request.



---

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)