cbfinn / gps

Guided Policy Search
http://rll.berkeley.edu/gps/
Other
594 stars 239 forks source link

Universal Robot functionality in Gazebo simulation for GPS. #49

Open wtokumaru opened 7 years ago

wtokumaru commented 7 years ago

Contributed to by @symbio-mitch, @symbiomark, @jlmsymbio, and @wtokumaru Mitch Adler mitch@symbiorobotics.com Mark Rogers mark@symbiorobotics.com Jacob Mandelson jacob@symbiorobotics.com William Tokumaru william@symbiorobotics.com

cbfinn commented 7 years ago

This looks great! Very nice documentation.

Is there a way that I can test it in simulation? If so, can you add detailed instructions in docs/index.md for setting it up and running the example? You can edit the "ROS Setup" section appropriately, and add a new section under "Examples" for the UR5.

Note that docs/index.md corresponds to the webpage at rll.berkeley.edu/gps.

symbio-mitch commented 7 years ago

Yep, it should be ready to go in Gazebo. Added to index.md the dependencies and process for running.

Let us know how it goes :).

ahundt commented 7 years ago

Is there anything outstanding on this before merging? I'm interested in trying it out.

wtokumaru commented 7 years ago

Dear Andrew,

I do not believe there is anything else on our end so you are free to test it. Feel free to contact us if you have any questions making it work.

Sincerely,

William

On Sun, Jan 1, 2017 at 6:47 PM, Andrew Hundt notifications@github.com wrote:

Is there anything outstanding on this before merging? I'm interested in trying it out.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/cbfinn/gps/pull/49#issuecomment-269930749, or mute the thread https://github.com/notifications/unsubscribe-auth/AS1mC8og0oFGPMH6lMNCTIY5MBo_YOwNks5rOGVSgaJpZM4J6_w2 .

ahundt commented 7 years ago

@wtokumaru great! @cbfinn can this be merged?

jianlanluo commented 7 years ago

@wtokumaru @cbfinn After some initial trials of this PR, I believe there are some minor notes to be added.

  1. Dependencies, sudo apt-get install ros-indigo-urdf*, xacro, robot-model

  2. __init__.py file is missing in gps.agent.ur_ros folder, so python can't do import

  3. urdf file of universal robots, original hyperparameter.py suggested to find urdf file under

$UR_PATH/ur_description/urdf/ , this would be fine if using ROS < Indigo. However, starting from Indigo, these urdf files are not directly provided anymore under that folder, but instead xacro files, please see https://github.com/ros-industrial/universal_robot/tree/indigo/ur_description/urdf .

So, for ros >= Indigo, you need to manually convert these xacro files to urdf, I use rosrun xacro xacro --inorder -o ur5_robot.urdf ur5_robot.xacro, and the whole simulation worked after I pointed the tree_path to this generated urdf file.

If you build ros-industrial from source, it should be fine. But if you install the ros-industrial stack using apt-get, these folders are inside /opt/ros, so you probably won't have write access to them, you can download these files https://github.com/ros-industrial/universal_robot/tree/indigo/ur_description/urdf in a folder owned by you, and then use xacro for converting format.

I am going to test this on a real ur5 robot, and will let you know once I have more questions.

@wtokumaru Thanks for the nice work!

Jianlan

wtokumaru commented 7 years ago

Thank you for your feedback @JianlanLuo! We will update this PR shortly with your suggestions.

cbfinn commented 7 years ago

Thanks @JianlanLuo!

Happy to merge when changes have been made and Jianlan approves.

wtokumaru commented 7 years ago

Added commits and should be ready to merge when approved by @JianlanLuo.

jacknlliu commented 6 years ago

Is this ready for merging?

wtokumaru commented 6 years ago

I believe so.

jacknlliu commented 6 years ago

I think the PR2 part should be split from ROS package gps_agent_pkg, then package gps_agent_pkg will be robot-agnostic, at least we don't need to compile the gps_agent_pkg with PR2 ROS packages dependencies which is not needed for UR.

And other two things should be considered.

More things will be deeply explored.

wtokumaru commented 6 years ago

@jacknlliu this PR was designed for this codebase over a year ago and is not really intended to change. Further development on this feature since then is unfortunately proprietary. I am not sure what @cbfinn's plan is with it but you are welcome to merge and modify it as you see fit.

jacknlliu commented 6 years ago

@wtokumaru thanks for sharing your thoughts. Are there some better algorithms beyond this GPS for such tasks? I hope to find a replacement.

wtokumaru commented 6 years ago

@jacknlliu What kind of tasks are you talking about specifically?

jacknlliu commented 6 years ago

unknown dynamics and need fewer samples, more efficient sample.

wtokumaru commented 6 years ago

For model-based reinforcement learning specifically for a UR simulation, I would recommend not using something quite as hefty as GPS. Something like a simple optimal control solver should be sufficient. Not sure what you mean by more efficient samples. It may also worth note that any simulation has known dynamics (itself).

wtokumaru commented 6 years ago

Was this ever planned to be merged? I do not have write access, so I am not able to... @cbfinn

seangeiger commented 5 years ago

Has anyone gotten this working on the actual UR5 arm outside of simulation?