Skip to content

Commit

Permalink
Fix ONNX URLs (#252)
Browse files Browse the repository at this point in the history
  • Loading branch information
apivovarov authored May 6, 2022
1 parent da450f6 commit c4c4cd7
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion docs/dev/benchmark.rst
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ Here is sample data encoded as JSON:
},
"workload_metadata":{
"class":"vision",
"doc_url":"https://github.com/onnx/models/blob/master/vision/body_analysis/arcface/README.md",
"doc_url":"https://github.com/onnx/models/blob/main/vision/body_analysis/arcface/README.md",
"md5":"66074b860f905295aab5a842be57f37d",
"opset":8,
"type":"body_analysis",
Expand Down
6 changes: 3 additions & 3 deletions python/tvm/relay/frontend/onnx.py
Original file line number Diff line number Diff line change
Expand Up @@ -1518,7 +1518,7 @@ class LRN(OnnxOpConverter):
@classmethod
def _impl_v1(cls, inputs, attr, params):
"""LRN support only NCHW format
https://github.com/onnx/onnx/blob/master/docs/Operators.md#LRN
https://github.com/onnx/onnx/blob/main/docs/Operators.md#LRN
"""
axis = 1
alpha = attr.get("alpha", 0.0001)
Expand Down Expand Up @@ -1949,7 +1949,7 @@ def _impl_v8(cls, inputs, attr, params):
# However, ONNX Expand supports multi-directional broadcasting, which allows
# above pattern and also some extent of 'shape' can be smaller than the corresponding
# extent of 'input'. In this case, the extent of 'shape' must be 1.
# https://github.com/onnx/onnx/blob/master/docs/Broadcasting.md
# https://github.com/onnx/onnx/blob/main/docs/Broadcasting.md
# In above cases, we cannot directorly apply 'op.broadcast_to' instead of 'expand'
# so, here we solved this problem by expanding the given 'shape' itself.
def expand_shape(in_shape, shape):
Expand Down Expand Up @@ -3219,7 +3219,7 @@ def _get_convert_map(opset):

class GraphProto:
"""A helper class for handling Relay expression copying from pb2.GraphProto.
Definition: https://github.com/onnx/onnx/blob/master/onnx/onnx.proto
Definition: https://github.com/onnx/onnx/blob/main/onnx/onnx.proto
Parameters
----------
Expand Down
2 changes: 1 addition & 1 deletion tests/python/contrib/test_bnns/test_onnx_topologies.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
TARGET = "llvm"
INPUT_SHAPE = [1, 3, 224, 224]

BASE_MODEL_URL = "https://github.com/onnx/models/raw/master/"
BASE_MODEL_URL = "https://github.com/onnx/models/raw/main/"
MODEL_URL_COLLECTION = {
"BERT": "text/machine_comprehension/bert-squad/model/bertsquad-10.onnx",
"MobileNet-v2": "vision/classification/mobilenet/model/mobilenetv2-7.onnx",
Expand Down
4 changes: 2 additions & 2 deletions tests/python/driver/tvmc/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def pytorch_resnet18(tmpdir_factory):

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

@pytest.fixture(scope="session")
def onnx_mnist():
base_url = "https://github.com/onnx/models/raw/master/vision/classification/mnist/model"
base_url = "https://github.com/onnx/models/raw/main/vision/classification/mnist/model"
file_to_download = "mnist-1.onnx"
model_file = download_testdata(
"{}/{}".format(base_url, file_to_download), file_to_download, module=["tvmc"]
Expand Down
2 changes: 1 addition & 1 deletion tutorials/get_started/tvmc_command_line_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
#
# .. code-block:: bash
#
# wget https://github.com/onnx/models/raw/master/vision/classification/resnet/model/resnet50-v2-7.onnx
# wget https://github.com/onnx/models/raw/main/vision/classification/resnet/model/resnet50-v2-7.onnx
#


Expand Down

0 comments on commit c4c4cd7

Please sign in to comment.