-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Transform] Remove R.Object parameters after LazyTransformParams (#16699
) * [Transform] Remove R.Object parameters after LazyTranformParams Prior to this commit, the output of `relax.transform.LazyTransformParams` would include all parameters that are not `R.Tensor`, in case they defined symbolic variables. However, this added too many unnecessary parameters, such as `R.Object` which cannot define symbolic variables. This commit updates `relax.transform.LazyTransformParams` to only retain `R.Prim` and `R.Shape` parameters, which can define symbolic variables. * [TVMScript][Bugfix] Check for StructInfoProxy in R.match_cast Prior to this commit, bare `StructInfoProxy` annotations could be used to annotate variables (e.g. `var: R.Tensor`). However, they could not be used as the argument of a match cast (e.g. `R.match_cast(obj, R.Tensor)`). This breaks round-trips, as the `R.match_cast` printing generates base `StructInfoProxy` objects. This commit updates TVMScript parsing to handle bare `StructInfoProxy` annotations as an argument to `R.match_cast`.
- Loading branch information
1 parent
05e218c
commit 831d769
Showing
5 changed files
with
97 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters