original_docstring: 
          Will load the file specified in config file containing the map rooms. Displays the interactive markers on the last saved points
          
docstring: Will load the file specified in config file containing the map rooms. Displays the interactive markers on the last saved points
docstring_tokens: Will load the file specified in config file containing the map rooms . Displays the interactive markers on the last saved points
code: def load_last_map(self):
          """
          Will load the file specified in config file containing the map rooms. Displays the interactive markers on the last saved points
          """
          rospy.loginfo(self.current_dir)
          file_path = os.path.join(self.current_dir,rospy.get_param("~map_file_path"))
  
          try:
              with open(file_path,'r+') as json_file:
                  data = json.load(json_file)
                  
              self.coord_IMs = data
  
  
              for room in data.keys():
                  for point_id in data[str(room)].keys():
                      int_marker = InteractiveMarker()
                      int_marker.header.frame_id = "/map"
                      int_marker.name = "marker_" + room + "_" + point_id
                      int_marker.description = "marker_" + room + "_" + point_id
  
                      int_marker.pose.position.x = data[str(room)][point_id]['x']
                      int_marker.pose.position.y = data[str(room)][point_id]['y']
                      # create a grey box marker
                      box_marker = Marker()
                      box_marker.header.frame_id = "map"
                      box_marker.type = Marker.CUBE
                      box_marker.pose.position.x = data[str(room)][point_id]['x']
                      box_marker.pose.position.y = data[str(room)][point_id]['y']
                      box_marker.scale.x = 0.2
                      box_marker.scale.y = 0.2
                      box_marker.scale.z = 0.2
                      box_marker.color.r = 0.0
                      box_marker.color.g = 0.5
                      box_marker.color.b = 0.5
                      box_marker.color.a = 1.0
  
                      # create a non-interactive control which contains the box
                      box_control = InteractiveMarkerControl()
                      box_control.always_visible = True
                      box_control.markers.append( box_marker )
  
                      # add the control to the interactive marker
                      int_marker.controls.append( box_control )
  
                      # create a control which will move the box
                      # this control does not contain any markers,
                      # which will cause RViz to insert two arrows
  
  
                      rotate_control = InteractiveMarkerControl()
                      rotate_control.orientation.w = 1
                      rotate_control.orientation.x = 1
                      rotate_control.orientation.y = 0
                      rotate_control.orientation.z = 0
                      rotate_control.name = "move_x"
                      rotate_control.interaction_mode = InteractiveMarkerControl.MOVE_AXIS
                      
  
                      # # add the control to the interactive marker
                      int_marker.controls.append(rotate_control)
  
                      rotate_control = InteractiveMarkerControl()
                      rotate_control.orientation.w = 1
                      rotate_control.orientation.x = 0
                      rotate_control.orientation.y = 0
                      rotate_control.orientation.z = 1
                      rotate_control.name = "move_y"
                      rotate_control.interaction_mode = InteractiveMarkerControl.MOVE_AXIS
                      int_marker.controls.append(rotate_control)
                      # add the interactive marker to our collection &
                      # tell the server to call processFeedback() when feedback arrives for it
                      self.server.insert(int_marker, self.processFeedback)
  
                      self.server.applyChanges()
  
              rospy.loginfo("{class_name} : Map loaded".format(class_name=self.__class__.__name__))
          except:
              rospy.logwarn("{class_name} : No map could be loaded".format(class_name=self.__class__.__name__))
code_tokens: def load_last_map ( self ) : rospy . loginfo ( self . current_dir ) file_path = os . path . join ( self . current_dir , rospy . get_param ( "~map_file_path" ) ) try : with open ( file_path , 'r+' ) as json_file : data = json . load ( json_file ) self . coord_IMs = data for room in data . keys ( ) : for point_id in data [ str ( room ) ] . keys ( ) : int_marker = InteractiveMarker ( ) int_marker . header . frame_id = "/map" int_marker . name = "marker_" + room + "_" + point_id int_marker . description = "marker_" + room + "_" + point_id int_marker . pose . position . x = data [ str ( room ) ] [ point_id ] [ 'x' ] int_marker . pose . position . y = data [ str ( room ) ] [ point_id ] [ 'y' ] box_marker = Marker ( ) box_marker . header . frame_id = "map" box_marker . type = Marker . CUBE box_marker . pose . position . x = data [ str ( room ) ] [ point_id ] [ 'x' ] box_marker . pose . position . y = data [ str ( room ) ] [ point_id ] [ 'y' ] box_marker . scale . x = 0.2 box_marker . scale . y = 0.2 box_marker . scale . z = 0.2 box_marker . color . r = 0.0 box_marker . color . g = 0.5 box_marker . color . b = 0.5 box_marker . color . a = 1.0 box_control = InteractiveMarkerControl ( ) box_control . always_visible = True box_control . markers . append ( box_marker ) int_marker . controls . append ( box_control ) rotate_control = InteractiveMarkerControl ( ) rotate_control . orientation . w = 1 rotate_control . orientation . x = 1 rotate_control . orientation . y = 0 rotate_control . orientation . z = 0 rotate_control . name = "move_x" rotate_control . interaction_mode = InteractiveMarkerControl . MOVE_AXIS int_marker . controls . append ( rotate_control ) rotate_control = InteractiveMarkerControl ( ) rotate_control . orientation . w = 1 rotate_control . orientation . x = 0 rotate_control . orientation . y = 0 rotate_control . orientation . z = 1 rotate_control . name = "move_y" rotate_control . interaction_mode = InteractiveMarkerControl . MOVE_AXIS int_marker . controls . append ( rotate_control ) self . server . insert ( int_marker , self . processFeedback ) self . server . applyChanges ( ) rospy . loginfo ( "{class_name} : Map loaded" . format ( class_name = self . __class__ . __name__ ) ) except : rospy . logwarn ( "{class_name} : No map could be loaded" . format ( class_name = self . __class__ . __name__ ) )
short_docstring: Will load the file specified in config file containing the map rooms.
short_docstring_tokens: Will load the file specified in config file containing the map rooms .
comment: """
          Will load the file specified in config file containing the map rooms. Displays the interactive markers on the last saved points
          """$SEP$# create a grey box marker$SEP$# create a non-interactive control which contains the box$SEP$# add the control to the interactive marker$SEP$# create a control which will move the box$SEP$# this control does not contain any markers,$SEP$# which will cause RViz to insert two arrows$SEP$# # add the control to the interactive marker$SEP$# add the interactive marker to our collection &$SEP$# tell the server to call processFeedback() when feedback arrives for it