Skip to content

Commit de0e87e

Browse files
authored
1.16.3 patch release (#18491)
Cherry-pick the following PRs: #18467 #17797 #18341 #18456
1 parent 0c5b95f commit de0e87e

File tree

90 files changed

+230
-226
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+230
-226
lines changed

.lintrunner.toml

-27
Original file line numberDiff line numberDiff line change
@@ -97,33 +97,6 @@ init_command = [
9797
]
9898
is_formatter = true
9999

100-
[[linter]]
101-
code = 'PYLINT'
102-
include_patterns = [
103-
# TODO: Opt in to pylint by adding paths here
104-
]
105-
exclude_patterns = [
106-
]
107-
command = [
108-
'python',
109-
'-m',
110-
'lintrunner_adapters',
111-
'run',
112-
'pylint_linter',
113-
'--rcfile=pyproject.toml',
114-
'--',
115-
'@{{PATHSFILE}}'
116-
]
117-
init_command = [
118-
'python',
119-
'-m',
120-
'lintrunner_adapters',
121-
'run',
122-
'pip_init',
123-
'--dry-run={{DRYRUN}}',
124-
'--requirement=requirements-lintrunner.txt',
125-
]
126-
127100
[[linter]]
128101
code = 'RUSTFMT'
129102
include_patterns = ['**/*.rs']

VERSION_NUMBER

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.16.2
1+
1.16.3

docs/python/README.rst

+5
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ For more information on ONNX Runtime, please see `aka.ms/onnxruntime <https://ak
88
Changes
99
-------
1010

11+
1.16.3
12+
^^^^^^
13+
14+
Release Notes : https://github.com/Microsoft/onnxruntime/releases/tag/v1.16.3
15+
1116
1.16.2
1217
^^^^^^
1318

include/onnxruntime/core/platform/EigenNonBlockingThreadPool.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@ class ThreadPoolProfiler {
278278
int num_threads_;
279279
#ifdef _MSC_VER
280280
#pragma warning(push)
281-
// C4324: structure was padded due to alignment specifier
281+
// C4324: structure was padded due to alignment specifier
282282
#pragma warning(disable : 4324)
283283
#endif // _MSC_VER
284284
struct ORT_ALIGN_TO_AVOID_FALSE_SHARING ChildThreadStat {

js/common/lib/version.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
// This file is generated by /js/scripts/update-version.ts
55
// Do not modify file content manually.
66

7-
export const version = '1.16.2';
7+
export const version = '1.16.3';

js/common/package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js/common/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"license": "MIT",
33
"type": "module",
44
"name": "onnxruntime-common",
5-
"version": "1.16.2",
5+
"version": "1.16.3",
66
"repository": {
77
"url": "https://github.com/Microsoft/onnxruntime.git",
88
"type": "git"

js/node/lib/version.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
// This file is generated by /js/scripts/update-version.ts
55
// Do not modify file content manually.
66

7-
export const version = '1.16.2';
7+
export const version = '1.16.3';

js/node/package-lock.json

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js/node/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
3
1414
]
1515
},
16-
"version": "1.16.2",
16+
"version": "1.16.3",
1717
"dependencies": {
1818
"onnxruntime-common": "file:../common"
1919
},

js/react_native/lib/version.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
// This file is generated by /js/scripts/update-version.ts
55
// Do not modify file content manually.
66

7-
export const version = '1.16.2';
7+
export const version = '1.16.3';

js/react_native/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"registry": "https://registry.npmjs.org/"
3737
},
3838
"source": "lib/index",
39-
"version": "1.16.2",
39+
"version": "1.16.3",
4040
"main": "dist/commonjs/index",
4141
"homepage": "https://github.com/microsoft/onnxruntime/blob/main/js/react_native/README.md",
4242
"files": [

js/react_native/yarn.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -5188,7 +5188,7 @@ onetime@^5.1.0, onetime@^5.1.2:
51885188
mimic-fn "^2.1.0"
51895189

51905190
"onnxruntime-common@file:../common":
5191-
version "1.16.2"
5191+
version "1.16.3"
51925192

51935193
open@^6.2.0:
51945194
version "6.4.0"

js/web/lib/version.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
// This file is generated by /js/scripts/update-version.ts
55
// Do not modify file content manually.
66

7-
export const version = '1.16.2';
7+
export const version = '1.16.3';

js/web/package-lock.json

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js/web/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"type": "git"
99
},
1010
"author": "fs-eire",
11-
"version": "1.16.2",
11+
"version": "1.16.3",
1212
"jsdelivr": "dist/ort.min.js",
1313
"dependencies": {
1414
"flatbuffers": "^1.12.0",

onnxruntime/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
For more information on ONNX Runtime, please see `aka.ms/onnxruntime <https://aka.ms/onnxruntime/>`_
88
or the `Github project <https://github.com/microsoft/onnxruntime/>`_.
99
"""
10-
__version__ = "1.16.2"
10+
__version__ = "1.16.3"
1111
__author__ = "Microsoft"
1212

1313
# we need to do device version validation (for example to check Cuda version for an onnxruntime-training package).

onnxruntime/core/framework/session_state_utils.cc

+1-2
Original file line numberDiff line numberDiff line change
@@ -455,11 +455,10 @@ common::Status SaveInputOutputNamesToNodeMapping(const onnxruntime::GraphViewer&
455455
// utils::CopyOneInputAcrossDevices is happy.
456456

457457
auto& input_map = session_state.GetInputNodeInfoMap();
458-
auto end_map = input_map.cend();
459458

460459
for (const auto& graph_input : graph_inputs) {
461460
const auto& name = graph_input->Name();
462-
if (input_map.find(name) == end_map) {
461+
if (input_map.find(name) == input_map.cend()) {
463462
// dummy entry for an input that we didn't find a use of in the graph. log it in case that's a bug.
464463
// utils::CopyOneInputAcrossDevices will use the input OrtValue as is given we don't believe it's used anywhere.
465464
LOGS(session_state.Logger(), INFO) << (graph.IsSubgraph() ? "Subgraph" : "Graph") << " input with name "

onnxruntime/core/providers/tensorrt/tensorrt_execution_provider.cc

+5
Original file line numberDiff line numberDiff line change
@@ -1126,6 +1126,11 @@ TensorrtExecutionProvider::~TensorrtExecutionProvider() {
11261126
}
11271127
}
11281128

1129+
if (external_stream_) {
1130+
ORT_IGNORE_RETURN_VALUE(CUBLAS_CALL(cublasDestroy(external_cublas_handle_)));
1131+
ORT_IGNORE_RETURN_VALUE(CUDNN_CALL(cudnnDestroy(external_cudnn_handle_)));
1132+
}
1133+
11291134
if (!external_stream_ && stream_) {
11301135
ORT_IGNORE_RETURN_VALUE(CUDA_CALL(cudaStreamDestroy(stream_)));
11311136
}

onnxruntime/core/session/onnxruntime_c_api.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -2744,7 +2744,7 @@ static_assert(offsetof(OrtApi, GetBuildInfoString) / sizeof(void*) == 254, "Size
27442744
static_assert(offsetof(OrtApi, KernelContext_GetResource) / sizeof(void*) == 265, "Size of version 16 API cannot change");
27452745

27462746
// So that nobody forgets to finish an API version, this check will serve as a reminder:
2747-
static_assert(std::string_view(ORT_VERSION) == "1.16.2",
2747+
static_assert(std::string_view(ORT_VERSION) == "1.16.3",
27482748
"ORT_Version change detected, please follow below steps to ensure OrtApi is updated properly");
27492749
// 1. Update the hardcoded version string in above static_assert to silence it
27502750
// 2. If there were any APIs added to ort_api_1_to_16 above:

onnxruntime/python/backend/backend.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ def is_opset_supported(cls, model):
6363
error_message = (
6464
"Skipping this test as only released onnx opsets are supported."
6565
"To run this test set env variable ALLOW_RELEASED_ONNX_OPSET_ONLY to 0."
66-
" Got Domain '{}' version '{}'.".format(domain, opset.version)
66+
f" Got Domain '{domain}' version '{opset.version}'."
6767
)
6868
return False, error_message
6969
except AttributeError:
@@ -74,7 +74,7 @@ def is_opset_supported(cls, model):
7474
error_message = (
7575
"Skipping this test as only released onnx opsets are supported."
7676
"To run this test set env variable ALLOW_RELEASED_ONNX_OPSET_ONLY to 0."
77-
" Got Domain '{}' version '{}'.".format(domain, opset.version)
77+
f" Got Domain '{domain}' version '{opset.version}'."
7878
)
7979
return False, error_message
8080
return True, ""

onnxruntime/python/tools/onnxruntime_test.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def generate_feeds(sess, symbolic_dims: dict | None = None):
4040
if not dim:
4141
# unknown dim
4242
shape.append(1)
43-
elif type(dim) == str:
43+
elif isinstance(dim, str):
4444
# symbolic dim. see if we have a value otherwise use 1
4545
if dim in symbolic_dims:
4646
shape.append(int(symbolic_dims[dim]))

onnxruntime/python/tools/profile_explorer/profile_explorer.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,8 @@ def _shape_to_string(shape):
8282
for dict_obj in shape:
8383
if len(dict_obj) > 1:
8484
raise ValueError("Unhandled type in _shape_to_string()")
85-
key = list(dict_obj.keys())[0]
86-
value = list(dict_obj.values())[0]
85+
key = next(iter(dict_obj.keys()))
86+
value = next(iter(dict_obj.values()))
8787
if len(res) != 0:
8888
res += ","
8989
res += f'{key}({"x".join(str(v) for v in value)})'

onnxruntime/python/tools/quantization/calibrate.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -363,9 +363,9 @@ def compute_data(self) -> TensorsData:
363363
else:
364364
min_value_array = min(merged_added_output_dict[added_output_names[i]])
365365
max_value_array = max(merged_added_output_dict[added_output_names[i + 1]])
366-
if type(min_value_array) == int or min_value_array.size > 0:
366+
if isinstance(min_value_array, int) or min_value_array.size > 0:
367367
min_value = float(min_value_array)
368-
if type(max_value_array) == int or max_value_array.size > 0:
368+
if isinstance(max_value_array, int) or max_value_array.size > 0:
369369
max_value = float(max_value_array)
370370

371371
if self.symmetric:

onnxruntime/python/tools/quantization/onnx_quantizer.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,7 @@ def _get_quantization_params(self, param_name, use_scale=None, use_zeropoint=Non
597597
if params is None or len(params) != 2:
598598
raise ValueError(
599599
"Quantization parameters should contain zero point and scale. "
600-
"Specified values for output {}: {}".format(param_name, params)
600+
f"Specified values for output {param_name}: {params}"
601601
)
602602

603603
zero_point_values = [params["zero_point"]]

0 commit comments

Comments
 (0)