3
$\begingroup$

Not sure if missing values is the right name to use here. I want to train a DNN on data given by a sensor. The sensor gives the (x,y) coordinates of the founded objects. The sensor can keep track of up to 32 objects at once. If the sensor can't find 32 objects (which is always the case) it sets the x and y coordinates of the objects not found to zero. Could there be a problem training a neural network on this kind of data? The sensor is set on a car, the objects are other cars and the networks job is to predict the next move.

Another problem is that when the sensor finds a new object, already existing/found object might change id. Any tips on that? I am thinking about making randomly permute the indices of the object since that should not make any difference?

Are there any standard solutions to these kind of problems? Especially Setting the distance of non existing objects to zero.

$\endgroup$
  • $\begingroup$ Is distance the only feature you have? Or for each object, there are other features like cardinal direction? $\endgroup$ – moh Mar 19 '18 at 12:40
  • $\begingroup$ @moh Each object will have both x and y coordinates which together would give the exact relative position. Not only the distance. $\endgroup$ – Rickard Johansson Mar 19 '18 at 13:21
  • $\begingroup$ So, these zeros are not missing values. They're basically useful information. A missing is when there is an object but your sensor is not able to find its position or distance and you will try to estimate it. I think there is no problem to use them during the training phase. $\endgroup$ – moh Mar 19 '18 at 13:40
1
$\begingroup$

The short answer is "it depends"

Is zero better than one or infinity? It depends on the range of x-y coordinates that you use. It also depends on your output. If you go from (x,y) to something like z = x^2, then you're placing your "null" at a local minimum. So, if it's a car, I'm assuming you're using a forward-facing camera. Do you really want your algorithm to see a bunch of "cars" bunched up at the origin? By the way, where is your origin? Upper left (like most image indexing)? Lower left (like a cartesian plane)? Center (if so, what direction is positive x and y?)

As for re indexing, what you can do is look at the previous frame (or frames) where your 32 objects are indexed, along with their position and velocity. Then, look at the current frame and compare each object's position to the positions in the previous frame. Assign the objects in the current frame the same id as the object nearest it in the previous frame. You can break ties with velocity.

following up on your comments:

a neural network can learn any arbitrary function to any arbitrary precision. Eventually. If you want certain behavior at (0,0) that is dramatically different from behavior at (0+ε,0+ε), then your network will take a long time to converge.

I suggest seeing what kind of results you get by converting nulls to zero and then comparing it to other techniques. Maybe replace null with the average of all the other cars, or set it immediately behind your ego vehicle (since cars primarily move forward, your network will probably put less importance on cars behind the ego car).

$\endgroup$
  • $\begingroup$ "Do you really want your algorithm to see a bunch of 'cars' bunched up at the origin?" is a great way of phrasing the question. I don't want the network to focus on non found objects. I am assuming (taking for granted) that cars close to the sensor should matter more then cars far off when a driver makes a decision. But then again the cars at zero, the closest, should not matter. Can the network learn this? Do you think it is a good idea to divide the coordinates with the total distance? Which would map cars at zero to infinity. $\endgroup$ – Rickard Johansson Mar 20 '18 at 9:49
  • $\begingroup$ The origin is defined at the center (the ego vehicle) with y pointing forward and x pointing to the right. $\endgroup$ – Rickard Johansson Mar 20 '18 at 9:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.