[GitHub] precedenceguo commented on a change in pull request #9939: add multi proposal operator (cpu version) and fix the bug in proposal op (gpu version)

2018-03-06 Thread GitBox
precedenceguo commented on a change in pull request #9939: add multi proposal 
operator (cpu version) and fix the bug in proposal op (gpu version)
URL: https://github.com/apache/incubator-mxnet/pull/9939#discussion_r172564668
 
 

 ##
 File path: src/operator/contrib/proposal.cu
 ##
 @@ -553,10 +553,10 @@ class ProposalGPUOp : public Operator{
 cudaMemcpyHostToDevice));
 
 // copy results after nms
-dimGrid.x = (rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
+dimGrid.x = (param_.rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
 
 Review comment:
   I think it is a good idea but I did not find significant issue of the 
invalid anchors.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] precedenceguo commented on a change in pull request #9939: add multi proposal operator (cpu version) and fix the bug in proposal op (gpu version)

2018-03-03 Thread GitBox
precedenceguo commented on a change in pull request #9939: add multi proposal 
operator (cpu version) and fix the bug in proposal op (gpu version)
URL: https://github.com/apache/incubator-mxnet/pull/9939#discussion_r172034936
 
 

 ##
 File path: src/operator/contrib/proposal.cu
 ##
 @@ -553,10 +553,10 @@ class ProposalGPUOp : public Operator{
 cudaMemcpyHostToDevice));
 
 // copy results after nms
-dimGrid.x = (rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
+dimGrid.x = (param_.rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
 
 Review comment:
   Yes, they should be thrown out; but that would require a new array. Instead 
I set the predicted confidence to be -1, same as the boxes whose centers are 
out of the input image boundary. Those invalid anchors would be ranked to the 
bottom for NMS so a proper threshold did not produce significant problems.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] precedenceguo commented on a change in pull request #9939: add multi proposal operator (cpu version) and fix the bug in proposal op (gpu version)

2018-03-03 Thread GitBox
precedenceguo commented on a change in pull request #9939: add multi proposal 
operator (cpu version) and fix the bug in proposal op (gpu version)
URL: https://github.com/apache/incubator-mxnet/pull/9939#discussion_r172034936
 
 

 ##
 File path: src/operator/contrib/proposal.cu
 ##
 @@ -553,10 +553,10 @@ class ProposalGPUOp : public Operator{
 cudaMemcpyHostToDevice));
 
 // copy results after nms
-dimGrid.x = (rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
+dimGrid.x = (param_.rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
 
 Review comment:
   Yes, it should; but throwing out would require a new array. Instead I set 
the predicted confidence to be -1, same as the boxes whose centers are out of 
the input image boundary. They would be ranked to the bottom for NMS so a 
proper threshold did not produce significant problems.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] precedenceguo commented on a change in pull request #9939: add multi proposal operator (cpu version) and fix the bug in proposal op (gpu version)

2018-03-02 Thread GitBox
precedenceguo commented on a change in pull request #9939: add multi proposal 
operator (cpu version) and fix the bug in proposal op (gpu version)
URL: https://github.com/apache/incubator-mxnet/pull/9939#discussion_r172002879
 
 

 ##
 File path: src/operator/contrib/proposal.cu
 ##
 @@ -553,10 +553,10 @@ class ProposalGPUOp : public Operator{
 cudaMemcpyHostToDevice));
 
 // copy results after nms
-dimGrid.x = (rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
+dimGrid.x = (param_.rpn_post_nms_top_n + kMaxThreadsPerBlock - 1) / 
kMaxThreadsPerBlock;
 
 Review comment:
   You are right. Elements whose index is larger than `rpn_post_nms_top_n` 
should be assigned. The values are copied from the valid anchors, just to 
satisfy the output size requirement.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services