Commit graph

6514 commits

Author SHA1 Message Date
Chi Lo
42d7112f03
Add multithreading test and put a lock on nvinfer1::createInferRuntime() for TRT EP (#10714)
* Add multithread unit test and put lock on library call

* update code

* remove debug code

* add comment

* add one session multi-threads inference

* Put lock for build engine all the time

* Update naming and comment

* remove unnecessary lock

* Revert "remove unnecessary lock"

This reverts commit 9c2317b1d2273dec0ebdeb52160bc757839e5edc.
2022-03-16 09:19:33 -07:00
Chi Lo
ce204d0744
Update to flatbuffers v2.0.0 (#10866) 2022-03-16 09:18:49 -07:00
Chun-Wei Chen
bac9c0eb50
skip optional related models from opset16 (#10840) (#10878) 2022-03-16 08:49:42 -07:00
PeixuanZuo
5763657715
[UPDATE] Add prefix in front of the file (#10884) 2022-03-16 21:05:18 +08:00
Valery Chernov
625a1f7673
[TVM EP] code refactor (#10655)
* rename info to options for TVM EP

* transfer options processing from TVMExecutionProvider to TVMEPOptions

* transfer TVMRunner to separated files

* implement TVMCompiler class

* replace CompileFunc by TVMCompiler object. update TVMRunner. now it does not depend on TvmExecutionProvider

* correct logging of TVM EP options

* RunnerImpl, GERunnerImpl and VMRunnerImpl were implemented

* add prepareComputeInfo method

* remove update_output_shapes flag

* embed all TVM EP dependences to tvm namespace. transfer model compilation from TVMRunner. connect TVMRunnerImpl to TVMRunner

* refactor compileModel method

* small cleaning

* separate TVM EP options data store and processing

* replace TvmTensorShape by InlinedVector with max_size 5

* correct indentation

* update TVM hash

Co-authored-by: Valery Chernov <valery.chernov@deelvin.com>
2022-03-16 13:55:04 +01:00
Edward Chen
f468ea40e5
Refactor Node::AddAttribute() (#10869) 2022-03-16 14:53:00 +10:00
PeixuanZuo
040c0645e2
[ADD] Add micro-benchmark for Cast (#10870)
* [ADD] Add micro-benchmark for Cast

* [UPDATE] related to bert model and fix the format
2022-03-16 10:48:26 +08:00
Sheil Kumar
860f28254e
Update DFT definition to more closely align with PyTorch by enabling axis attribute, and arbitrary tensor rank. (#10842)
* Add axis attribute

* fix breaks

* Enable axis-specified DFT

* remove static cast

Co-authored-by: Sheil Kumar <sheilk@microsoft.com>
2022-03-15 15:27:12 -07:00
Changming Sun
de6d1fcb41 Update C# runtest.sh 2022-03-15 14:18:34 -07:00
Chi Lo
aebbb90b79
Integrate C-API tests into Pipelines for release packages (#10794)
* add c-api test for package

* fix bug for running c-api test for package

* refine run application script

* remove redundant code

* include CUDA test

* Remove testing CUDA EP temporarily

* fix bug

* Code refactor

* try to fix YAML bug

* try to fix YAML bug

* try to fix YAML bug

* fix bug for multiple directories in Pipelines

* fix bug

* add comments and fix bug

* Update c-api-noopenmp-packaging-pipelines.yml

* Remove failOnStandardError flag in Pipelines
2022-03-15 10:18:38 -07:00
Nat Kershaw (MSFT)
2d961604b1
Refactor Python API docs to better explain IO binding scenarios (#10651) 2022-03-15 09:40:59 -07:00
Scott McKay
f385c73058
Fix a couple of issues with the python package tools (#10858)
* Tweaks to the model utils
  * Add handling for a dim_value of -1 when replacing the entire input shape. This occurs in models exported from PaddlePaddle
  * make pytorch helpers accessible in package
  * make QDQ helpers accessible in package
2022-03-15 15:52:12 +10:00
Hariharan Seshadri
0d8d44d035
Fix Reduced ops pipeline (#10861) 2022-03-14 20:42:14 -07:00
Rachel Guo
7e9dfe627a
Add additional NNAPI QDQ test cases for expected failure path (#10769)
* add more qdq softmax test case

* add rest of additional nnapi qdq test case

* comment out

* update

* update concat test case

* extract zp/scale point retrieval out

* fix

* fix helper function for scale/zp and address some pr comments

* use enum class expectedepnodeassignments

* fix default value for ExpectedEPNodeAssignment

* update

* refine some comments

* refine some minor comments

* refine pr comments

* update

Co-authored-by: rachguo <rachguo@rachguos-Mini.attlocal.net>
2022-03-14 19:22:22 -07:00
Edward Chen
e53422c6d0
Update convert_onnx_models_to_ort.py to support runtime optimizations. (#10765)
Add runtime optimization support to ONNX -> ORT format conversion script.
Replace `--optimization_level`, `--use_nnapi`, and `--use_coreml` with a new `--optimization_style` option.
2022-03-14 16:50:41 -07:00
Abhishek Jindal
03181caeae
Creating test case for printing ort tensor (#10850)
* creating a test for printing ort tensor

* modifying comment for error case

* Using Output Grabber to assert the print output

* modifying the print ort test

* removing comments

* removing sys import
2022-03-11 21:39:48 -08:00
Tiago Koji Castro Shibata
ce10d7d231 Workaround https://github.com/microsoft/STL/issues/434#issuecomment-921321254 2022-03-11 18:10:23 -08:00
Tiago Koji Castro Shibata
d1f059c856 Remove kernel32 defaultlib 2022-03-11 18:10:23 -08:00
Tiago Koji Castro Shibata
ddf1a312ab Remove cpuinfo from WCOS builds 2022-03-11 18:10:23 -08:00
Funtowicz Morgan
c4f73af234
Fix wrong percentile values returned during calibration (#10847)
* Use numpy.percentile to get the lookup value.

* Use 1.0 as float value rather than integer.

* Add missing cdf parameter for `np.percentile`.

* Use 100. instead of 1.0

* Remove print.

* Update from @yufenglee
2022-03-11 14:52:09 -08:00
Scott McKay
6ac3b8d46a
Add support for opset 16 to transpose optimizer. (#10841)
* Add support for opset 16 to transpose optimizer.

Only change required is for GridSample to be added to the layout sensitive ops. The existing handling for layout transpose works with that as the first input and first output are layout sensitive.

Update the optimize to be able to return an error message if it fails.
2022-03-12 08:50:55 +10:00
Changming Sun
2d2eebb844 Correct a comment
"WINVER=0x0602" means  Windows 8.  source: https://docs.microsoft.com/en-us/cpp/porting/modifying-winver-and-win32-winnt?view=msvc-170
2022-03-11 11:42:41 -08:00
Ryan Lai
2e7592ddf8
avoid using LocalFree on FormatMessageW buffer (#10796)
* remove local free

* Remove local free from onnxruntime

* don't allocate

* Change to use constexpr to satisfy  CPU build warning
2022-03-11 11:11:40 -08:00
Kotaro Yamamoto
64556888a1
add python binding for RunOptions config entry (#10694) 2022-03-11 08:49:22 -08:00
pengwa
d478a53d43
don't clear grad_fns & add test (#10671) 2022-03-11 14:31:54 +08:00
Edward Chen
1a62306db7
Use separate build directories for full and mobile iOS packages. (#10835) 2022-03-10 19:33:06 -08:00
Chun-Wei Chen
5202efd11e
remove unused six in code and CIs (#10832) 2022-03-10 15:38:44 -08:00
Changming Sun
f87a06cd96
Patch absl so that it doesn't disable important VC++ warnings (#10836)
This PR is just for making onnxruntime passing Binskim rules.

Below is how I made it:

git clone absl repo, checkout the version we are using
Then apply our patch file
Make modifications
Regenerate the patch file by "git diff > C:\src\onnxruntime\cmake\patch\xxx.patch"
Then submit the change to our repo
You will need to repeat the steps when you need to advance the absl commit or add more changes to it.
2022-03-10 15:35:39 -08:00
Pranav Sharma
97ae44d060
Mark end of version 11 C API. (#10803)
* Mark end of version 11 C API

* Add static_assert
2022-03-10 15:11:02 -08:00
Abhishek Jindal
3ae2bfaefe
Abjindal/torch api change gelu (#10833)
* changing gelu backward op and adding required files

* cleaning up file and adding comments

* version comparison issue
2022-03-10 11:56:30 -08:00
Dmitri Smirnov
1d545dfe87
Address performance issue with abseil flat_hash_table. (#10819)
When returning by value in a cross DLL call, the hash table
even though containing all the entries that are originally there
can not find at least some of them. Reverting to std::unordered_set
pending further investigation.
2022-03-10 09:49:55 -08:00
Hariharan Seshadri
e80ff63274
Fix bug in MemcpyToHost (#10816) 2022-03-10 07:02:27 -08:00
Ryan Hill
9853eaa14f
Detect runtime CUDA JIT and warn the user (#10781)
* Use cudaMalloc vs cudaDeviceSynchronize and show the total time
2022-03-09 19:15:16 -08:00
Changming Sun
cc3a3476ed
Uninstall onnxruntime-training before running local tests (#10827)
* Uninstall onnxruntime-training before running local tests
2022-03-09 18:45:04 -08:00
zhangyaobit
9cbcc93e03
Add micro-benchmarks for Attention and SkipLayerNormalization ops. (#10798)
* Add micro-benchmarks for Attention and SkipLayerNormalization ops.

* Add choices for argument provider and precision.

* Automatically select CUDA or ROCM execution provider.
2022-03-09 18:18:51 -08:00
Abhishek Jindal
1c313f4476
changing gelu backward op and adding required files (#10813)
* changing gelu backward op and adding required files

* cleaning up file and adding comments
2022-03-09 16:54:51 -08:00
Edward Chen
0293e525ea
Make QDQSelectorActionTransformer() is_int8_allowed parameter required. (#10820)
Make QDQSelectorActionTransformer() is_int8_allowed parameter required.
Set it to QDQIsInt8Allowed() in places it was previously set to false.
2022-03-09 16:19:43 -08:00
Changming Sun
cc6bc34c8c
Update protobuf submodule (#10801) 2022-03-09 09:37:58 -08:00
Dmitri Smirnov
58521fb822
Make training CUDA kernels to adhere established code structure patterns (#10735)
Current training optimizer kernels include CPU headers
  that affects changes that we can make in the CPU code with C++14 compiler and
  other refactoring efforts. Rearrange the kernel according to the established patterns
  and do not include headers that are not needed.
2022-03-09 09:06:45 -08:00
Adam Pocock
4ef81b142d
Making the Java tests faster by optionally disabling ones which require running multiple JVMs. (#10811) 2022-03-08 22:19:37 -08:00
Hariharan Seshadri
ae97ecf05b
Fix CPU, CUDA Selu activation logic (#10771) 2022-03-08 19:53:27 -08:00
Edward Chen
c147c9dda6
Remove ORT_ENABLE_RUNTIME_OPTIMIZATION_IN_MINIMAL_BUILD. (#10778)
Remove ORT_ENABLE_RUNTIME_OPTIMIZATION_IN_MINIMAL_BUILD as it is now implied by ORT_EXTENDED_MINIMAL_BUILD.
Remove related CMake option.
2022-03-08 16:18:49 -08:00
George Wu
769aa8363d
update onnx-tensorrt to bring in https://github.com/onnx/onnx-tensorrt/pull/812 (#10810) 2022-03-08 14:51:07 -08:00
Jingqiao Fu
f4fd67cc2c
Revert "add load from buffer (#10162)" (#10590)
This reverts commit 5cd57bb726.
2022-03-08 13:35:23 -08:00
dependabot[bot]
7e04dccca7
Bump numpy in /tools/ci_build/github/linux/docker/scripts (#10385)
Bumps [numpy](https://github.com/numpy/numpy) from 1.16.6 to 1.21.0.
- [Release notes](https://github.com/numpy/numpy/releases)
- [Changelog](https://github.com/numpy/numpy/blob/main/doc/HOWTO_RELEASE.rst.txt)
- [Commits](https://github.com/numpy/numpy/compare/v1.16.6...v1.21.0)

---
updated-dependencies:
- dependency-name: numpy
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-03-08 11:02:36 -08:00
Sunghoon
68c8f5a1ef
Change a pipeline vmImage from windows-latest to windows-2019 (#10804) 2022-03-08 10:49:59 -08:00
Yufeng Li
33c6819196
add qdq support of Sigmoid (#10800) 2022-03-08 10:29:15 -08:00
Changming Sun
6260733533
Fix eager mode pipeline (#10802)
It was still using python 3.6
2022-03-08 09:26:20 -08:00
Hariharan Seshadri
a9d9c6b486
Register CPU, CUDA and ROCM opset-16 kernels for some operators (#10643) 2022-03-08 09:18:39 -08:00
Changming Sun
ce07dc30fd
Change how we apply patches to absl (#10799) 2022-03-08 02:03:06 -08:00