Package apple.coreml.protocol
Interface MLCustomModel
-
public interface MLCustomModelProtocol for specifying a custom model implementation.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description java.lang.ObjectinitWithModelDescriptionParameterDictionaryError(MLModelDescription modelDescription, NSDictionary<java.lang.String,?> parameters, org.moe.natj.general.ptr.Ptr<NSError> error)Initialize the custom model implementation.MLFeatureProviderpredictionFromFeaturesOptionsError(MLFeatureProvider input, MLPredictionOptions options, org.moe.natj.general.ptr.Ptr<NSError> error)Required implemenationat of a single sample input prediction.default MLBatchProviderpredictionsFromBatchOptionsError(MLBatchProvider inputBatch, MLPredictionOptions options, org.moe.natj.general.ptr.Ptr<NSError> error)Batch prediction with explicit options, if not implemented the single input predictionFromFeatures:options:error will be used
-
-
-
Method Detail
-
initWithModelDescriptionParameterDictionaryError
java.lang.Object initWithModelDescriptionParameterDictionaryError(MLModelDescription modelDescription, NSDictionary<java.lang.String,?> parameters, org.moe.natj.general.ptr.Ptr<NSError> error)
Initialize the custom model implementation. The model description describes the input and output feature types and metadata in the Model specificaiton. The parameter dictionary contains the contents of the 'parameters' map from the CustomModel specification. This function is called once on model load. We expect the implementation to return 'nil' and set an error in the event of failure initializing the object.
-
predictionFromFeaturesOptionsError
MLFeatureProvider predictionFromFeaturesOptionsError(MLFeatureProvider input, MLPredictionOptions options, org.moe.natj.general.ptr.Ptr<NSError> error)
Required implemenationat of a single sample input prediction.
-
predictionsFromBatchOptionsError
default MLBatchProvider predictionsFromBatchOptionsError(MLBatchProvider inputBatch, MLPredictionOptions options, org.moe.natj.general.ptr.Ptr<NSError> error)
Batch prediction with explicit options, if not implemented the single input predictionFromFeatures:options:error will be used
-
-