MLKCustomImageLabelerOptions
@interface MLKCustomImageLabelerOptions : MLKCommonImageLabelerOptions
Configurations for a custom-model image labeler.
-
The maximum number of labels to return for an image. Must be positive. If unset or an invalid value is set, the default value of
10
is used.Declaration
Objective-C
@property (nonatomic) NSInteger maxResultCount;
-
Initializes a
CustomImageLabelerOptions
instance using the givenLocalModel
with theconfidenceThreshold
property set tonil
. If that remains unset, it will use the confidence threshold value included in the model metadata, if available. If that does not exist, a value of0.0
will be used instead.Declaration
Objective-C
- (nonnull instancetype)initWithLocalModel:(nonnull MLKLocalModel *)localModel;
Parameters
localModel
A custom image labeling model stored locally on the device.
Return Value
A new instance of
CustomImageLabelerOptions
with the givenLocalModel
. -
Initializes a
CustomImageLabelerOptions
instance using the givenCustomRemoteModel
with theconfidenceThreshold
property set tonil
. If that remains unset, it will use the confidence threshold value included in the model metadata, if available. If that does not exist, a value of0.0
will be used instead.Declaration
Objective-C
- (nonnull instancetype)initWithRemoteModel: (nonnull MLKCustomRemoteModel *)remoteModel;
Parameters
remoteModel
A custom image labeling model stored remotely on the server and downloaded to the device.
Return Value
A new instance of
CustomImageLabelerOptions
with the givenCustomRemoteModel
. -
Unavailable.
Declaration
Objective-C
- (nonnull instancetype)init;