Ask Your Question

Revision history [back]

Detect one of N objects

I want to detect only one of N objects. The objects are similar. I can train for each object including the other objects as negative images, along with other negative images.

I can then detect each object. I should only get one hit. I can pick the one with the best match if more than one hit.

My question is, is there a better way to do this than running a detection for each object?

Can I detect the one from N objects is a single go, ether using all the training results or by training in a different way?

(I'm happy to create a new tool using OpenCV API if required.)

Detect one of N objects

I want to detect only one of N objects. The objects are similar. I can train for each object including the other objects as negative images, along with other negative images.

I can then detect each object. I should only get one hit. I can pick the one with the best match if more than one hit.

My question is, is there a better way to do this than running a detection for each object?

Can I detect the one from N objects is a single go, ether using all the training results or by training in a different way?

(I'm happy to create a new tool using OpenCV API if required.)

EDIT

One project in mind to detect a model car and its crude orientation. It will be on a flat surface with the camera "level" but the camera could be at any elevation. To make the task easier for feature based stuff I choose (rightly or wrongly) eight positions where the features would be different. Front of the car, 45 degrees ie front top and one side. 90 degrees, side no front or back, etc etc. The big task is collecting training material so 'm trying to plan ahead a bit.

Steven's plan looks like a better one where I build a car detector and then a "found car" orientation detector. For the car detector was hoping to use Haar features and standard tools to create a car detector. (Maybe LBP for performances issues.)

Its very unclear to me what data I would feed the second stage (SVM?)

  • I could get the cropped image of the found car
  • I could possibly feed it the original found features from the whole image cropped to the car region. Saving the feature finding step again.
  • Possibly just the features car finder used to find the car. Already filtering irrelevant features.

Detect one of N objects

I want to detect only one of N objects. The objects are similar. I can train for each object including the other objects as negative images, along with other negative images.

I can then detect each object. I should only get one hit. I can pick the one with the best match if more than one hit.

My question is, is there a better way to do this than running a detection for each object?

Can I detect the one from N objects is a single go, ether using all the training results or by training in a different way?

(I'm happy to create a new tool using OpenCV API if required.)

EDIT

One project in mind to detect a model car and its crude orientation. It will be on a flat surface with the camera "level" but the camera could be at any elevation. To make the task easier for feature based stuff I choose (rightly or wrongly) eight positions where the features would be different. Front of the car, 45 degrees ie front top and one side. 90 degrees, side no front or back, etc etc. The big task is collecting training material so 'm trying to plan ahead a bit.

Steven's plan looks like a better one where I build a car detector and then a "found car" orientation detector. For the car detector was hoping to use Haar features and standard tools to create a car detector. (Maybe LBP for performances issues.)

Its very unclear to me what data I would feed the second stage (SVM?)

  • I could get the cropped image of the found car
  • I could possibly feed it the original found features from the whole image cropped to the car region. Saving the feature finding step again.
  • Possibly just the features car finder used to find the car. Already filtering irrelevant features.

EDIT2

Here are some images from the internet of the sort of thing...

image description

Above is what I would call a south east facing car.

image description

Above is a south west facing car.

I would like to

  • Detect the car in a scene.
  • Detect which way it is facing (one of eight)

I want to avoid creating eight different "car in scene" detectors if this is not a cleaver way of doing things. (If creating eight detects is the "best" I can do that.) (These are not training pictures just examples. Training pictures would be the car in a real scene, unfortunately I don't have a huge infinity curve for the car to drive on. )