How to deal with different height and weight use uffssdsample?

cuda 9.0
Following the sampleUffSSD, we need to modify the file to fit our ssd model. My ssd model use the size of 360*640.

Input = gs.create_node(“Input”,
shape=[1, 3, 360, 640]) # batch, channels, height, width
PriorBox = gs.create_plugin_node(name=“GridAnchor”, op=“GridAnchor_TRT”,
aspectRatios=[1.0, 2.0, 0.5, 3.0, 0.33],
featureMapShapes = [23, 12, 6, 3, 2, 1])

Here is my But I don’t know how to set the featureMapShapes with different h and w? In the NvInferPlugin.h, we can find some parameters definition about the struct GridAnchorParameters, but there is no featureMapShapes parameter.

struct GridAnchorParameters
float minSize, maxSize;
float* aspectRatios;
int numAspectRatios, H, W;
float variance[4];

//! \param param Set of parameters for creating the PriorBox plugin layer.
//! \deprecated. This plugin is superseded by createPriorBoxPlugin()
TENSORRTAPI INvPlugin* createSSDPriorBoxPlugin(PriorBoxParameters param);
TENSORRTAPI INvPlugin* createSSDPriorBoxPlugin(const void* data, size_t length);

Please tell me how to set the featureMapShapesH and featureMapShapesW? The problem has been asked, but there is no solution.If GridAnchor_TRT operation dose not support setting different h and w featureMapShapes please tell me clearly, I won’t waste my time on that. Thank you very much.

For sampleUffSSD it’s not possible to make an input of other size than 300x300 as of right now without changing a whole architecture of the network in the demo.

I’ve trained the model of my datasets and set the input image size to 360*640 use tensorflow detection api. This model is testing well and detection results are all right use tensorflow.
Problems arise after the use of tensorRT to accelerate the model. In ‘’ the featureMapShapes parameters must correspond to my new model but I don’t know how to set the the featureMapShapes with different h and w. For sampleUffSSD the size of the featureMapShapes is square(height=width ) and just need to set one number(h or w) for every layer. Now I need set two numbers(h and w) for every layer. Please tell me how to do it.