Skip to content

Conversation

@liquanfeng
Copy link
Contributor

Fix #14926 .
The input should be normalized with the provided running mean and running variance instead of computing the mean and variance from the input data when use_input_stats is set to false.

@tvm-bot
Copy link
Collaborator

tvm-bot commented May 26, 2023

Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.

Generated by tvm-bot

data = inputs[0]
data_type = input_types[0]
channels = self.infer_shape(data)
running_mean = inputs[3]

Choose a reason for hiding this comment

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

Is this a most recent api change from pytorch or a long ignored params on our side? The former will need us to think about BC.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The latter I think. The "track_running_stats" has been ignored in the unit test.
By the way, there will be another PR later about BC, also on a similar issue.

@masahi masahi merged commit 5f1421d into apache:main May 27, 2023
@liquanfeng liquanfeng deleted the in branch May 27, 2023 11:13
mei-ye pushed a commit to mei-ye/tvm that referenced this pull request Jun 1, 2023
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.

[Bug] [Relay] attribute track_running_stats of InstanceNorm lead to wrong inference results

4 participants