GithubHelp home page GithubHelp logo

xiaojake / livox-localization Goto Github PK

View Code? Open in Web Editor NEW

This project forked from siyuanhuang95/livox-localization

0.0 1.0 0.0 17.81 MB

!!!基于fast-lio和sc的重定位系统:A simple localization framework that can re-localize in one point-cloud map.

License: GNU General Public License v2.0

CMake 0.48% C++ 88.28% Python 11.23%

livox-localization's Introduction

Livox-Localization

This repository implements a point-cloud map based localization framework. The odometry information is published with FAST-LIO. And the initial localization information is obtained with ScanContext and its python-implementation PyICP-SLAM. The main idea is inspired by the FAST-LIO-LOCALIZATION. This repository is the extension of our mapping module: Livox-Mapping, where you can get an accurate point-cloud map.

1. Features

  • Realtime 3D global localization in a pre-built point cloud map.
  • The initial localization pose can be obtained with ScanContext which store the history point cloud collection information.

demo

2. Prerequisites

2.1 Dependencies for FAST-LIO

Technically, if you have built and run FAST-LIO before, you may skip section 2.1.

This part of dependency is consistent with FAST-LIO, please refer to the documentation [Link].

Also, we have provided you the Docker Image (For Cpp-Dependencies) for a quick usage, please check DockerHub. For specific information, please refer to the document described in Livox-Mapping.

2.2 Dependencies for localization module

sudo apt install ros-$ROS_DISTRO-ros-numpy
pip install open3d
  • numpy
pip install numpy
  • sklearn
pip install sklearn

3. Build

Clone the repository and catkin_make:

    cd ~/$A_ROS_DIR$/src
    git clone https://github.com//SiyuanHuang95/Livox-Localization.git
    cd Livox-Localization
    git submodule update --init
    cd ../..
    catkin_make
    source devel/setup.bash
  • Remember to source the livox_ros_driver before build (follow livox_ros_driver)

4. Run Localization

4.1 Dataset Requirements

Before running the mapping functionality, please make sure the sensor data are published to the correct rostopic.

  • Livox LiDAR: /livox/lidar
  • IMU: /livox/imu

4.2 Sample Dataset

For the ease of usage, we are providing several test rosbags collected in one industrial park located in Shanghai. Please be aware that all codes and datasets included in this repository are for academic research purposes only. Other usages are NOT encouraged, and it is at your own risk. If You have any concerns including privacy, please contact us by sending an e-mail to [email protected]

The dataset can be downloaded through the Baidu Netdisk with:

Link:https://pan.baidu.com/s/17ElBOWiFVr68975FtXY8ZA 
Passwort:pjop

The pre-built point-cloud map and its corresponding extracted history information represented with Ring Key, Scan Context and the pose file could be found in one zip file saved in the Baidu Netdisk.

4.3 Prepare ScanContext information

Before run the localization module, you have to prepare the ScanContext related files, which store the history odometry information during the collection activity. Here, we assume that the odometry information has been store in the format of interactive_slam. That format is also the output representation of our former work Livox-Mapping.

We provide the function livox_load_pc_make_sc in our ScanContextManager class, you can refer to the file livox_scan_context_test.py for the usage demonstration.

4.4 Run Localization Module

  1. First, please make sure you're using the Python 2.7 environment;
  2. Provide ScanContext information path. Modify the SC-file path for line 256 of the file global_localization.
  3. Run localization, here we take Livox Horizion as an example:
 roslaunch livox_localization localization_horizon.launch  map:=/path/to/your/map.pcd

​ Please modify /path/to/your/map.pcd to your own map point cloud file path.

​ Wait for 3~5 seconds until the map cloud shows up in RVIZ;

  1. Play the demo rosbag.
rosbag play demo.bag

Related Works

  1. FAST-LIO: A computationally efficient and robust LiDAR-inertial odometry (LIO) package
  2. ikd-Tree: A state-of-art dynamic KD-Tree for 3D kNN search.
  3. FAST-LIO-SLAM: The integration of FAST-LIO with Scan-Context loop closure module.
  4. FAST-LIO-LOCALIZATION: A simple localization framework that can re-localize in built maps based on FAST-LIO.
  5. LIO-SAM_based_relocalization: A simple system that can relocalize a robot on a built map based on LIO-SAM.

Acknowledgments

Thanks for the authors of FAST-LIO, FAST-LIO-LOCALIZATION and LIO-SAM_based_relocalization. We also use the tools from PyICP-SLAM and kd-tree.

Contact

  • If you have any questions, contact here please

livox-localization's People

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.