ONNX Runtime: cross-platform, high performance ML inferencing and training accelerator
Find a file
George Nash 1c38ceda49
Add fusion support for Dnnl execution provider (#9897)
* Op fusion support added

In addition the following op fusions are detected
 - ConvRelu
 - MatMulAdd

This change includes
  - Change abstraction of Subgraph + node + tensor to support delete insert
    modify
  - add nodearg class to establish connection from tensor to node
  - add graphtransformer class to support fusion
  - add topological sort to ensure propoer node ordering after fusion
  - add convrelu + matmuladd primitive to support execution of fused nodes
  - Fix FusionResolution with missing tensors

    when fusing, if the target node contains fewer tensors then original
    patterns (Gelu and FastGelu ignores many initializers), potentially delete them
    also from inputs and initializers

    Also check tensor has no producer and consumer before deleting

Signed-off-by: Wang <zhaoyang.wang@intel.com>

* Gelu and FastGelu Fusion for DNNL EP

The basics of the Gelu/FastGelu code is modeled after:
   - core/optimizer/fast_gelu_fusion.cc and
   - core/optimizer/gelu_fusion.cc

OneDNN does not have support for 'Erf' unless it is part of 'Gelu'.

This results in detecting 'Gelu' fusion twice. Once when detecting
if the 'Erf' Operator is supported and again in the subgraph transformer
code. The capability code is finding the Gelu using onnxruntime:GraphViewer
and onnxruntime::Node.  While the transformer code is using DnnlSubgraph
and DnnlNode.  This results in two parts of code looking for the same
pattern but unfortanatly having little code reuse.

This also adds support for Biased versions of Gelu and FastGelu if they already
exist in a model.

Signed-off-by: George Nash <george.nash@intel.com>

* Code Clean Up

Signed-off-by: Wang <zhaoyang.wang@intel.com>

Co-authored-by: Wang <zhaoyang.wang@intel.com>
2021-12-02 18:11:19 -08:00
.gdn Update compliance tasks in python packaging pipeline and fix some compile warnings (#8471) 2021-07-30 17:16:37 -07:00
.github Update issue template to ask users to check known issues to avoid repetition. (#8288) 2021-07-02 15:36:14 -07:00
cgmanifests Update manylinux build scripts (#9701) 2021-11-09 11:55:49 -08:00
cmake add --amdgpu-target=gfx90a (#9820) 2021-12-01 22:28:52 -08:00
csharp Update to include the Xamarin targets for internal ORT builds so the managed nuget package is consistent as both CPU and GPU builds produce a package called Microsoft.ML.OnnxRuntime.Managed. (#9906) 2021-12-02 18:43:34 +10:00
dockerfiles [OpenVINO-EP] V3.4 Release with OpenVINO 2021.4.2 LTS Release (#9848) 2021-11-23 13:12:08 -08:00
docs Update doc for operators/opsets supported by mobile package (#9899) 2021-12-02 13:51:22 +10:00
include/onnxruntime/core Various fixes to fix WindowsAI RI build. (#9877) 2021-11-29 21:33:15 -08:00
java Support optional type in ORT (#8339) 2021-11-04 15:01:42 -07:00
js [js/node] npm audit fix (#9861) 2021-11-29 13:11:19 -08:00
objectivec [Objective-C API] WIgnore clang documentation warnings from C/C++ header usage. (#9057) 2021-09-14 13:03:48 -07:00
onnxruntime Add fusion support for Dnnl execution provider (#9897) 2021-12-02 18:11:19 -08:00
orttraining ScatterND supports negative indices (#9739) 2021-11-30 21:17:32 -08:00
package/rpm Bumping up to 1.10 (#9006) 2021-09-22 16:34:28 -07:00
samples Add Python checks pipeline (#7032) 2021-08-09 10:37:05 -07:00
server Remove redundant inline specifiers, sync server IsLittleEndianOrder with runtime core (#9856) 2021-11-29 08:32:16 -08:00
tools changing commit for windows build for eager mode (#9912) 2021-12-02 14:07:46 -08:00
winml WinML RT API: Add PixelRange Metadata to Bind() call PropertySet (#9827) 2021-11-24 13:44:25 -08:00
.clang-format
.clang-tidy
.dockerignore Update dockerfiles (#5929) 2020-11-25 15:38:22 -08:00
.flake8 Add Python checks pipeline (#7032) 2021-08-09 10:37:05 -07:00
.gitattributes
.gitignore Add Xamarin support (#9436) 2021-10-27 20:07:07 +10:00
.gitmodules Remove optional-lite (#9424) 2021-10-22 16:45:45 -07:00
build.amd64.1411.bat
build.bat
build.sh Add iOS test pipeline and a sample app. (#5298) 2020-09-29 13:53:11 -07:00
CODEOWNERS Update ORTTraiing frontend codeowner (#9427) 2021-10-18 23:56:21 -07:00
CONTRIBUTING.md fixed the link (#8757) 2021-08-18 11:45:42 -07:00
LICENSE Remove year from license (#6658) 2021-02-12 00:25:56 -08:00
NuGet.config Delete nuget extra configs (#6477) 2021-01-27 20:25:45 -08:00
ort.wprp
packages.config Update to 1.8.0 2021-11-19 04:44:32 -08:00
README.md Fix typo 2021-08-12 15:57:15 -07:00
requirements-dev.txt Add post-install command to build PyTorch CPP extensions from within onnxruntime package (#8027) 2021-06-28 18:11:58 -07:00
requirements-doc.txt Add auto doc gen for ORTModule API during CI build (#7046) 2021-03-22 10:20:33 -07:00
requirements-training.txt Add post-install command to build PyTorch CPP extensions from within onnxruntime package (#8027) 2021-06-28 18:11:58 -07:00
requirements.txt.in Chang how numpy version is handled. (#8130) 2021-06-23 14:08:37 -07:00
setup.py Integrate TensorRT into GPU Python package (#9785) 2021-11-18 13:26:51 -08:00
ThirdPartyNotices.txt Clean up optional-lite references (#9534) 2021-10-25 21:05:45 -07:00
VERSION_NUMBER Bumping up to 1.10 (#9006) 2021-09-22 16:34:28 -07:00

ONNX Runtime is a cross-platform inference and training machine-learning accelerator.

ONNX Runtime inference can enable faster customer experiences and lower costs, supporting models from deep learning frameworks such as PyTorch and TensorFlow/Keras as well as classical machine learning libraries such as scikit-learn, LightGBM, XGBoost, etc. ONNX Runtime is compatible with different hardware, drivers, and operating systems, and provides optimal performance by leveraging hardware accelerators where applicable alongside graph optimizations and transforms. Learn more →

ONNX Runtime training can accelerate the model training time on multi-node NVIDIA GPUs for transformer models with a one-line addition for existing PyTorch training scripts. Learn more →

Get Started

General Information: onnxruntime.ai

Usage documention and tutorials: onnxruntime.ai/docs

Companion sample repositories:

Build Pipeline Status

System CPU GPU EPs
Windows Build Status Build Status Build Status
Linux Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Build Status
Mac Build Status
Build Status
Android Build Status
iOS Build Status
WebAssembly Build Status

Data/Telemetry

Windows distributions of this project may collect usage data and send it to Microsoft to help improve our products and services. See the privacy statement for more details.

Contributions and Feedback

We welcome contributions! Please see the contribution guidelines.

For feature requests or bug reports, please file a GitHub Issue.

For general discussion or questions, please use GitHub Discussions.

Code of Conduct

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

License

This project is licensed under the MIT License.