An example of You Only Look At CoefficienTs on iOS using CoreML.
Yolact (https://github.com/dbolya/yolact) is a simple, fully convolutional model for real-time instance segmentation. https://arxiv.org/abs/1904.02689
onnx 1.4.1
onnx-coreml 0.4.0
onnx-simplifier 0.1.8
torch 1.0.1
How to convert pytorch model to CoreML model:
-
Run yolcat code with ONNX and CoreML converter to convert to ONNX model (WITHOUT priors layer).
-
Use onnx-simplifier to simplify ONNX model.
-
Disable Upsample layer in onnx-coreml package to make Upsample custom layer in CoreML.
-
Run ONNXToCoreML converter to conver ONNX mode to CoreML model, input should be MLMultiArray (3x550x550) and we need to do input normalization in our application code.
- Simply model to get more performance on mobile devices.