ONNX Runtime v1.5.1
Key Updates
General
- Reduced Operator Kernel build allows ORT binaries to be built with only required operators in the model(s) - learn more
- [Preview] ORT for Mobile Platforms - minimizes build size for mobile and embedded devices - learn more
- Transformer model inferencing performance optimizations
- Perf improvement for DistilBERT
- Benchmark tool supports more pretrained models
- Improvements in quantization tool
- Support quantization-aware training models
- Make calibration tool to support general preprocessing and calibrate on input
- Simplify the quantization APIs
- Support of model larger than 2G
- New operators for static quantization: QLinearMul, QLinearAdd, QlinearSigmoid and QLinearLeakyRelu
- Prepack constant matrix B for float GEMM (MatMul, Attention)
- Limited Python 3.8 support added in addition to 3.5-3.7 for official Python packages. Not yet supported for Windows GPU and Linux ARM builds.
- Telemetry enabled in Java and NodeJS packages for Windows builds. Note: data is not directly sent to Microsoft or ORT teams by ONNX Runtime; enabling telemetry means trace events are collected by the Windows operating system and may be sent to the cloud based on the user's privacy settings - learn more.
API
- Python API support for RegisterCustomOpsLibrary
- IO Binding API for C/C++/C# language bindings. This allows use of pre-allocated buffers on targeted devices and also target device for unknown output shapes.
- Sharing of allocators between multiple sessions. This allows much better utilization of memory by not creating a separate arena for each session in the same process. See this for details.
Windows ML
- NuGet package now supports UWP applications targeting Windows Store deployment (CPU only)
- NuGet package now supports .NET and .NET framework applications
- RUST Developers can now deploy Windows ML – sample and documentation available here
- New APIs to for additional performance control:
- IntraopNumThreads: Provides an ability to change the number of threads used in the threadpool for Intra Operator Execution for CPU operators through LearningModelSessionOptions.
- SetNamedDimensionOverrides: Provides the ability to override named input dimensions to concrete values through LearningModelSessionOptions in order to achieve better runtime performance.
- Support for additional ONNX format image type denotations – Gray8, normalized [0..1] and normalized [-1..1]
- Reduced Windows ML package size by separating debug symbols into separate distribution package.
Execution Providers
- CUDA updates
- CUDA 10.2 / cuDNN 8.0 in official package
- CUDA 11 support added and available to build from source
- CUDA conv kernel support asymmetrical padding to fully support models such as YoloV3 for improved GPU perf
- TensorRT EP updates
- Support for TensorRT 7.1
- Added TensorRT engine caching feature, turned on by setting env variable ORT_TENSORRT_ENGINE_CACHE_ENABLE=1
- TensorRT builds are now built with the Execution Provider as a separate dll. If enabled in the build, the provider will be available as a shared library. This was previously also enabled for the DNNL EP (ORT 1.3). Other Execution Providers will be added in the future.
- OpenVINO EP updates
- Support for OpenVINO 2020.4
- Added runtime options for VPU hardware to select specific hardware device and enable fast compilation of models.
- Enable C# binding support for OpenVINO EP
- DirectML EP updates
- API available for Python (build from source) and C# Microsoft.ML.OnnxRuntime.DirectML
- 7 new operators for ONNX 1.7 (opset 12): Celu, GreaterOrEqual, LessOrEqual, ArgMin/Max with select_last_index, GatherND with batch_dim, RoiAlign
- New data integer types were added to existing operators: Clip int, Max int, Min int, MaxPool int8, ReduceMin int8, ReduceMax int8, Pow int exponent
- Higher dimension support 1D to 8D added to these operators: ElementWise*, Activation*, Reduce*, ArgMin/ArgMax, Gather*, Scatter*, OneHot
- 64-bit support for indices on GPU's that support it: Gather, Scatter, OneHot, ArgMax/ArgMin, Cast.
- Android NNAPI EP updates:
- Support for dynamic input shape
- Int32/float32/uint8 data type
- 50% more supported operators (36 total)
- Support for Uint8 static quantization
- Smaller binary size
- Lower memory consumption
- CPU fallback for Android level 26-
- MiGraphX EP updates
- Added ONNX operators: GatherElements, NonZero, Equal, and Where
- Support for Boolean data type
- Improve support for existing operators:
- Asymmetric padding of AveragePool
- Multi-dimensional support for Convolution, Pooling, LRN, and Batchnormalization
- Ceil mode support for AveragePool and MaxPool
- More general approach to check whether constant folding is possible
- Improved graph partitioning logic
Training (RC3 release)
- New and improved API to simplify integration with PyTorch trainer code - see instructions here
- Updated CUDA 11 / cuDNN 8.0 support to accelerate in NVIDIA A100
Dependency updates
MacOS binaries now rely on openmp to be installed. See this for reference.
Contributions
Contributors to ONNX Runtime include members across teams at Microsoft, along with our community members:
gwang-msft, snnn, skottmckay, hariharans29, thiagocrepaldi, tianleiwu, wangyems, RandySheriffH, yufenglee, SherlockNoMad, smk2007, jywu-msft, liqunfu, edgchen1, yuslepukhin, tiagoshibata, fdwr, ashbhandare, iK1D, wschin, BowenBao, zhanghuanrong, RyanUnderhill, ryanlai2, askhade, pranavsharma, martinb35, suffiank, ytaous, KeDengMS, rayankrish, natke, YUNQIUGUO, range4life, smkarlap, zhangxiang1993, xzhu1900, codemzs, weixingzhang, stevenlix, tracysh, mosdav, jingyanwangms, tlh20, souptc, orilevari, kit1980, yangchen-MS, faxu, fs-eire, wenbingl, chilo-ms, xkszltl, Andrews548, yuzawa-san, MaximKalininMS, jgbradley1, nickfeeney, zhijxu-MS, Tixxx, suryasidd, Craigacp, duli2012, jeffbloo