[TensorRT EP] Clear constrain of trt plugin with different input type (#19044)

### Description
<!-- Describe your changes. -->
Add heterogeneous support to skip this check for TRT plugin which has
different input tensor types



### Motivation and Context
<!-- - Why is this change required? What problem does it solve?
- If it fixes an open issue, please link to the issue here. -->
This commit is contained in:
Yifan Li 2024-01-09 10:29:06 -08:00 committed by GitHub
parent ad6dd0a597
commit 574c7caf3a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -56,6 +56,14 @@ struct TensorRTCustomOp : Ort::CustomOpBase<TensorRTCustomOp, TensorRTCustomKern
OrtCustomOpInputOutputCharacteristic GetOutputCharacteristic(size_t) const { return OrtCustomOpInputOutputCharacteristic::INPUT_OUTPUT_VARIADIC; };
bool GetVariadicInputHomogeneity() const {
return false; // heterogenous
}
bool GetVariadicOutputHomogeneity() const {
return false; // heterogeneous
}
private:
const char* provider_{onnxruntime::kTensorrtExecutionProvider};
void* compute_stream_;