VisionInference QML Type
Runs AI inference on incoming video frames. More...
| Import Statement: | import QtEdgeAi |
| Since: | Qt 6.12 |
| Inherits: | |
| Status: | Technical Preview |
Properties
- configFile : url
- provider : string
Detailed Description
VisionInference is an InferenceStep that runs a vision model, such as a classifier or detector, on the frames it receives and produces structured results. Place it after an InferenceVideoSource in an InferenceFlow, and connect its output to an InferenceResultParser to interpret the results.
Everything the step provider needs to run the model, such as the model itself, its labels and the detection threshold, comes from the configFile. The provider selects the step provider that the file is written for, so both properties are required. When the QML component completes, the step creates the underlying C++ QVisionInference with these values; changing them afterwards has no effect and logs a warning. Without a provider, the underlying step is not created.
VisionInference {
provider: "edgeimpulse"
configFile: "configs/edgeimpulse/inference.json"
}See also InferenceStep, InferenceVideoSource, and InferenceResultParser.
Property Documentation
configFile : url [required]
This property holds the configuration file for the step.
What the file contains, and in which format, depends entirely on the step provider. A step provider that has a configuration file format of its own reads the file with its own parser; the others read a JSON object, use the keys they know, and ignore the rest.
A relative URL is resolved against the application's directory, not against the QML file, and only local files are supported. Relative paths inside the file are resolved against the application's directory too.
See also Qt Edge AI Configuration Files.
provider : string [required]
This property holds the name of the step provider that runs the step.
The factory creates the underlying step with the step provider that is registered under this name. The configFile is specific to the provider, so a step needs both.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.