CLRNet
CLRNet copied to clipboard
clr_head.py 389 line meaning?
hi, It's a great work. But when I understand the source code, I'm confused with the meaning of "target_yxtl[:, -1] -= (predictions_starts - target_starts)" in clr_head.py 389 line. Can you help me?
hi, It's a great work. But when I understand the source code, I'm confused with the meaning of "target_yxtl[:, -1] -= (predictions_starts - target_starts)" in clr_head.py 389 line. Can you help me?
The last index of target_yxtl
is the length of lane. This is used to compensate the diff between predictions_starts
and target_starts
since the endpoint of prior and ground truth should be the same.
For example:
Assume we have one ground truth lane, the target_start_y is 0, end_y is 20, so the target_length = 20
. Then we have one predicted lane prior which pred_start_y is 5, we keep the same end_point so the end_y is also 20, so the pred_length = 15
, this is why we need thistarget_yxtl[:, -1] -= (predictions_starts - target_starts)
.