[torch_mlir.compile] Fixes issue with the https://github.com/llvm/torch-mlir/issues/1557

Signed-Off By: Vivek Khandelwal<vivek@nod-labs.com>
pull/1554/head
Vivek Khandelwal 2022-11-11 17:30:17 +05:30
parent dcff5a7150
commit d571d050fd
1 changed files with 1 additions and 1 deletions

View File

@ -172,7 +172,7 @@ class ExampleArgs:
if not isinstance(example_args, Sequence):
example_args = [example_args]
for arg in example_args:
if not isinstance(arg, _example_arg):
if not isinstance(arg, (TensorPlaceholder, torch.Tensor)):
raise Exception(f"Only Tensor's, TensorPlaceholder's, or sequences of "
f"Tensor's and TensorPlaceholder's are supported as "
f"example args for method inputs. "