Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions core/conversion/converters/impl/einsum.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ auto einsum_registrations TORCHTRT_UNUSED = RegisterNodeConversionPatterns().pat
auto equation = args[0].unwrapToString();
auto in = args[1].IValue()->toListRef();

TORCHTRT_CHECK(
in.size() <= 2,
"TensorRT currently supports up to 2 input tensors "
<< "to einsum but operation had " << in.size()
<< " input tensors, please specify torch_executed_ops=[\"aten::einsum\"] "
<< "at compilation time to avoid this error.");

std::vector<nvinfer1::ITensor*> tensors;

// Populate vector of ITensor pointers
Expand Down