Lunderberg opened a new pull request, #17323: URL: https://github.com/apache/tvm/pull/17323
The `Function.bind_params` method requires all bound values to have `StructInfo` annotations. While these are generated on construction for `relax::Constant` and `relax::PrimValue`, the most common cases of bound values, other useful expression such as `relax.op.zeros(shape,dtype)` do not have `StructInfo` until they are normalized. In addition, because `Function.bind_params` may be used in contexts that do not have a `relax.BlockBuilder` available, performing this normalization is not straightforward. This commit updates the constructors for Relax operations within the `tvm.relax.op.create` namespace to infer their `StructInfo` on construction, if it is possible to do so. This allows these operations to be used inside `Function.bind_params`. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
