I use TensorRT4.0
I convert my tensorflow frozen model into uff file. There is a plugin node ‘RPROI’. I implement it with the api function createFasterRCNNPlugin(…)
I know the RPROI plugin needs 4 inputs: rpn_cls, rpn_bbox_pred, convf, im_info. Supposing that the size of feature map I got is (1,256,80,80). And the anchors ratio number equals to 1, anchors scale number eaquals to 3, so that the k equals to 1*3=3. Please let me know what I understood below is right or not. Thanks.
- The order of the inputs like this, right?
RPROI = gs.create_node("name_RPROI",
op='plugin_rproi',
inputs=["name_cls", "name_box", "name_convf", "name_info"]
)
Because I have tried
inputs=["name_box", "name_cls", "name_info", "name_convf"]
or other order, and there is something wrong, so I want to know if it is needed to order like this, any other order?
- The size of rpn_cls is (1,2k,80,80) → (1,6,80,80), right?
Now I only got the score of foreground, so I have the rpn_cls with size (1,3,80,80). I want to change my (1,3,80,80) into (1,6,80,80) so I decide to add 38080 zeros(representing background score) into the vector. What I want to konw is the order of foreground scores and background scores. It should be like this? (Supposed the score of foreground I got is -1 -2 -3 -4 …)
-1 -2 -3 -4 .... 0 0 0 0 0 0 0.....
or like this?
0 0 0 0 0 0 ... -1 -2 -3 -4 ......
or like this?
-1 0 -2 0 -3 0 -4 0 ......
or like this?
0 -1 0 -2 0 -3 0 -4...
Is it necessary to make the range of these numbers between 0 and 1(that is softmax)? I wonder if this api can handle values that do not pass through softmax.
Does it just check the foreground scores of rpn_cls and ignore the background scores? If I fill the random number in the background, will it cause an error?
I know it shouldn’t be easy to fill in 0, but I just want to figure out how it works. I have other ways to get the right number to fill in instead of 0.