Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Menu based teleop plugins #721

Open
wants to merge 21 commits into
base: master
Choose a base branch
from
Open

Conversation

weiqiyang
Copy link
Contributor

@weiqiyang weiqiyang commented Jun 18, 2019

This PR adds several plugins to jsk_teleop_joy that provides functions including base movement, bounding-box selection and end-pose adjustment.

Following is the demo video.
https://drive.google.com/file/d/1WrQpt2VzYSj-bA00aqcJO4Gx3hJAHAHz/view?usp=sharing

@k-okada k-okada requested review from knorth55 and itohdak June 18, 2019 23:45
@knorth55
Copy link
Member

Can you attach demo video about how to use this plugin?

@weiqiyang weiqiyang changed the title Add base_pose plugin [WIP] Add base_pose plugin Jun 20, 2019
@weiqiyang
Copy link
Contributor Author

I add a sample launch file.
There are still several improves that I would like to imply, so I add WIP to the title.

@weiqiyang weiqiyang changed the title [WIP] Add base_pose plugin Menu based teleop plugins Nov 1, 2019
@weiqiyang
Copy link
Contributor Author

I modified the title and PR comment with a link to a demo video.

@k-okada
Copy link
Member

k-okada commented Nov 1, 2019

Nice video

  1. What is the role of irteus view?
  2. I think latency is very important in this application, Please analyze why the point loud did has latency + low throughput . For example, if we subsmple the cloud, can we speed up? Or did you transfer pointcloud of depthmap ...

@weiqiyang
Copy link
Contributor Author

Thank you.

1. What is the role of irteus view?

The plugins publishs manually adjusted pose and button commands. The irteus view in the demo is an example of the application of the plugins cooperating with euslisp.

2. I think latency is very important in this application, Please analyze why the point cloud did has latency + low throughput . For example, if we subsample the cloud, can we speed up? Or did you transfer pointcloud of depthmap ...

The pointcloud has latency because I was using the raw data while making this video. We tried using compressed data republished by an extra node later, which do speed up the pointcloud display.

@k-okada
Copy link
Member

k-okada commented Nov 1, 2019 via email

@weiqiyang
Copy link
Contributor Author

If operator only sees Rviz, then I think we do not need irtview in the video.

The operator sees the irtviewer also, to confirm ik result before executing.
Maybe if we can have an euslisp script that generate a tf topic from joint-angle array, then we can show the result as another robot model, and the irtviewer is no longer needed.

If you use pointlcoud, please consider using depthimage
jsk-ros-pkg/jsk_robot#923

Yes, this is what I mean by "compressed data", and we are using this node now.

@k-okada
Copy link
Member

k-okada commented Nov 1, 2019 via email

@weiqiyang
Copy link
Contributor Author

Thank you for the suggestion!

I tried to modified the code to apply it on hsr and successfully published the marker.
However, since the marker topic is presented in points, the topic was very heavy.
(rostopic hz showed a result of less than 0.2Hz.
I also tried to take a log by rostopic echo -n 1, and a single publish was over 15MB)

Now I am using robot_state_publisher.
I will try to come up with a new video this week.

@knorth55
Copy link
Member

knorth55 commented Nov 8, 2019

Can you use 4 spaces for indentation?
Python does not matter, but it is better to use same indentation as other python files.

@knorth55
Copy link
Member

knorth55 commented Nov 8, 2019

There are many changes, so it may take time for review. I'm reviewing now.

@weiqiyang
Copy link
Contributor Author

Can you use 4 spaces for indentation?
Python does not matter, but it is better to use same indentation as other python files.

I checked other python files in the plugin folder, and I think they are all using 2 spaces for indentation.

@@ -0,0 +1,44 @@
<launch>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

joy_plugin_sample.launch -> sample_joy_plugin.launch

Comment on lines 3 to 7
import imp
try:
imp.find_module("geometry_msgs")
except:
import roslib; roslib.load_manifest('jsk_teleop_joy')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't need this for python programs.

@@ -0,0 +1,194 @@
from joy_rviz_view_controller import RVizViewController
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use 4 space indents.

Comment on lines 3 to 7
import imp
try:
imp.find_module("geometry_msgs")
except:
import roslib; roslib.load_manifest('jsk_teleop_joy')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't need these lines

@@ -0,0 +1,116 @@
from joy_rviz_view_controller import RVizViewController
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use 4 space indents

break
rospy.loginfo("End loading base_pose")

def setPoseCB(self, pose):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use snake case

import math
import time

def signedSquare(val):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use snake case for functions

from jsk_recognition_msgs.msg import BoundingBox
from jsk_recognition_msgs.msg import BoundingBoxArray

def signedSquare(val):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use snake case for functions

self.bbox_pub.publish(self.bbox)
self.prev_time = now

def bboxSB(self, msg):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use snake case for functions

import numpy
import time

def signedSquare(val):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use snake case for functions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants