lucastabelini / LaneATT

Code for the paper entitled "Keep your Eyes on the Lane: Real-time Attention-guided Lane Detection" (CVPR 2021)
https://openaccess.thecvf.com/content/CVPR2021/html/Tabelini_Keep_Your_Eyes_on_the_Lane_Real-Time_Attention-Guided_Lane_Detection_CVPR_2021_paper.html
MIT License
626 stars 165 forks source link

The influence of different training settings #36

Closed FlowEternal closed 3 years ago

FlowEternal commented 3 years ago

Hello I am now working to further improve the model's ability on my own real world dataset. I am wondering if I can get some suggestion and the reason why this works better.

Question 1: is it really necessary to use the pre-generated anchor mask on the dataset when training? I mean that if I do not use these anchor mask when training, will the training result be vastly different? or just the speed is slower but the training result won't be very different.

Question 2: You actually use nms when training, is it really necesary to use nms to suppress some lower confidence anchors when training ? what if I do not use nms when training, will the training result be vastly different? or just the speed is slower?

Question 3: if the dataset contains the situation where there exists double lanes like the double white-solid lanes, I want to detect each of the two neighbor lanes seperately, then how should I adjust the nms_threshold to keep both lanes remain after nms? or is there some other suggestions when encounter this kind of situations?

lucastabelini commented 3 years ago
  1. No, the training result will not be vastly different. It's just an efficiency optimization (for both training and testing faster), as discussed in the paper.
  2. As discussed in another issue, I did not really experiment much without NMS. But someone else did in #24.
  3. You can try reducing the threshold, but I'm not sure if that is going to work really well. Maybe you'll have to come up with some sort of heuristic. In the case of double white-solid lanes, for example, do you really need to detect both of them separately? Maybe you could predict their average and then do some kind of classification.
FlowEternal commented 3 years ago

thanks for your reply, which resolve the question one and two.

As for the last question, one possible solution that I can come up with is that we further modify the classification part of the network to account for different line types like what VPGnet do.(solid white, solid yellow, dash white and so on). Actually I already did this by changing the laneatt. py and the corresponding index for classification including the .cu file, and retrain it on my own dataset and it achieves satisfactory result of identifying different lane types.But I actually treat double lane when labeling as two seperate lane instead of treating it as one double lane type.

I suppose in this way of treating double lanes as one class, it may intefering with feature learning of single lane and thus downgrade the overall performance of the network.Also, the double lanes are corner cases which mean that the sample number is really small and may suffer from some data imbalance.

So in this way, I have to come up with some heuristic way of dealing with double lanes. I am wondering what is your opinions on how to deal with double lane. Treating it as a specific class or using some clever heuristic (for example, if the two lane have no intersection with each other we keep them, because in real world it may be very unlikely)

lucastabelini commented 3 years ago

In my opinion it makes more sense to treat double lanes as a single object since that's what they are, at least semantically. Therefore, I believe it would be better to differentiate them only in the classification phase. I think it shouldn't be hard to create some sort of heuristic to join two separate labels into a single double lane.

I suppose in this way of treating double lanes as one class, it may intefering with feature learning of single lane and thus downgrade the overall performance of the network.Also, the double lanes are corner cases which mean that the sample number is really small and may suffer from some data imbalance.

I don't think the performance will degrade considerably. However, that can be verified through an experiment, which is what I would recommend you to do.

FlowEternal commented 3 years ago

thanks again I will do the experiment soon later

ForestWang commented 2 years ago

@FlowEternal, for Q1 and Q2,would you share the modified code? thanks a lot.