Repository navigation
v1.0.0 — First stable release
First stable release of onnx2coreml — an ONNX → Apple Core ML converter producing .mlpackage (ML Program / MIL) and .mlmodel (NeuralNetwork), built on coremltools' MIL builder and verified for numerical parity against ONNX Runtime.
Highlights
- 105 operator lowerings across elementwise/math, activations, convolution/pooling, normalization, linear, shape/movement, indexing/gather-scatter, reduction, recurrent, and attention families.
- Two output formats — ML Program (
.mlpackage, fp16, modern on-device performance) and NeuralNetwork (.mlmodel, older-OS reach). - Verified, not assumed — every operator has parity tests run against the live Core ML runtime on macOS.
Added
- Operator coverage expanded to 105 ops: LSTM (recurrent), GridSample, DepthToSpace, TopK, the ReduceL1/L2/LogSum/LogSumExp/SumSquare family, GatherND/GatherElements, ScatterND/ScatterElements, NonZero, matrix Inverse (
com.microsoft), and the trigonometric, logical, and comparison operators. - Selective fp16 precision:
convert(..., fp32_op_types={...})keeps numerically sensitive ops in fp32 while the rest runs fp16. - Model-zoo evaluation and export tooling under
tools/.
Fixed
- PRelu now handles slopes that broadcast across more than the channel dimension (e.g.
(C, H, W)), using the exact elementwise identity rather than Core ML's per-channelpreluop. - ConvTranspose now honors
output_padding. - PRelu handles non-rank-4 inputs and scalar slopes; Clip handles integer tensors; Expand handles boolean tensors.
- Constants are saturated into the int32 and fp16 ranges to avoid overflow (int64 sentinels and FLT_MAX attention-mask fills).
Install
uv pip install onnx2coreml==1.0.0Full changelog: https://github.com/devin-lai/onnx2coreml/blob/main/CHANGELOG.md