Skip to content

OnnxToTorch bicubic interpolation #3802

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

Merged
merged 6 commits into from
Nov 12, 2024
Merged

OnnxToTorch bicubic interpolation #3802

merged 6 commits into from
Nov 12, 2024

Conversation

aldesilv
Copy link
Contributor

@aldesilv aldesilv commented Oct 17, 2024

(nod-ai/SHARK-TestSuite#391)
Repro (using SHARK TestSuite):

  1. python run.py --torchtolinalg -m cl-onnx-iree -t cubic_test

@aldesilv aldesilv force-pushed the cubic branch 5 times, most recently from 5635202 to 71487e6 Compare October 23, 2024 18:15
@aldesilv aldesilv force-pushed the cubic branch 5 times, most recently from f4c442b to f718e52 Compare November 6, 2024 18:42
@aldesilv aldesilv marked this pull request as ready for review November 8, 2024 16:59
Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

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

Hey, Alex. Looking this over, I have an idea that might resolve the numerical issues. Do you mind taking a look?

Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

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

More comments!

@aldesilv aldesilv force-pushed the cubic branch 2 times, most recently from 1ed2b47 to a4d7d79 Compare November 8, 2024 20:43
Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

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

Before making changes, check out the suggestions for fixing the numerics in aldesilv#3.

Besides the suggestions in that PR, and the comments in this review, I'd generally like more comments in this code. Where does this implementation come from? What assumptions did we make?

To anyone who doesn't have context on cubic interpolation, this code would be completely inscrutable.

@aldesilv aldesilv force-pushed the cubic branch 2 times, most recently from b5519b8 to 2dfcc1c Compare November 11, 2024 23:57
Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

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

Great! One small change and should be good to go.

It might also be a good idea to rework some of the function signatures to take const references to avoid making unnecessary copies.

Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

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

LGTM

@zjgarvey zjgarvey merged commit 889a836 into llvm:main Nov 12, 2024
3 checks passed
rahuls-cerebras added a commit that referenced this pull request Jan 3, 2025
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.

2 participants