fasterrcnn plugin in Python


Is it possible to use createFasterRCNNPlugin in Python? Or is there any plan to add this plugin in python later?

I just found a basic example about add fullyconnected plugin layer in example folder after I installed python version of TensorRT-3.0.0, so now we can move the plugin layer in c++ to src folder, and compile somehow to make a python plugin layer, but I am still wondering if the createFasterRCNNPlugin can be converted into python in the same way?

Just finished implementing given Python FullyconnectedpluginFactory, and want to add reshape layer and fasterrcnn plugin in sampleFasterRCNN into src folder, a lot errors comes out because of smart pointer(unique_ptr).

Why the unique_ptr was replaced by normal pointer, is that necessary when we convert custom layer into python?

Good new, after changing smart pointer to normal pointer, I finished converting reshape layer and createFasterRCNNplugin into python, and I tired to build fasterrcnn in python. One error came out at first because tensorrt always check whether the output dimension is 3(CHW) everytime, so I modified the source code in (from to_CHW to to_NCHW), then another segment fault error came out, I guess that is because tensorrt always add one more dimension for batch, is there any hints about this?

Here is the error log:
[TensorRT] INFO: --------------- Timing (9)
[TensorRT] INFO: Tactic 0 time 0.009056
[TensorRT] INFO: Adding reformat layer: cls_prob output to be reformatted 0 (cls_prob) from Float(1,1,21,4200) to Float(1,1,1,21,4200)
[TensorRT] INFO: After reformat layers: 74 layers
[TensorRT] INFO: Block size 7372800
[TensorRT] INFO: Block size 1048576
[TensorRT] INFO: Block size 409600
[TensorRT] INFO: Block size 24576
[TensorRT] INFO: Block size 12288
[TensorRT] INFO: Block size 4096
[TensorRT] INFO: Total Activation Memory: 8871936
Segmentation fault (core dumped)

Finally, the error is due to MAX_WORKSPACE_SIZE is not set properly, the engine can be built successfully now, but more inference experiment need to be done later.

The result calculated by python-createFasterRCNN is completely wrong

Finally, the error was im_info also must be float.



Hello zhjqyzhjqy,

Thanks for the nice work.
Is it possible to share the code?