Our paper describes our data export based on CARLA. For more information, see the official CARLA documentation: Official Documentation.
[HomePage
]Paper
][Data Download
: GoogleDrive
HuggingFace
]
SS3DM: Benchmarking Street-View Surface Reconstruction with a Synthetic 3D Mesh Dataset
Yubin Hu*, Kairui Wen*, Heng Zhou, Xiaoyang Guo, Yong-Jin Liu
NeurIPS 2024 Track on Dataset and Benchmark
🌟 [2024/11/07] We've uploaded the data to GoogleDrive and HuggingFace!
🥳 [2024/09/26] Our paper is accepted by NeurIPS 2024 Track on Dataset and Benchmark.
-
Install and configure CARLA. For installing CARLA's Python library, refer to the official documentation. We recommend using Python 3.7.
-
Install the prerequisite libraries used in the code.
pip3 install -r requirements.txt
-
Open the CARLA simulator, choose one of the cities, load it, and then click "Run" in the top right corner. Here, we will use Town02 as an example.
-
In the
path.txt
of our codebase, select a path (you can also define your own path), and modifyexport/export_car_manager.py
with theroute_points
andtransform
. Setroute_points
to the coordinates of all points along the path, and settransform
to the coordinates and rotation corresponding to the starting point. For example, if we choose theTown_02 300frames
path, the modified code snippet should look like this:route_points = [ carla.Location(x=4610.736328 / 100, y=28746.634766 / 100, z=22.363468 / 100), carla.Location(x=4589.283203 / 100, y=20432.091797 / 100, z=22.353996 / 100) ] transform = carla.Transform(carla.Location(x=4610.736328 / 100, y=28746.634766 / 100, z=22.363468 / 100), carla.Rotation(pitch=0.025818, yaw=-89.975494, roll=0.000184))
-
Modify the
frame_count
inexport/export.py
to the desired number of frames, which in this example is 300 frames. This variable is located at line 114 of the code. -
Run
export/export.py
and wait for the export to complete. The data will be exported to the directory whereexport.py
is located. -
(Optional) If you need to convert the data to Streetsurf format, copy
parse2streetsurf.py
fromdata_processing
to the exported data'sdata/
directory and run it to convert the data format.
By default, the exported data in data/
will contain 8 folders, each storing the following types of data:
- The
depths
folder contains depth data captured by the depth camera, stored inexr
format. For specific parameters of the depth camera, please refer to our paper. Each frame's data is aligned with the RGB camera. - The
images
folder contains image data captured by the RGB camera. - The
insseg
folder contains instance segmentation data from the instance annotation camera, where each color in the image represents a different entity. The same entity will have the same color across different frames from different cameras. Each frame's data is aligned with the RGB camera. - The
lidars
folder contains point cloud data from the LiDAR, stored innpz
format. For specific parameters, please refer to our paper or thelidar2ply.py
script. - The
poses
folder contains the positional information for each frame's camera, including the rotation matrix from Camera 5 (front camera) to the world coordinate system and the rotation matrices from different cameras to the front camera. - The
semseg
folder contains image data from the semantic segmentation camera; refer to the CARLA official documentation for the semantic meanings corresponding to colors. Each frame's data is aligned with the RGB camera. - The
vehicles
andwalkers
folders contain information about other vehicles and pedestrians. This section of the information is not yet fully processed and will be supplemented in future updates.
-
Our dataset may involve multiple coordinate systems; therefore, we provide coordinate transformation scripts located in the
coord_transform
folder.fbx2obj_axis.py
is used to convert the coordinate system of the fbx files exported from CARLA (after being converted toobj
files) to the world coordinate system we use. -
The scripts related to data export are located in the
export
folder.We provide
path.txt
, which records all routes included in our dataset (Note: the frame count may not be accurate, as we made minor adjustments based on the route length);We provide
export.py
for exporting data. When running it, please ensure that you have correctly configured CARLA, and it will export the data to thedata/
folder in the same directory.If you need to modify the route and frame count in
export.py
, please editexport_car_manager.py
and changeframe_count
inexport.py
.We provide
fbx2obj.py
, located in themisc
folder. This script converts thefbx
files exported from CARLA toobj
files. Please note that CARLA does not export materials when exportingfbx
files, so you will need to handle the materials to some extent. -
To facilitate the processing of the dataset, we provide data processing scripts located in the
misc
folder.parse2streetsurf.py
is used to convert data exported from CARLA into training data formatted like Streetsurf.Currently, it has two modes: when
convert_flag
isFalse
, place it in thedata
folder and run it to convert the data in the current folder;When
convert_flag
isTrue
, it can recursively convert all data in the current subfolder. Please note that we have not debugged this functionality, so we do not recommend enabling this option. -
We also provide data visualization scripts to help visualize some of the data, located in the
misc
folder.lidar2ply.py
is used to convert point clouds stored innpz
format in our dataset toply
format for easier viewing;semseg2png.py
is used to convert instance segmentation data stored innpz
format in our dataset topng
format for visualization.