-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Resize use Sizes but Scales is single #2451
Comments
This contradicts the statement OP highlighted in Operators.md, as the following section of code in the schema verification requires the input to be not |
That's right... Scales description describes it as optional input BUT it is not defined as one... Therefore right now the only way is to pass an empty tensor. Same goes with roi. Please check the tests for examples This op needs to be updated to make scales and roi as optional inputs. |
@askhade scales input if it's initializer type, it will not be able convert to tensorrt.
|
If I remember correctly, I made it non-optional intentionally because I didn't find a way to get whether an optional input is specified, instead, I could only check the input_size, so the "scales" must be specified even if it is not used. Please correct me if I'm wrong. |
Can we revisit updating this operator? Could we merge the sizes and scale inputs into one input and have an attribute tell the operator how to interpret the input? Then, the ROI input could be made optional. I feel that just by passing empty to these inputs is wasteful and makes the implementation for other backends of ONNX much harder. As a side note, the spec should not tell the user to pass an empty string when the inputs is required to be float type as @leroyzhao pointed out. |
is there a solution for this, I must set ROI it seems. the doc is a lie. I can't get this to work. if I don't set roi or scale, onnx will complain. and if I do set them I got
|
Closing this in favor of #3500 |
In the documentation, it is stated that sizes can be used as long as the name of scales is set to empty string.
However, after setting the name of scales to an empty string, the graph fails to load.
The error states that
input 2 is marked single but has an empty string in the graph
.The text was updated successfully, but these errors were encountered: