minimum snap trajectory generator
Project description
MiSTGen: Minimum Snap Trajectory Generator
1 Overview
Minimum snap trajectory generators can generate smooth trajectories that have minimum snap, pass through specified waypoints and are subject to velocity and acceleration constraints.
2 How to use
3.1 Installing
pip install mistgen
3.2 Usage
from mistgen.mist import mist_generator
myMistGen = mist_generator()
xxs,yys,tts = myMistGen.mist_2d_gen(waypts_ori,v0,a0,ve,ae,T)
vaj_xy = myMistGen.mist_2d_vaj_gen(xxs,yys,tts)
myMistGen.mist_2d_vis(waypts_ori,xxs,yys,tts,vaj_xy,show_wp=True,show_mist_xy=True,show_avj=True,same_plot=False)
# or all in one:
mistTraj = myMistGen.mist_2d_gen_all(waypts_ori,v0,a0,ve,ae,T,show_wp=True,show_mist_xy=True,show_avj=False,same_plot=False)
A simple example:
def main_demo_v010():
ax = [0.0, 5.0,5.0,0.0]
ay = [0.0, 0.0,6.0,6.0]
waypts_ori = np.array([ax,ay])
T = 10
v0 = np.array([0,0])
a0 = np.array([0,0])
ve = np.array([0,0])
ae = np.array([0,0])
myMistGen = mist_generator()
xxs,yys,tts = myMistGen.mist_2d_gen(waypts_ori,v0,a0,ve,ae,T)
vaj_xy = myMistGen.mist_2d_vaj_gen(xxs,yys,tts)
myMistGen.mist_2d_vis(waypts_ori,xxs,yys,tts,vaj_xy,True,True,True)
yaw_rad,yaw_deg = myMistGen.calc_yaw(vaj_xy[0],vaj_xy[3])
For more example, please do the following:
from mistgen.examples.main_demo_v010 import main_demo_v010
from mistgen.examples.main_demo_v02x import main_demo_v020
from mistgen.examples.main_demo_v02x import main_demo_v021
3 API
Some utils functions:
from utils.T_functions import arrangeT
from utils.T_functions import init_T
from utils.cvxopt_qp import quadprog
from utils.other_utils import computeQ
from utils.other_utils import calc_tvec
from utils.other_utils import re_shape_vaj
from utils.other_utils import poly_val
License
This source code is released under GNU GENERAL PUBLIC LICENSE Version 3 license.
For more questions, please contact author: Zhaoliang (zhz03@g.ucla.edu)
Reference
[1] Minimum Snap Trajectory Generation and Control for Quadrotors
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mistgen-0.2.6.tar.gz.
File metadata
- Download URL: mistgen-0.2.6.tar.gz
- Upload date:
- Size: 22.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.7.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bffa3a08fac35f3c7a8c987137122185907e5dac9f195e79da8f9470827e6495
|
|
| MD5 |
2ac691d18f82c00a105111a62d8a56f7
|
|
| BLAKE2b-256 |
879413e0d08fe443528763ab841f9ea289ff3356450b09171f5012ec058ca130
|
File details
Details for the file mistgen-0.2.6-py3-none-any.whl.
File metadata
- Download URL: mistgen-0.2.6-py3-none-any.whl
- Upload date:
- Size: 26.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.7.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
20538de846c454dc79344543c7283256cfad25442b575443566f93e42816df34
|
|
| MD5 |
e69b4aeb773f0bb63fd14f6deb8e2926
|
|
| BLAKE2b-256 |
f8b7b9abdbe55f4a807410f1dfd540b7f372b7978c46e1396f4fb2f30ee6095e
|