Page Summary
-
MLKLocalModelrepresents a machine learning model stored on the device. -
It can be initialized using either a model file path or a manifest file path.
-
The
pathproperty provides the absolute path to the model file. -
The
manifestPathproperty, if available, gives the absolute path to the model manifest file. -
Initializing with an invalid or missing manifest path will return
nil.
MLKLocalModel
@interface
MLKLocalModel
:
NSObject
A model stored locally on the device.
-
An absolute path to a model file stored locally on the device.
Declaration
Objective-C
@property ( nonatomic , copy , readonly ) NSString * _Nonnull path ; -
An absolute path to a model manifest file stored locally on the device.
nilif the model does not have a manifest.Declaration
Objective-C
@property ( nonatomic , copy , readonly , nullable ) NSString * manifestPath ; -
Creates a new instance with the given model file path.
Declaration
Objective-C
- ( nonnull instancetype ) initWithPath :( nonnull NSString * ) path ;Parameters
pathAbsolute path to a model file stored locally on the device.
Return Value
A new
LocalModelinstance. -
Creates a new instance with the given manifest file path of an AutoML Vision Edge model.
Declaration
Objective-C
- ( nullable instancetype ) initWithManifestPath :( nonnull NSString * ) manifestPath ;Parameters
manifestPathAbsolute path to an AutoML Vision Edge model manifest stored locally on the device.
Return Value
A new
LocalModelinstance.nilif the model manifest at the givenmanifestPathis either missing or invalid. -
Unavailable.
Declaration
Objective-C
- ( nonnull instancetype ) init ;


