Home

Awesome

A Synthetic Dataset for 3D lane Detection

Introduction

This is a synthetic dataset constructed to stimulate the development and evaluation of 3D lane detection methods (download dataset from [google drive] [baidu netdisk]). This dataset is an extension to Apollo Synthetic Dataset. The detailed strategy of construction and the evaluation method refer to our ECCV 2020 paper:

"Gen-LaneNet: a generalized and scalable approach for 3D lane detection", Y. Guo, etal., ECCV, 2020 [eccv][arxiv] [code]

<p align="center"> <img src="figs/00_0000045.jpg" width="280" /> <img src="figs/08_0000003.jpg" width="280" /> <img src="figs/16_0000077.jpg" width="280" /> </p>

Requirements

Data preparation

You are welcome to proceed to the development and evaluation directly using the splits of the training and testing sets we provide. Feel free to skip this section if you use our data split directly.

```
data_splits
├── standard
│   ├── 3D_LaneNet
|   |       └──test_pred_file.json
│   ├── Gen_LaneNet
|   |       └──test_pred_file.json
│   ├── train.json
│   └── test.json
│── rare_subset
│   ├── 3D_LaneNet
|   |       └──test_pred_file.json
│   ├── Gen_LaneNet
|   |       └──test_pred_file.json
│   ├── train.json
│   └── test.json
|── illus_chg
│   ├── 3D_LaneNet
|   |       └──test_pred_file.json
│   ├── Gen_LaneNet
|   |       └──test_pred_file.json
│   ├── train.json
│   └── test.json
```

Meanwhile, we provide the helper functions needed to build your own split from the raw datasets downloaded. The following codes need to be right in order.

parse_apollo_sim_raw_data.py

This code extracts lane-lanes and center-lanes in an interested top-view area. The code reasons about the foreground and background occlusion based on the provided ground-truth depth maps and semantic segmentation map. Those lane segments in the distance occluded by background are discarded, because in general they are not expected to recover from a lane detection method. By setting 'vis=True', this code will draw ground-true lane-lines and center-lines on each image and save them.

prepare_data_split.py

This code randomly splits the whole data into training and testing sets following a 'standard' five-fold split. Specifically, a subset generated from a difficult urban map are further extracted to be the test set for 'rare subset' data split.

prepare_data_subset

Given the standard split of data, this code excludes images corresponding to a certain 'illumination' condition (before dawn) from the training set. On contrary, in the testing set, only images corresponding to that illumination condition are kept.

Evaluation

eval_3D_lane.py

You need to modify 'method_name', 'data_split' to specify the method and the data split to conduct evaluation. For example, the default setting compares 'data_splits/illus_chg/Gen_LaneNet/test_pred_file.json' against ground-truth 'data_splits/illus_chg/test.json'. Optionally, set 'args.dataset_dir' to the folder containing the original dataset. The original images are only required for visualizing lane results, when setting 'vis = True'.

In this dataset, each image sample is associated with a set of ground-truth 3D lane-lines and center-lines, as well as the camera height and pitch angle. Per image, the optimal bipartite match between a set of predicted lane curves and a set of ground-truth lane curves is sought via solving a min-cost flow. Precision and recall are computed via varying lane confidence thresholds. Overall, evaluation metrics include:

Before running the evaluation, you need to make sure the predicted lanes are saved in the 'test_pred_file.json' file following the format included in our example. Specifically, each lane needs to be associated with a 'prob' score to calculate the precision and recall in full-range. Otherwise, you can only keep 'evaluator.bench_one_submit' in the main code to evaluate your algorithm at a single operation point.

Baselines Results

We show the evaluation results comparing two baseline methods:

Comparisons are conducted under three distinguished splits of the dataset. For simplicity, only lane-line results are reported here. The results from the code is slightly different from that reported in the paper due to different random splits.

MethodAPF-Scorex error near (m)x error far (m)z error near (m)z error far (m)
3D-LaneNet89.386.40.0680.4770.0150.202
Gen-LaneNet90.188.10.0610.4960.0120.214
MethodAPF-Scorex error near (m)x error far (m)z error near (m)z error far (m)
3D-LaneNet74.672.00.1660.8550.0390.521
Gen-LaneNet79.078.00.1390.9030.0300.539
MethodAPF-Scorex error near (m)x error far (m)z error near (m)z error far (m)
3D-LaneNet74.972.50.1150.6010.0320.230
Gen-LaneNet87.285.30.0740.5380.0150.232

Visualization

Visual comparisons to the ground truth can be generated per image when setting 'vis = True'. We show two examples for each method under the data split involving illumination change.

<img src="figs/3D_LaneNet/images_00_0000148.jpg" width="400"> <img src="figs/3D_LaneNet/images_00_0000171.jpg" width="400">

<img src="figs/Gen_LaneNet/images_00_0000148.jpg" width="400"> <img src="figs/Gen_LaneNet/images_00_0000171.jpg" width="400">

Citation

Please cite the paper in your publications if it helps your research:

@article{guo2020gen,
  title={Gen-LaneNet: A Generalized and Scalable Approach for 3D Lane Detection},
  author={Yuliang Guo, Guang Chen, Peitao Zhao, Weide Zhang, Jinghao Miao, Jingao Wang, and Tae Eun Choe},
  booktitle={Computer Vision - {ECCV} 2020 - 16th European Conference},
  year={2020}
}