general_ros.py
Go to the documentation of this file.
1 import rospy
2 import rospkg
3 
4 # to wait until application is fully started
5 def waitForService(serviceName, silence = False):
6  if not silence:
7  print("waiting for " + serviceName)
8  rospy.wait_for_service(serviceName, timeout=60)
9  # print("finished waiting for " + serviceName)
10 
11 def waitForAllModules(silence = False):
12  try:
13  waitForService("/rp_ism_node/find_scenes", silence)
14  waitForService("/visualization/clear_all_models", silence)
15  waitForService("/robot_state_publisher/get_loggers", silence)
16  waitForService("/asr_flir_ptu_driver/get_range", silence)
17  waitForService("/ptu_manual_controller_script/get_loggers", silence)
18  #waitForService("/asr_robot_model_services/GetRobotPose")
19  waitForService("/asr_object_database/recognizer_list", silence)
20  waitForService("/nbv/set_point_cloud", silence)
21  waitForService("/move_base/make_plan", silence)
22  waitForService("/asr_mild_base_fake_driving/get_loggers", silence)
23  waitForService("/map_server/get_loggers", silence)
24  waitForService("/asr_fake_object_recognition/get_all_recognizers", silence)
25  waitForService("/env/asr_world_model/get_viewport_list", silence)
26  waitForService("/PTUController/get_loggers", silence)
27  return True
28  except rospy.ROSException, e:
29  return False
30 
31 # get an instance of RosPack with the default search paths, see http://wiki.ros.org/Packages#Python
32 rospack = rospkg.RosPack()
33 
34 # ros package paths
35 scene_exploration_path = rospack.get_path("asr_state_machine")
36 resources_for_active_scene_recognition_path = rospack.get_path("asr_resources_for_active_scene_recognition")
37 world_model_path = rospack.get_path("asr_world_model")
38 recognizer_prediction_ism_path = rospack.get_path("asr_recognizer_prediction_ism")
39 fake_object_recognition_path = rospack.get_path("asr_fake_object_recognition")
40 next_best_view_path = rospack.get_path("asr_next_best_view")
def waitForService(serviceName, silence=False)
Definition: general_ros.py:5
def waitForAllModules(silence=False)
Definition: general_ros.py:11


asr_resources_for_active_scene_recognition
Author(s): Allgeyer Tobias, Aumann Florian, Borella Jocelyn, Karrenbauer Oliver, Marek Felix, Mei├čner Pascal, Stroh Daniel, Trautmann Jeremias
autogenerated on Tue Feb 18 2020 03:14:15