Topics   All   MacOS (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server   Client   Old   Deprecated   Guides   Examples   Videos
New in version: 12.2   12.3   12.4   12.5   13.0   13.1   13.2   13.3   13.4   13.5    Statistic    FMM    Blog  

CoreML.OpenModel

Opens a compiled model file.

Component Version macOS Windows Linux Server iOS SDK
CoreML 7.4 ✅ Yes ❌ No ❌ No ✅ Yes, on macOS ✅ Yes
MBS( "CoreML.OpenModel"; Path )   More

Parameters

Parameter Description Example
Path The path to the model file. "/test.mlmodelc"

Result

Returns OK or error.

Description

Opens a compiled model file.
If the model is not compiled (*.mlmodel), you can compile it with CoreML.CompileModel.
Returns error message if there is a problem.

See also Vision.ClassifyImage to use Vision framework from Apple to classify images with Apple's model.

Examples

Load Model:

Set Variable [ $$ML ; Value: MBS("CoreML.OpenModel"; CoreML::Model Path) ]
If [ MBS("IsError") ]
    Show Custom Dialog [ "Failed to load" ; $$ML ]
    Set Variable [ $$ML ; Value: "" ]
Else
    Set Field [ CoreML::Model Description ; MBS("CoreML.Description"; $$ML) ]
End If

See also

Example Databases

Blog Entries

This function checks for a license.

Created 16th September 2017, last changed 17th October 2019


CoreML.List - CoreML.PredictionFromFeatures

💬 Ask a question or report a problem