(shape: list[Any] | tuple[Any, ...])
| 713 | |
| 714 | |
| 715 | def make_shape(shape: list[Any] | tuple[Any, ...]) -> ShapeExpr: |
| 716 | if isinstance(shape, list | tuple): |
| 717 | return ShapeExpr(shape) |
| 718 | raise TypeError( |
| 719 | "make_shape expects a list or tuple of shape values, " |
| 720 | f"but received type {type(shape).__name__}" |
| 721 | ) |
| 722 | |
| 723 | |
| 724 | @tvm_ffi.register_object("relax.expr.Constant") |
searching dependent graphs…