Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"_jit_pass_onnx_function_substitution" was added in PT 1.6 #180

Closed
wants to merge 1 commit into from

Conversation

vdantu
Copy link

@vdantu vdantu commented Nov 23, 2020

Minor fix to pytorch parser. "_jit_pass_onnx_function_substitution" pass was added after PyTorch 1.5.1

Thanks for contributing to TVM! Please refer to guideline https://tvm.apache.org/docs/contribute/ for useful information and tips. After the pull request is submitted, please request code reviews from Reviewers by @ them in the pull request thread.

@vdantu vdantu changed the title [WIP] "_jit_pass_onnx_function_substitution" was added in PT 1.6 "_jit_pass_onnx_function_substitution" was added in PT 1.6 Nov 24, 2020
@@ -2714,7 +2714,7 @@ def _run_jit_passes(graph):
""" The inline pass is necessary to unwrap prim::CallMethod """
import torch

if _is_version_greater_than("1.5.0"):
if _is_version_greater_than("1.5.1"):

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fix will not work if the version string is of the form "1.5.1+cpu" or the like. The method _is_version_greater_than will return "1.5.1+cpu" is greater than "1.5.1" since that is what packaging.version.parse returns

@trevor-m
Copy link

trevor-m commented Dec 4, 2020

Closing since #181 has the same change from upstream

@trevor-m trevor-m closed this Dec 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants