Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.2   6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5    Statistic  

CoreML.OpenModel

Opens a compiled model file.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
CoreML 7.4 Yes No Yes, macOS only No Yes

MBS( "CoreML.OpenModel"; Path )

Parameters

Parameter Description Example value
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.

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


CoreML.GetUsesCPUOnly   -   CoreML.PredictionFromFeatures

Feedback: Report problem or ask question.




Links
MBS Xojo Plugins