Coder Social home page Coder Social logo

yeranlee / agv_path_smoothing Goto Github PK

View Code? Open in Web Editor NEW

This project forked from q576333/agv_path_smoothing

0.0 0.0 0.0 889 KB

A generating/fitting specified NURBS curve ROS package

License: BSD 3-Clause "New" or "Revised" License

C++ 98.53% CMake 1.47%

agv_path_smoothing's Introduction

agv path smoothing - A generating/fitting specified NURBS curve ros package

This is a ROS package developed NURBS method for path smoothing in autonomous mobile robot navigation to avoid global planners generated path which has many sharp turns. The NURBS(Non-Uniform Rational B-Spline) curve, consist of control point, knot vector and weight vector, is parameter curve that can let curve curvature continuity and with high degree of freedom to modify curve.

The main features include:

  • Implemented the generate Line, Bezier, B-spline and NURBS curve.
  • Implemented the global interpolation method (see reference) to fit discrete waypoints.
  • Implemented useful function for motion planning to use, such as calculation NURBS curve derivative, curvature, curve length and so on.
  • Implemented limited fitting function let the mobile robot do not need to rotate in place when navigating.

image

The package is under development, some future works are listing below:

  • Knot insert function
  • Collision checking
  • Real time control point repositioning (path modification)
  • Extend to 3D NURBS curve.

Installation

This package based on Eigen library to development, so please install eigen library first.

sudo apt-get install libeigen3-dev

Next, clone this repository to your catkin workspace and catkin build this package.

cd ~/catkin_ws/src
glt clone https://github.com/q576333/agv_path_smoothing
catkin build

Usage

Gerenting NURBS curve example

Setting control point, knot vector and weight vector in launch file

<rosparam param="control_point" > [0, 0, 0, -2, 4, -2, 4, 0, 4, 2, 0, 2, 0, 0]</rosparam> 
<rosparam param="knot_vector" > [0, 0, 0, 0.25, 0.5, 0.5, 0.75, 1, 1, 1]</rosparam>
<rosparam param="weight_vector" > [1, 0.5, 0.5, 1, 0.5, 0.5, 1]</rosparam>

Running

roslaunch agv_path_smoothing spline_visualization.launch

image

Fitting waypoints to NURBS curve example

Setting discrete waypoints and weight vector in launch file

<rosparam param="fitting_point" > [-6, -3, -5, -2.5, 1, 3, 2, 1.5, 3, 1, 7, 1.5, 9, -2.5]</rosparam>
<rosparam param="weight_vector" > [1, 1, 1, 1, 1, 1, 1]</rosparam>

Running

roslaunch agv_path_smoothing fitting_test.launch

image

Reference

  • "The NURBS Book" Les Piegl and Wayne Tiller, 2nd edn., Springer, 1997.

agv_path_smoothing's People

Contributors

q576333 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.