Skip to content

Commit c4c4cd7

Browse files
authored
Fix ONNX URLs (#252)
1 parent da450f6 commit c4c4cd7

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

docs/dev/benchmark.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ Here is sample data encoded as JSON:
104104
},
105105
"workload_metadata":{
106106
"class":"vision",
107-
"doc_url":"https://github.com/onnx/models/blob/master/vision/body_analysis/arcface/README.md",
107+
"doc_url":"https://github.com/onnx/models/blob/main/vision/body_analysis/arcface/README.md",
108108
"md5":"66074b860f905295aab5a842be57f37d",
109109
"opset":8,
110110
"type":"body_analysis",

python/tvm/relay/frontend/onnx.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -1518,7 +1518,7 @@ class LRN(OnnxOpConverter):
15181518
@classmethod
15191519
def _impl_v1(cls, inputs, attr, params):
15201520
"""LRN support only NCHW format
1521-
https://github.com/onnx/onnx/blob/master/docs/Operators.md#LRN
1521+
https://github.com/onnx/onnx/blob/main/docs/Operators.md#LRN
15221522
"""
15231523
axis = 1
15241524
alpha = attr.get("alpha", 0.0001)
@@ -1949,7 +1949,7 @@ def _impl_v8(cls, inputs, attr, params):
19491949
# However, ONNX Expand supports multi-directional broadcasting, which allows
19501950
# above pattern and also some extent of 'shape' can be smaller than the corresponding
19511951
# extent of 'input'. In this case, the extent of 'shape' must be 1.
1952-
# https://github.com/onnx/onnx/blob/master/docs/Broadcasting.md
1952+
# https://github.com/onnx/onnx/blob/main/docs/Broadcasting.md
19531953
# In above cases, we cannot directorly apply 'op.broadcast_to' instead of 'expand'
19541954
# so, here we solved this problem by expanding the given 'shape' itself.
19551955
def expand_shape(in_shape, shape):
@@ -3219,7 +3219,7 @@ def _get_convert_map(opset):
32193219

32203220
class GraphProto:
32213221
"""A helper class for handling Relay expression copying from pb2.GraphProto.
3222-
Definition: https://github.com/onnx/onnx/blob/master/onnx/onnx.proto
3222+
Definition: https://github.com/onnx/onnx/blob/main/onnx/onnx.proto
32233223
32243224
Parameters
32253225
----------

tests/python/contrib/test_bnns/test_onnx_topologies.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
TARGET = "llvm"
3535
INPUT_SHAPE = [1, 3, 224, 224]
3636

37-
BASE_MODEL_URL = "https://github.com/onnx/models/raw/master/"
37+
BASE_MODEL_URL = "https://github.com/onnx/models/raw/main/"
3838
MODEL_URL_COLLECTION = {
3939
"BERT": "text/machine_comprehension/bert-squad/model/bertsquad-10.onnx",
4040
"MobileNet-v2": "vision/classification/mobilenet/model/mobilenetv2-7.onnx",

tests/python/driver/tvmc/conftest.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ def pytorch_resnet18(tmpdir_factory):
147147

148148
@pytest.fixture(scope="session")
149149
def onnx_resnet50():
150-
base_url = "https://github.com/onnx/models/raw/master/vision/classification/resnet/model"
150+
base_url = "https://github.com/onnx/models/raw/main/vision/classification/resnet/model"
151151
file_to_download = "resnet50-v2-7.onnx"
152152
model_file = download_testdata(
153153
"{}/{}".format(base_url, file_to_download), file_to_download, module=["tvmc"]
@@ -158,7 +158,7 @@ def onnx_resnet50():
158158

159159
@pytest.fixture(scope="session")
160160
def onnx_mnist():
161-
base_url = "https://github.com/onnx/models/raw/master/vision/classification/mnist/model"
161+
base_url = "https://github.com/onnx/models/raw/main/vision/classification/mnist/model"
162162
file_to_download = "mnist-1.onnx"
163163
model_file = download_testdata(
164164
"{}/{}".format(base_url, file_to_download), file_to_download, module=["tvmc"]

tutorials/get_started/tvmc_command_line_driver.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
#
8888
# .. code-block:: bash
8989
#
90-
# wget https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet50-v2-7.onnx
90+
# wget https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet50-v2-7.onnx
9191
#
9292

9393

0 commit comments

Comments
 (0)