How to handle image classification network where output classes can be subsets of one another? For instance, if I wanted a train network that can output


van
truck
sedan
vehicle
pedestrian


does it make sense to only train it on van, truck, sedan, and pedestrian and then make "vehicle" a synonym of van, truck, sedan? Or does it make sense to train vehicle as its own class made up of the combined training data of van, truck, sedan?

EDIT ---

Here's a more clear example I think, what if there are labels that are not exclusive? For instance, a child can also be a pedestrian. How do I train a network to output both labels if it, for example, sees a child walking down the street? It seems that using a softmax later as the final layer of the network would not allow this to work as all probabilities need to sum to one, in this case it could be 90% child and 80% pedestrian and that's entirely valid.
It depends what you're trying to achieve.

In general, there are things that are vehicles but aren't vans, trucks, or sedans, so your two proposed schemes are not equivalent even if you were somehow able to obtain a 100% accurate classifier.

In general, the way to answer questions like this is to try it both ways and see which works better.