Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Are there any examples of how to use caffe-fast-rcnn in C++? #5

Open
jainanshul opened this issue Feb 11, 2016 · 1 comment
Open

Are there any examples of how to use caffe-fast-rcnn in C++? #5

jainanshul opened this issue Feb 11, 2016 · 1 comment

Comments

@jainanshul
Copy link

Specifically I am looking for a way to get bounding boxes for the proposed region and their classification.

@AlexeyAB
Copy link

AlexeyAB commented Apr 17, 2016

I join a question.

1 Is there enough will get exactly the same way as an array as here?

/* Copy the output layer to a std::vector */

Blob<float>* output_layer = net_->output_blobs()[0];
  const float* begin = output_layer->cpu_data();
  const float* end = begin + output_layer->channels();
  return std::vector<float>(begin, end);

In which: { class_score, x, y, width, height, class_score, x, y, width, height, ... }

2 Or should we use like this?

    const vector<Blob<float>*>& output_blobs = net_->ForwardPrefilled();
    //LOG(INFO) << "End";
    for (int i = 0; i < output_blobs.size(); ++i) {

Where for each output_blobs[i] contains different layers: cls_score, bbox_pred, cls_prob ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants