GithubHelp home page GithubHelp logo

akihikoy / ay_py Goto Github PK

View Code? Open in Web Editor NEW
2.0 5.0 5.0 766 KB

Python libraries for robot learning, including optimization, Graph-DDP, locally weighted regression, neural networks for regression and classification, geometry and kinematics calculation, robot control interface of Baxter, PR2, Robotiq, Dynamixel and Mikata arm, ROS utility, etc.

Home Page: http://akihikoy.net/notes/?text%2Fay_tools

License: Other

CMake 0.08% Makefile 0.01% Python 99.91%

ay_py's Introduction

ay_py

Python libraries for robot learning, including optimization, Graph-DDP, locally weighted regression, neural networks for regression and classification, geometry and kinematics calculation, robot control interface of Baxter, PR2, Robotiq, ROS utility, etc.

Author

Akihiko Yamaguchi, http://akihikoy.net/

Acknowledgment

CMA-ES (src/ay_py/thirdp/cma.py) is implemented by Nikolaus Hansen. Read src/ay_py/thirdp/CMA1.0.09-README.txt for more information.

Requirements

ay_py.core

  • Python: core, numpy, scipy

ay_py.ros

Binaries are available (you can use apt-get):

  • ROS core system, rospy, roscpp, std_msgs, std_srvs, geometry_msgs, tf, ...
  • ros-ROS_DISTR-moveit-full (ROS_DISTR: groovy, hydro, indigo, etc.)
  • ros-ROS_DISTR-moveit-resources

Working with Baxter/PR2 (OPTIONAL):

Usage

Add src/ay_py/ to Python package path. Under ay_py, there are sub modules:

import sys
sys.path.append('YOUR_DIRECTORY/ay_py/src')

ay_py.core

ROS-independent module, including optimization, Graph-DDP, locally weighted regression, neural networks for regression and classification, geometry and kinematics calculation, etc. You can use this module WITHOUT ROS. Just import the package:

from ay_py.core import *

ay_py.thirdp

Packages from third party are stored. They are internally used in ay_py.*.

ay_py.ros

ROS-dependent module, including utility, robot control interface of Baxter, PR2, Robotiq, etc. ROS environment should be setup before using this module.

from ay_py.ros import *

ay_py.tools

Useful tools, such as GUI with Python.

Requirements: for tool/py_gui.py: tmux rxvt-unicode-256color

For example, run:

python src/ay_py/tool/py_gui.py

demo

In demo directory, many demonstration scripts using ay_py.core are contained. Directly run them.

demo_ros

In demo_ros directory, some demonstration scripts using ay_py.ros are contained. Directly run them.

Troubles

Send e-mails to the author.

ay_py's People

Contributors

akihikoy avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ay_py's Issues

PolygonArea

#Calculate area of a polygon in 2D.
# http://mathworld.wolfram.com/PolygonArea.html
# http://stackoverflow.com/questions/451426/how-do-i-calculate-the-area-of-a-2d-polygon
def PolygonArea(points):
if len(points)<3: return 0.0
return 0.5*abs(sum(x0*y1-x1*y0
for ((x0,y0), (x1,y1)) in zip(points, points[1:]+[points[0]])))

The correctness of the PolygonArea calculation should be double-checked.

cf. https://stackoverflow.com/questions/24467972/calculate-area-of-polygon-given-x-y-coordinates

return 0.5*np.abs(np.dot(points_x,np.roll(points_y,1))-np.dot(points_y,np.roll(points_x,1)))

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.