Commit graph

6739 commits

Author SHA1 Message Date
Changming Sun
3b16fb2000
Delete java-test-final-jar-step.yml (#8894) 2022-05-09 11:25:03 -07:00
Justin Chu
c541063245
Format coding conventions documentation (#11405)
Add proper formatting to code blocks to make the doc more readable.

- Wrap code blocks with `
- Fix typos
2022-05-09 10:19:15 -07:00
symphonylyh
c2de603c10
Contrib ops for TRT plugin: Disentangled Attention Plugin (#11287)
* Add disentangled attention TRT plugin as contrib op

* update plugin name & remove null character

* update onnx-tensorrt submodule with my beta version

* use suggested plugin name & simpler shape propagation

* update onnx-tensorrt gitsubmodule to temporary fork

* update onnx-tensorrt to temporary commit

* redirect submodule back to latest 8.2-GA release of onnx-tensorrt repo

Co-authored-by: HHH-ComputeLab <haohangh@nvidia.com>
2022-05-08 15:25:25 -07:00
George Wu
70e501866b
Revert "[TensorRT EP] reduce CI pipelines test execution time (#11440)" (#11460)
This reverts commit 8d6ade9e08.
2022-05-07 11:41:11 -07:00
Dwayne Robinson
69b2fab810
Update DirectML from 1.8.0 to 1.8.2 (#11459) 2022-05-06 17:52:52 -07:00
RandySheriffH
8467af832f
Fix reduced pipeline by excluding test case standalone op (#11458)
* exclude reduce build from standalone op test

* exclude test from reduced op build
2022-05-06 16:19:49 -07:00
Brian Popow
3624f7c5a5
Update samples (#11420) 2022-05-06 13:32:16 -07:00
Hubert Lu
2a90922f01
Using vectorized loads (float2) for fp16 to improve performance (#11390) 2022-05-05 14:19:21 -07:00
Changming Sun
d2ae0f49b2
Make Graph::InlineFunction be able to process initializers (#11443) 2022-05-05 12:30:29 -07:00
George Wu
8d6ade9e08
[TensorRT EP] reduce CI pipelines test execution time (#11440)
* add global builder placeholder to improve CI test time for TRT EP

* fix build error

* rename var, put in unnamed namespace

* fix build error

* fix
2022-05-05 09:25:54 -07:00
Tang, Cheng
3f3c5fcd68
Unify the Compile API for mobile build and normal build (#10632)
* use the lightweight compile api as default; use dnnl ep for testing

* apply to tensorrt ep

* fix the missing files

* fix build

* fix the copy issue on linux

* migrate migraphx and openvino ep

* fix openvino build break

* fix linux build

* fix unused parameter

* fix coreml build

* use graph view's filtered initializers

* fix openvino break

* fix tvm compile api

* fix tvm / rknpu / vitisai ep build

* add IsInitializedTensor in graph_viewer; fix nuphar build

* use serializer directly as tvm ep is still static lib

* fix the type mismatch

* fix the type mismatch

* fix merge conflict

* add a comment

* fix minimal build

* fix the DML EP's legacy approach

* save type/shape in dnnl IR

* fix linux break

* fix tvm failure

* dnnl ep: move initializer referenced out of dnnl subgraph

* Revert "add IsInitializedTensor in graph_viewer; fix nuphar build"

This reverts commit 1cc3c7f08c16fee4fe3309a67209eb769d479587.

* add IsInitializedTensor to graph viewer

* add the legacy code for nuphar build to temporarily make nuphar build work

* ignore internal test for nuphar

* remove the out of date tests

* keep the legacy API in EP for a while

* turn serializer into a static function

* update comments

* fix tvm build

* Update include/onnxruntime/core/framework/execution_provider.h

Co-authored-by: Pranav Sharma <prs@microsoft.com>

* Update include/onnxruntime/core/framework/execution_provider.h

Co-authored-by: Pranav Sharma <prs@microsoft.com>

* Update onnxruntime/core/framework/execution_provider.cc

Co-authored-by: Pranav Sharma <prs@microsoft.com>

* updatee comments; add warning message for legacy compil call

* add a flag to control out of scope arg in serialization

* fix trt  build; improve the test

* resolve merege errors

* fix a typo

Co-authored-by: Cheng Tang <chenta@microsoft.com>
Co-authored-by: Cheng Tang <chenta@microsoft.com@orttrainingdev9.d32nl1ml4oruzj4qz3bqlggovf.px.internal.cloudapp.net>
Co-authored-by: Pranav Sharma <prs@microsoft.com>
2022-05-05 08:30:07 -07:00
cloudhan
eca4cbc419
Avoid using word 'crazy' (#11396)
Avoid using word 'crazy' and simplify the comment of else branch
2022-05-05 23:07:50 +08:00
Valery Chernov
5ae461ec0a
[TVM EP] update set input to remove excess copying inside TVM (#11247)
* update TVM

* small fixes

* update TVM with new set_input and NDArray API

* use set_input instead of set_one_input

Co-authored-by: Valery Chernov <valery.chernov@deelvin.com>
2022-05-05 14:25:02 +02:00
Vincent Wang
084165c748
Change MinGrad/MaxGrad to Use Distributed Logic (#11388)
* change min max grad

* resolve comments
2022-05-05 11:49:40 +08:00
Yulong Wang
860ba8820b
[js/rn] fix ORTRN for iOS (#11425)
* align ios version with onnxruntime-mobile-c

* support 'file://' in iOS

* fix lint error
2022-05-04 13:58:55 -07:00
Changming Sun
963e1ace4e
Fix SAL annotations for custom op (#11432)
Fix SAL annotations for custom op. For example, "_In_" only applies to pointers, not integers.
2022-05-04 10:47:28 -07:00
Justin Chu
a1f9847b23
[Fix] Add the extra param to match gelu in PyTorch in the contrib symbolic function (#11318)
Description:

Add the extra param to match gelu in PyTorch in the contrib symbolic function

Motivation and Context

Why is this change required? What problem does it solve?
The symbolic function in /onnxruntime/python/tools/pytorch_export_contrib_ops.py is missing a recently added parameter approximate. We add this parameter and use the exporter defined gelu if approximate is "tanh".
2022-05-04 10:36:38 -07:00
Hariharan Seshadri
1aad59fa49
Increase timeout for IOS packaging pipeline (#11431) 2022-05-04 10:00:41 -07:00
Changming Sun
57b51e72d7
Linux CI: uninstall onnx before installing it (#11428) 2022-05-04 08:49:37 -07:00
Yulong Wang
af21a04977
[js] upgrade async@3.2.3 /js/ (#11421)
* [js] upgrade async@3.2.3 /js/

* format code
2022-05-03 23:41:36 -07:00
Sheil Kumar
85fa168dc1
Add optional dft_length input to the DFT and IDFT operators. (#11427)
* Add optional dft_length input.

* CR Feedback

Co-authored-by: Sheil Kumar <sheilk@microsoft.com>
2022-05-03 16:17:43 -07:00
Tang, Cheng
ae043e3963
Support ort device tensor in ortmodule's inference (#11112)
* support ort device tensor in ort module inference

* fallback aten equal to cpu; add ortmodule inference test case

* fix python format

Co-authored-by: Cheng Tang <chenta@microsoft.com@orttrainingdev9.d32nl1ml4oruzj4qz3bqlggovf.px.internal.cloudapp.net>
2022-05-03 14:28:30 -07:00
RandySheriffH
8d69b9398b
APIs for custom op to invoke ort operator directly (#10713)
* draft kernel creation

* setup eager context

* call into kernel in eager mode

* redefine test case

* refact eager context

* add comment

* remove header

* rename argument

* redefine API definition with types

* list outputs as argument

* switch to int to represent length

* fix compile err

* create attribute API

* add test case for topk

* remove bool from c api

* add gru test case

* remove var

* fix compile warnings

* rename status

* fix compile err

* exclude sparse tensor

* fix comments

* fix comments

* fix build err

* rename file and move location

* format code

* move file to session folder

* fix comments

Co-authored-by: Randy <Randy@randysmac.attlocal.net>
2022-05-03 14:16:30 -07:00
Yulong Wang
a3e38d7c90
[js] upgrade async@3.2.3 /js/web/ (#11426) 2022-05-03 14:04:22 -07:00
Changming Sun
253c8b41ed
Move some of the transpose kernel code to onnxruntime_framework.lib (#11380)
* Move some of the tranpose kernel code to onnxruntime_framework.lib

* Fix C4244 warnings in the tranpose code

* Rename IsMovingSingleAxis to IsTransposeMovingSingleAxis
2022-05-03 14:03:50 -07:00
Yulong Wang
308b605047
[wasm] increase timeout for Web Assembly static lib CI (#11306)
* [wasm] increase timeout for Web Assembly static lib CI

* update config format
2022-05-03 11:29:40 -07:00
Yulong Wang
d306e00351
[js/rn] set minSdkVersion to 21 for ORT-RN Android (#11403) 2022-05-02 19:36:41 -07:00
Changming Sun
5023f6750b
Revert "Call pluggable EP's shutdown function in Environment::~Environment() (#11120)" (#11393)
This reverts commit 4983d6e5d6. We can't destroy OrtEnv through python's atexit function, because at that time there might be many other ORT python objects alive.
2022-05-02 14:38:31 -07:00
Tianlei Wu
92cc1b4542
Update GPT2 notebook (#11371) 2022-05-02 12:27:48 -07:00
G. Ramalingam
024747bff4
Allow int32 as shape type (#11345)
Signed-off-by: Ganesan Ramalingam <grama@microsoft.com>
2022-05-02 10:10:30 -07:00
Olivia Jain
49d7050b88
Create Checkout Submodules Script (#11344)
* move all logic for ubuntu dockerfiles

* pass in trt version

* update trt 8.0 file

* downgrade protobuf

* uncomment

* and

* change to 8.0

* update dockerfiles

* checkout protobuf based on version

* adding last dockerfile:
:

* checkout 3.10 protobuf

* fix checkout version

* update to 8.2

* keep only one submodule sync

* cleanup

* Delete Dockerfile.custom-trt-perf

* create checkout submodules script

* properly compare decimals in bin/sh

* combine build ort paths

* deprecate TRT 7.2

* only checkout protobuf if we checkout older onnx-tensorrt

* only pull nvidia container if true, update image

* downgrade protobuf only if we checkout onnx-trt

* Update linux-gpu-tensorrt-daily-perf-pipeline.yml for Azure Pipelines

* Update linux-gpu-tensorrt-daily-perf-pipeline.yml for Azure Pipelines

* Add quotes to avoid path splitting

* address shellcheck

* use shellcheck suggestions
2022-04-29 13:04:26 -07:00
Olivia Jain
80a950cde1
Create OV EP Signing Pipeline (#11391)
* Create new pipeline to sign ov ep binaries

* make codesign available

* make codesign available

* Update sign_ov_ep_binaries.yml for Azure Pipelines

* Update sign_ov_ep_binaries.yml for Azure Pipelines

* add codesign task

* Update sign_ov_ep_binaries.yml for Azure Pipelines

* Update sign_ov_ep_binaries.yml for Azure Pipelines

* windows

* reduce timeout to 15 minutes
2022-04-29 10:54:37 -07:00
Tang, Cheng
4b875e3543
Re-implment the function support in onnxruntime (#11167)
* initial fix

* refactor the function handle

* update the implementation

* fix linux build break

* fix training build

* fix minmal build

* fix gradient checker

* deprecate the local function members in graph. host it in model

* fix changming's comments

* fix comments about inlined containers

* fix a missed inlined container

* fix training build

* avoid const for std string_view

Co-authored-by: Cheng Tang <chenta@microsoft.com>
2022-04-29 10:15:58 -07:00
Edward Chen
e194a01787
Update SafeInt version. (#11379) 2022-04-28 10:51:59 -07:00
Adrian Lizarraga
11e681f46a
[ep-perf] Fix the order of onnx and onnxruntime imports. (#11383)
Fix the order of onnx and onnxruntime imports. Importing onnx before onnxruntime causes a dependency issue in the tensorrt containers that prevents onnxruntime_pybind11_state.so from finding the system libstdc++. This is a workaround to get the EP Perf pipeline working until we can investigate the issue more closely.

Co-authored-by: Justin Chu <justinchuby@users.noreply.github.com>
2022-04-28 10:32:39 -07:00
Edward Chen
c6a3c149de
Fix formatting. (#11386) 2022-04-28 08:55:35 -07:00
mindest
c8270c2940
Add ATen export and gradient for torch.max/min (#11275)
* add aten export for max, max.dim

* rewrite grad of max (no dim); add cases for min

* update UT cases

* mod sym shape infer

* resolve comments: shape infer, add comments, etc.

* add test for torch.max of two tensors

* resolve peng's comments: keepdim; test case

* correct python format

* fix recently introduced lint error
2022-04-28 17:30:33 +08:00
Vincent Wang
1c64351e09
Create Tensor with Strides (#11294)
* create tensor with strides

* resolve comments

* refactor

Co-authored-by: Vincent Wang <weicwang@microsoft.com>
2022-04-28 16:49:37 +08:00
PeixuanZuo
6f218105ed
[FIX] amd ci pipeline timeout (#11387) 2022-04-28 14:32:36 +08:00
Scott McKay
833ded4b0e
Update setup.py to include config files used by model analysis in wheel. (#11381)
* Update setup.py to include config files used by model analysis in wheel.
2022-04-28 16:13:26 +10:00
Mina Asham
6cd1931a93
Specify list/map capacity when initializing where possible (#11110)
* Specify list/map capacity when initializing where possible

- This really depends on the use case, but in some cases the array/map resizing can be slightly costly, there is effectively no downside setting the initial capacity for a collection if we know for sure its final size

* Supply list/map capacity when initializing where possible

- This really depends on the use case, but in some cases the array/map resizing can be slightly costly, there is effectively no downside setting the initial capacity for a collection if we know for sure its final size
- Introduce an extra utility to help creating maps with expected capacity

* Move utility function to OrtUtil and drop MapUtil, also add Java doc to method

* Move test to the right class
2022-04-27 20:59:18 -07:00
Edward Chen
87a628a602
[NNAPI EP] Add support for PRelu op (#11303)
* Add OpBuilder/OpSupportChecker handling of PRelu.

* Register OpBuilder/OpSupportChecker for PRelu.
2022-04-28 12:31:17 +10:00
Ryan Hill
9e7753c109
Speed up GatherElements CPU Op (#11349)
* Specialize element copy by element size
2022-04-27 17:57:56 -07:00
Justin Chu
d64769c38e
Set black's target version (#11370)
Description: Set black's target version to be py37 - py310

Motivation and Context

Black by default targets its format for py3.10. Since our project supports python 3.7, we need to target version to all the python versions supported.

Re-ran black. 13 files reformatted.
2022-04-27 14:52:19 -07:00
Justin Chu
f6526af23d
Add LGTM config for c++ and c# (#11365)
Add LGTM config for c++, cs and java so that it can successfully built by lgtm.
2022-04-27 10:51:40 -07:00
Edward Chen
20ee399be4
Include layout transformation ops in extended minimal build and above. (#11355) 2022-04-27 10:31:02 -07:00
Olivia Jain
88ff48910d
Perf Bug Fix: Keep First Run for Random Input (#11366) 2022-04-27 09:17:49 -07:00
Dmitri Smirnov
a7d0158c24
Introduce a way to disable Abseil library (#11353)
Introduce a way to disable Abseil library.
Use cmake extra args, no new build switch.
2022-04-27 08:57:52 -07:00
Scott McKay
63d4f45186
Add stub implementation of the NNAPI interface (#11288)
* Add stub implementation of the NNAPI interface so that model builder code can be unit tested on all platforms.

Needed to fix a lot of type mismatch warnings. As these don't occur on Android builds used static_cast for simplicity.
2022-04-27 15:39:09 +10:00
Magnus1cheng
a937920e24
Update sequence_op.h (#11361)
Fix incorrect cudaMemcpyAsync kind in ConcatFromSequence Op.
2022-04-26 18:33:32 -07:00