Description
I customized a plugin reflectPad, which supports dynamic input, but an error was reported in GetOutputDimensions()
my code:
DimsExprs ReflectPadPlugin::getOutputDimensions(
int outputIndex, const DimsExprs *inputs, int nbInputs, IExprBuilder &exprBuilder)
{
assert(inputs[0].nbDims == 4);
DimsExprs output(inputs[0]);
output.d[2] = exprBuilder.constant(inputs[0].d[2]->getConstantValue() + mPadT + mPadB); // Segmentation fault
output.d[3] = exprBuilder.constant(inputs[0].d[3]->getConstantValue() + mPadL + mPadR);
return output;
}
I cannot use exprBuilder.contant(error occurred: Segmentation fault) and exprBuilder.operation(error occurred: double free) normally
please help me! I can’t complete any custom ops right now. Thank you!
Environment
TensorRT Version: v8.2.0.6
GPU Type: RTX 2080TI
Nvidia Driver Version: 460.80
CUDA Version: 11.2
CUDNN Version:
Operating System + Version: ubuntu 18.04
Python Version (if applicable):
TensorFlow Version (if applicable):
PyTorch Version (if applicable):
Baremetal or Container (if container which image + tag):