Code Monkey home page Code Monkey logo

Comments (6)

justinchuby avatar justinchuby commented on May 25, 2024

I think GridSample has been updated to support ND inputs (https://onnx.ai/onnx/operators/onnx__GridSample.html). To help me understand better, was your intention to support a range of input ranks during shape validation? What would this enable?

from onnx.

ZelboK avatar ZelboK commented on May 25, 2024

I think GridSample has been updated to support ND inputs (https://onnx.ai/onnx/operators/onnx__GridSample.html). To help me understand better, was your intention to support a range of input ranks during shape validation? What would this enable?

Yes your understanding is correct.

https://github.com/microsoft/onnxruntime/blob/3fb8905393bf91d97eae7afa0ae341828e3f1dbc/onnxruntime/core/graph/contrib_ops/contrib_defs.cc#L1044

If you look here, the logic is that it'll throw an error if you try to pass it input with anything but 4 dimensions. ORT is interested into extending this feature to support 5D, so (if my understanding is correct), this will need to change a bit to account for both 4D and 5D being valid inputs. If an operator is interested in supporting ND, would it not be helpful to have this validation?

Keep in mind this is a really small detail and I figured it was worth making a PR. I am still learning both ORT and ONNX - this isn't required functionality but I was mostly curious to see if it offered any utility. If I'm missing some context, please lmk and I can close both this PR and issue.

from onnx.

justinchuby avatar justinchuby commented on May 25, 2024

Thanks for the clarification. The new grid sample is going to support dimensions >5 as well, at least according to the spec. So specifying a range seems to be runtime specific. I would recommend adding this function only when it is needed for inferring shapes for onnx domain operations defined in this repository, to keep the APIs lean. Please correct me if there's anything I overlooked.

from onnx.

ZelboK avatar ZelboK commented on May 25, 2024

Thanks for the clarification. The new grid sample is going to support dimensions >5 as well, at least according to the spec. So specifying a range seems to be runtime specific. I would recommend adding this function only when it is needed for inferring shapes for onnx domain operations defined in this repository, to keep the APIs lean. Please correct me if there's anything I overlooked.

Sounds good, I don't think you've missed anything. Would you prefer this PR closed then?

(Tangential) can you point to some cxx related issues I can contribute towards if any exist? :)

from onnx.

justinchuby avatar justinchuby commented on May 25, 2024

Sounds good, I don't think you've missed anything. Would you prefer this PR closed then?

Yes. I think it's good to close it for now. Your contribution is appreciated still :)

(Tangential) can you point to some cxx related issues I can contribute towards if any exist? :)

Absolutely! Here is a list of issues that would welcome contributions: https://github.com/onnx/onnx/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3A%22contributions+welcome%22

Some c++ related ones are:

Etc.

from onnx.

ZelboK avatar ZelboK commented on May 25, 2024

Sounds good, I don't think you've missed anything. Would you prefer this PR closed then?

Yes. I think it's good to close it for now. Your contribution is appreciated still :)

(Tangential) can you point to some cxx related issues I can contribute towards if any exist? :)

Absolutely! Here is a list of issues that would welcome contributions: https://github.com/onnx/onnx/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3A%22contributions+welcome%22

Some c++ related ones are:

Etc.

Much appreciated! I'll look into one of those :D

from onnx.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.