From 92a7163ce2388997eb368872c0052af28068866b Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Wed, 1 Nov 2023 09:27:01 +0300 Subject: [PATCH 1/8] Add files via upload --- .../benchmarking_local_global_planners_pdf.py | 487 +++++++++++------- ROSNavBench/marker_publisher.py | 2 +- ROSNavBench/performace_analysis.py | 45 +- config/circle_path_scenario.yaml | 25 +- config/differen_tunning_DWB.yaml | 64 +++ config/dynamic_obstacles.yaml | 26 +- config/narrow_path.yaml | 6 +- config/params.yaml | 6 +- config/random_waypoints.yaml | 29 +- config/random_waypoints_2.yaml | 63 +++ config/static_2.yaml | 66 +++ config/static_obstacles.yaml | 28 +- config/straight_line.yaml | 20 +- .../behavior_trees/btNavFn_MPPI.xml | 39 ++ .../turtlebot3/behavior_trees/btNavFn_RPP.xml | 39 ++ .../behavior_trees/bt_NavFn_DWB.xml | 39 ++ .../behavior_trees/bt_NavFn_DWB_1.xml | 36 ++ .../behavior_trees/bt_NavFn_DWB_2.xml | 36 ++ .../behavior_trees/bt_NavFn_DWB_RSC.xml | 36 ++ .../behavior_trees/bt_NavFn_MPPI.xml | 39 ++ .../behavior_trees/bt_NavFn_RPP.xml | 39 ++ .../behavior_trees/bt_NavFn_RPP_RSC.xml | 36 ++ .../behavior_trees/bt_smac_planner_DWB.xml | 39 ++ .../bt_smac_planner_DWB_RSC.xml | 36 ++ .../behavior_trees/bt_smac_planner_MPPI.xml | 39 ++ .../behavior_trees/bt_smac_planner_RPP.xml | 39 ++ .../bt_smac_planner_RPP_RSC.xml | 36 ++ .../behavior_trees/btsmac_planner_MPPI.xml | 39 ++ .../behavior_trees/btsmac_planner_RPP.xml | 39 ++ example/turtlebot3/behavior_trees/pose.xml | 19 +- example/turtlebot3/behavior_trees/poses.xml | 22 +- example/turtlebot3/behavior_trees/posses.xml | 39 ++ example/turtlebot3/nav2_config/waffle.yaml | 102 +++- launch/main.launch.py | 49 +- 34 files changed, 1375 insertions(+), 329 deletions(-) create mode 100644 config/differen_tunning_DWB.yaml create mode 100644 config/random_waypoints_2.yaml create mode 100644 config/static_2.yaml create mode 100644 example/turtlebot3/behavior_trees/btNavFn_MPPI.xml create mode 100644 example/turtlebot3/behavior_trees/btNavFn_RPP.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml create mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml create mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml create mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml create mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml create mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml create mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml create mode 100644 example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml create mode 100644 example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml create mode 100644 example/turtlebot3/behavior_trees/posses.xml diff --git a/ROSNavBench/benchmarking_local_global_planners_pdf.py b/ROSNavBench/benchmarking_local_global_planners_pdf.py index 3d06f09..5eabb17 100644 --- a/ROSNavBench/benchmarking_local_global_planners_pdf.py +++ b/ROSNavBench/benchmarking_local_global_planners_pdf.py @@ -1,4 +1,5 @@ #! /usr/bin/env python3 +from hmac import new from pydoc import plain import numpy as np import yaml @@ -24,7 +25,8 @@ from numpy import asarray from ROSNavBench.follow_path import circle_points,square_points from ROSNavBench.performace_analysis import performance_analysis - +from scipy import ndimage +from scipy.interpolate import interp1d def main(): ''' @@ -69,11 +71,10 @@ def path_length(controller_number): trajectory_type= robot_specs['trajectory_type'] map_path=robot_specs['map_path'] map_png_path=robot_specs['map_png_path'] - trails_num = robot_specs['trails_num'] criteria= robot_specs['criteria'] weights= robot_specs['weights'] - if trails_num>0: - controller_type=[controller_type[0]]*trails_num + instances_num= robot_specs['instances_num'] + # list of arrays to hold data of experiment # This is a way to arrange data to be used for analysis and ploting data=[] @@ -94,7 +95,7 @@ def path_length(controller_number): distance_to_obstacles=[] # nested arrays equal to number of controllers # E.g., x_points=[[x points for the 1st controller],[x points for the 2nd controller],...] - for i in range(len(controller_type)*len(planner_type)): + for i in range(len(controller_type)*len(planner_type)*instances_num): data.append([]) CPU.append([]) Memory.append([]) @@ -108,18 +109,19 @@ def path_length(controller_number): # open each csv file for the different used controllers, and add all data to data array for k in range(len(planner_type)): for i in range(len(controller_type)): - round_num=len(controller_type)*k+i - f=open(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data', - pdf_name+'_'+controller_type[i]+planner_type[k]+str(round_num+1)+'.csv'),'r') - writer=csv.reader(f,quoting=csv.QUOTE_NONNUMERIC,delimiter=' ') - for lines in writer: - data[round_num].append(lines[:]) + for q in range(instances_num): + round_num=k*len(controller_type)*instances_num+i*instances_num+q + f=open(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data', + pdf_name+'_'+controller_type[i]+planner_type[k]+str(round_num+1)+'.csv'),'r') + writer=csv.reader(f,quoting=csv.QUOTE_NONNUMERIC,delimiter=' ') + for lines in writer: + data[round_num].append(lines[:]) # Extarct data from data array and arrange them into different arrays - for k in range(len(controller_type)*len(planner_type)): + for k in range(len(controller_type)*len(planner_type)*instances_num): for i in range(len(data[k])-5): #EDIT FOR ADDING THE PATH CPU[k].append(data[k][i+2][0]) Memory[k].append(data[k][i+2][1]) @@ -135,9 +137,19 @@ def path_length(controller_number): global_y_points.append(data[k][i+2][3]) global_time.append(data[k][i+2][6]) distance_to_obstacles[k].append(data[k][i+2][7]) - + print("CPU ",CPU) + print(len(CPU)) + print("CPU global ",global_CPU) + print("x points",x_points) + print(len(x_points)) + print("y points",y_points) + print(len(y_points)) + print("xy points",xy_points) + print(len(xy_points)) + print("obstacles",distance_to_obstacles) + print("time ",time) # Convert the nested array into tuples to satisfy the requirment of Label() function of reportlab - for k in range(len(controller_type)*len(planner_type)): + for k in range(len(controller_type)*len(planner_type)*instances_num): CPU_data[k]=tuple(CPU_data[k]) Memory_data[k]=tuple(Memory_data[k]) xy_points[k]=tuple(xy_points[k]) @@ -158,39 +170,75 @@ def result(round_num): 'results', pdf_name+".pdf"),pagesize=A4) - + # PDF title d=shapes.Drawing(5,40) d.add(String(1,20,pdf_name,fontSize=20)) elements.append(d) - - - # A table summarize the results d=shapes.Drawing(250,40) d.add(String(1,20,"Comparsion of controllers",fontSize=15)) elements.append(d) analysis_data=[] + box_plot_data=[[],[],[],[],[],[],[]] for i in range(len(planner_type)): d=shapes.Drawing(250,40) d.add(String(1,20,"-Global planner: "+planner_type[i],fontSize=12,fontName= 'Times-Bold')) elements.append(d) - table= [["Controller\ntype","Result","Execution\nTime (sec)","CPU(%)","","Memory usage(%)","Memory usage (%)","Number of\nrecoveries","Path\nlength\n(m)","Proximity\nto\n obstacles(m)"]] + table= [["Controller\ntype","Success\n rate\n (%)","Average \nexecution\ntime (sec)","CPU(%)","","Memory usage(%)","Memory usage (%)","Average\nnumber of\nrecoveries","Average\n path\nlength(m)","Min\nproximity to\n obstacles(m)"]] table.append(["","","","Average","Max","Average","Max","","",""]) for k in range(len(controller_type)): + #a loop for each instance + instance_results=[] + instance_CPU=[] + instance_Memory=[] + instance_execution_time=[] + instance_path_length=[] + instance_recovery=[] + instance_obstacles=[] + for q in range(instances_num): + round_num=i*len(controller_type)*instances_num+k*instances_num+q + instance_results.append(result(round_num)) + instance_CPU+=CPU[round_num] + instance_Memory+=Memory[round_num] + instance_execution_time.append(data[round_num][len(data[round_num])-4][6]) + instance_path_length.append(round(path_length(round_num),2)) + instance_recovery.append(data[round_num][len(data[round_num])-4][4]) + instance_obstacles.append(min(distance_to_obstacles[round_num])) + box_plot_data[0].append(planner_type[i]+"\n"+controller_type[k]) + box_plot_data[1].append(instance_Memory) + box_plot_data[2].append(instance_CPU) + box_plot_data[3].append(instance_obstacles) + box_plot_data[4].append(instance_execution_time) + box_plot_data[5].append(instance_path_length) + box_plot_data[6].append(i*len(controller_type)+k+1) + print(instance_results) + print("CPU") + print(instance_CPU) + print("memory") + print(instance_Memory) + print("time") + print(instance_execution_time) + print("path") + print(instance_path_length) + print("recovery") + print(instance_recovery) + print("obstacles") + print(instance_obstacles) + + ## table_data=[] table_data.append(controller_type[k]) - round_num=len(controller_type)*i+k - table_data.append(result(round_num)) - table_data.append(str(data[round_num][len(data[round_num])-4][6])) #EDITNG for addin path - table_data.append(str('{0:.2f}'.format(sum(CPU[round_num])/len(CPU[round_num])))) - table_data.append(str(max(CPU[round_num]))) - table_data.append(str('{0:.2f}'.format(sum(Memory[round_num])/len(Memory[round_num])))) - table_data.append(str(max(Memory[round_num]))) - table_data.append(str(data[round_num][len(data[round_num])-4][4])) #EDITNG for addin path - table_data.append(str(round(path_length(round_num),2))) - table_data.append(str(min(distance_to_obstacles[round_num]))) + table_data.append(str(round((instance_results.count('succeeded')/len(instance_results))*100,2))) #success rate of this combination + table_data.append(str('{0:.2f}'.format(sum(instance_execution_time)/len(instance_execution_time)))) #Execution time + table_data.append(str('{0:.2f}'.format(sum(instance_CPU)/len(instance_CPU)))) # average CPU + table_data.append(str(max(instance_CPU))) #Max CPU + table_data.append(str('{0:.2f}'.format(sum(instance_Memory)/len(instance_Memory)))) #average Memory + table_data.append(str(max(instance_Memory))) #Max memory + table_data.append(str('{0:.2f}'.format(sum(instance_recovery)/len(instance_recovery)))) #Number of recoveries + table_data.append(str('{0:.2f}'.format(sum(instance_path_length)/len(instance_path_length)))) #Path length + table_data.append(str(min(instance_obstacles))) #Proximity to obstacles table.append(table_data) analysis_data.append(table) @@ -200,24 +248,19 @@ def result(round_num): ('SPAN',(0,0),(0,1)), ('SPAN',(1,0),(1,1)), ('SPAN',(2,0),(2,1)), - #('SPAN',(3,0),(3,1)), - #('SPAN',(4,0),(4,1)), - #('SPAN',(5,0),(5,1)), - #('SPAN',(6,0),(6,1)), ('SPAN',(7,0),(7,1)), ('SPAN',(8,0),(8,1)), ('SPAN',(9,0),(9,1)), ('SPAN',(3,0),(4,0)), ('SPAN',(5,0),(6,0)), ('FONTNAME',(0,0),(9,1),'Times-Bold'), - #('SPAN',(0,len(data)-1),(6,len(data)-1)), - #('FONTNAME',(0,len(data)-1),(6,len(data)-1),'Times-Bold'), ])) elements.append(t) # Performace analysis d=shapes.Drawing(250,70) d.add(String(1,40,"Performace analysis",fontSize=15)) elements.append(d) + print(analysis_data) ranking,planners_success_rate,controllers_success_rate=performance_analysis(criteria,analysis_data,weights,planner_type,controller_type) d.add(String(1,20,"Based on the criteria:" +", ".join(criteria),fontName= 'Times-Bold')) d=shapes.Drawing(250,20*(len(ranking)+1)) @@ -241,7 +284,33 @@ def result(round_num): for i in range(len(controllers_success_rate)): d.add(String(1,20*(row_increament),controllers_success_rate[i])) row_increament+=1 - elements.append(d) + print("--------------",box_plot_data[0]) + elements.append(d) + fig = plt.figure(figsize =(10, 12),constrained_layout=True) + plt.subplot(3,1,1).set_title ("Memory(%)",fontdict={'family':'serif','size':12}) + plt.boxplot(box_plot_data[1]) + plt.xticks(ticks =box_plot_data[6] ,labels = box_plot_data[0], rotation = 'horizontal',fontdict={'family':'serif','size':12}) + plt.subplot(3,1,2).set_title("CPU(%)",fontdict={'family':'serif','size':12}) + plt.boxplot(box_plot_data[2]) + plt.xticks(ticks =box_plot_data[6] ,labels = box_plot_data[0], rotation = 'horizontal',fontdict={'family':'serif','size':12}) + plt.subplot(3,1,3).set_title ("Proximity to obstacles(m)",fontdict={'family':'serif','size':12}) + plt.boxplot(box_plot_data[3]) + plt.xticks(ticks = box_plot_data[6],labels = box_plot_data[0], rotation = 'horizontal',fontdict={'family':'serif','size':12}) + plt.savefig(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data','graph_box_plot.png')) + elements.append(Image_pdf(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data','graph_box_plot.png'),500,600)) + fig = plt.figure(figsize =(10, 8),constrained_layout=True) + plt.subplot(2,1,1).set_title ("Time (sce)",fontdict={'family':'serif','size':12}) + plt.boxplot(box_plot_data[4]) + plt.xticks(ticks =box_plot_data[6] ,labels = box_plot_data[0], rotation ='horizontal',fontdict={'family':'serif','size':12}) + plt.subplot(2,1,2).set_title ("Path Length (m)",fontdict={'family':'serif','size':12}) + plt.boxplot(box_plot_data[5]) + plt.xticks(ticks = box_plot_data[6] ,labels = box_plot_data[0], rotation = 'horizontal',fontdict={'family':'serif','size':12}) + plt.savefig(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data','graph_box_plot2.png')) + elements.append(Image_pdf(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data','graph_box_plot2.png'),500,400)) d=shapes.Drawing(250,55) d.add(String(1,20,"Graphs",fontSize=15)) elements.append(d) @@ -263,96 +332,113 @@ def result(round_num): for i in range(0, r): l = LineSwatch() l.strokeColor = getattr(colors, items[i+v]) - if trails_num>0: - cnp.append((l, controller_type[i+v]+' #'+str(i+1+v))) - else: - cnp.append((l, controller_type[i+v])) + + cnp.append((l, controller_type[i+v])) legend.colorNamePairs = cnp legend_list.append(legend) #d.add(legend, 'legend') #elements.append(d) drawing = shapes.Drawing(500, 10) elements.append(drawing) - for k in range(len(planner_type)): - # CPU plot - drawing = shapes.Drawing(500, 290) - lab=Label() - lab.setOrigin(0,130) - lab.angle=90 - lab.setText('CPU(%)') - lp = LinePlot() - lp.x = 40 - lp.y = 35 - lp.height = 220 - lp.width = 450 - CPU_data_plot=[] - for i in range(len(controller_type)): - CPU_data_plot.append(CPU_data[len(controller_type)*k+i]) + #Finding a mean line and the probabilty region + def interpolate_trajectory(x, y, num_points): + # Create a cumulative distance array as reference + distance = np.cumsum(np.sqrt(np.ediff1d(x, to_begin=0)**2 + np.ediff1d(y, to_begin=0)**2)) + print("distance",distance) + distance = distance / distance[-1] # Normalize distance to [0,1] - lp.data = CPU_data_plot - lp.joinedLines = 1 - for i in range(len(controller_type)): - lp.lines[i].strokeColor=getattr(colors, items[i]) + # Interpolate using the distance as reference + fx = interp1d(distance, x, kind='linear') + fy = interp1d(distance, y, kind='linear') - lp.strokeColor = colors.black - lp.xValueAxis.valueMin = 0 - lp.xValueAxis.valueMax = max(global_time) - lp.xValueAxis.configure(global_time) - lp.xValueAxis.labelTextFormat = '%2.1f' - lp.yValueAxis.valueMin = 0 - lp.yValueAxis.valueMax=100 - lp.yValueAxis.configure(global_CPU) - drawing.add(String(1,280,"-Global planner: "+planner_type[k],fontSize=12,fontName= 'Times-Bold')) - drawing.add(String(200,270,'CPU usage(%) ', fontSize=12, fillColor=colors.black)) - drawing.add(lab) - drawing.add(lp) - drawing.add(String(200,5,'Time(sec) ', fontSize=12, fillColor=colors.black)) - elements.append(drawing) - for r in range(len(legend_list)): - d = Drawing(500, 30) - d.add(legend_list[r], 'legend') - elements.append(d) - # Memory usage plot - for k in range(len(planner_type)): - drawing = shapes.Drawing(500, 290) - lab=Label() - lab.setOrigin(0,130) - lab.angle=90 - lab.setText('Memory') - lp = LinePlot() - lp.x = 40 - lp.y = 35 - lp.height = 220 - lp.width = 450 - Memory_data_plot=[] - for i in range(len(controller_type)): - Memory_data_plot.append(Memory_data[len(controller_type)*k+i]) - lp.data = Memory_data_plot - lp.joinedLines = 1 - for i in range(len(controller_type)): - lp.lines[i].strokeColor=getattr(colors, items[i]) - lp.strokeColor = colors.black - lp.xValueAxis.valueMin = 0 - lp.xValueAxis.valueMax = max(global_time) - lp.xValueAxis.configure(global_time) - lp.xValueAxis.labelTextFormat = '%2.1f' - lp.yValueAxis.valueMin = 0 - lp.yValueAxis.valueMax = 100 - lp.yValueAxis.configure(global_Memory) - drawing.add(String(1,280,"-Global planner: "+planner_type[k],fontSize=12,fontName= 'Times-Bold')) - drawing.add(String(200,270,'Memory usage', fontSize=12, fillColor=colors.black)) - drawing.add(lab) - drawing.add(lp) - drawing.add(String(200,5,'Time(sec) ', fontSize=12, fillColor=colors.black)) + # New normalized distance values + new_distances = np.linspace(0, 1, num_points) + return fx(new_distances), fy(new_distances) + + def mean_line(x_arrays,y_arrays): + new_x_array=[] + new_y_array=[] + arrays_length=[] + for i in range(len(x_arrays)): + arrays_length.append(len(x_arrays[i])) + print(arrays_length) + points_num=max(arrays_length) + print(points_num) + for i in range(len(x_arrays)): + new_x,new_y=interpolate_trajectory(x_arrays[i], y_arrays[i], points_num) + new_x_array.append(new_x) + new_y_array.append(new_y) + + x_mean=np.mean(new_x_array,axis=0) + y_mean=np.mean(new_y_array,axis=0) + std=np.std(new_y_array,axis=0) + return x_mean,y_mean,std + #CPU plot + #Oter loop prodcuce new graph + for i in range(len(planner_type)): + # start the graph + plt.figure(figsize=(10, 4)) + plt.ylim(0,100) + labels_list=[] + labels_tag=[] + #inner loop plot a new line + for k in range(len(controller_type)): + round_num=i*len(controller_type)*instances_num+k*instances_num + CPU_array=CPU[round_num:round_num+instances_num] + time_array=time[round_num:round_num+instances_num] + print("CPU_array",CPU_array) + print("time_array",time_array) + + #Shaded area or dots of actual lines + # for q in range(instances_num): + # actual_points,=plt.plot(time_array[q],CPU_array[q],color=items[k] ,linestyle='dotted',alpha=0.3) + + mean_time,mean_CPU,std=mean_line(time_array,CPU_array) + lmean,=plt.plot(mean_time,mean_CPU,label=planner_type[i]+" "+controller_type[k],color=items[k]) + lsigma=plt.fill_between(mean_time, mean_CPU-std,mean_CPU+std,color=items[k], alpha=0.2) + labels_list.append((lmean,lsigma)) + labels_tag.append(controller_type[k]+" Mean +/- stdev") + #labels_list.append(actual_points) + #labels_tag.append("Actual CPU") + + plt.legend(labels_list,labels_tag,prop={'family':'serif','size':8}) + plt.xlabel('Time(sec)',fontdict={'family':'serif','size':12}) + plt.ylabel('CPU (%)',fontdict={'family':'serif','size':12}) + #save the graph + plt.savefig(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data','CPU_plot'+str(i)+'.png')) + + # CPU plot + drawing = shapes.Drawing(500, 30) + drawing.add(String(1,20,"-Global planner: "+planner_type[i],fontSize=12,fontName= 'Times-Bold')) + drawing.add(String(200,10,'CPU usage(%) ', fontSize=12, fillColor=colors.black)) elements.append(drawing) - for r in range(len(legend_list)): - d = Drawing(500, 30) - d.add(legend_list[r], 'legend') - elements.append(d) + # insert the graph to pdf + elements.append(Image_pdf(os.path.join(get_package_share_directory('ROSNavBench'), + 'raw_data','CPU_plot'+str(i)+'.png'),500,200)) + # Trajectory plot #Trajectory plot on map image # Open map yaml file and extact data - for k in range(len(planner_type)): + #new + if trajectory_type=="circle": + r= robot_specs['radius'] + waypoints_array=circle_points(x,y,r) + elif trajectory_type=="several_waypoints": + waypoints_array=robot_specs['waypoints'] + elif trajectory_type=="square": + side_length=robot_specs['side_length'] + waypoints_array=square_points(x,y,side_length) + elif trajectory_type=="one_goal": + waypoints_array=[[robot_specs['goal_pose_x'],robot_specs['goal_pose_y']]] + x_trajectory=[] + y_trajectory=[] + # plot the waypoints + for i in range(len(waypoints_array)): + x_trajectory.append(waypoints_array[i][0]) + y_trajectory.append(waypoints_array[i][1]) + for i in range(len(planner_type)): + # start the graph with open(map_path, 'r') as file: map_specs = yaml.safe_load(file) @@ -365,52 +451,79 @@ def result(round_num): y_length=len(numpydata[0]) # width img=plt.imread(map_png_path) fig, ax=plt.subplots() - ax.imshow(img,cmap=plt.cm.gray,extent=[origin[0],0.05*y_length+origin[0],origin[1],0.05*x_length+origin[1]]) - if trajectory_type=="circle": - r= robot_specs['radius'] - waypoints_array=circle_points(x,y,r) - elif trajectory_type=="several_waypoints": - waypoints_array=robot_specs['waypoints'] - elif trajectory_type=="square": - side_length=robot_specs['side_length'] - waypoints_array=square_points(x,y,side_length) - elif trajectory_type=="one_goal": - waypoints_array=[[robot_specs['goal_pose_x'],robot_specs['goal_pose_y']]] - - x_trajectory=[] - y_trajectory=[] - # plot the waypoints - for i in range(len(waypoints_array)): - x_trajectory.append(waypoints_array[i][0]) - y_trajectory.append(waypoints_array[i][1]) - plt.scatter(x_trajectory,y_trajectory,marker='*',c='yellowgreen') - # plot the trajectory of each controller - for p in range(len(controller_type)): - round_num=len(controller_type)*k+p - plt.plot(x_points[round_num],y_points[round_num],c=items[p]) - plt.plot(x_points[round_num][len(x_points[round_num])-1],y_points[round_num][len(y_points[round_num])-1],c=items[p],marker='o', ms=10) - - plt.xlabel('x-axis (meters)',fontdict={'family':'serif','size':12}) - plt.ylabel('y-axis (meters)',fontdict={'family':'serif','size':12}) - # Plot the initial pose - if trajectory_type=="circle": - plt.plot(x+r,y,marker='*',c='yellowgreen',ms=13) + print("-----------------x is ",x_length,"-----------y is ",y_length) + labels_list=[] + labels_tag=[] + if y_length + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/btNavFn_RPP.xml b/example/turtlebot3/behavior_trees/btNavFn_RPP.xml new file mode 100644 index 0000000..6d9f1a4 --- /dev/null +++ b/example/turtlebot3/behavior_trees/btNavFn_RPP.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml new file mode 100644 index 0000000..1151bea --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml new file mode 100644 index 0000000..1e6e8e0 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml new file mode 100644 index 0000000..ea5b6d4 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml new file mode 100644 index 0000000..4b5b1b1 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml b/example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml new file mode 100644 index 0000000..6ec88cc --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml b/example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml new file mode 100644 index 0000000..6d9f1a4 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml b/example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml new file mode 100644 index 0000000..62e1eff --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml new file mode 100644 index 0000000..d15d42c --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml new file mode 100644 index 0000000..8d30863 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml new file mode 100644 index 0000000..45f7b62 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml new file mode 100644 index 0000000..e57786a --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml new file mode 100644 index 0000000..86dd4d3 --- /dev/null +++ b/example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml b/example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml new file mode 100644 index 0000000..45f7b62 --- /dev/null +++ b/example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml b/example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml new file mode 100644 index 0000000..e57786a --- /dev/null +++ b/example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/pose.xml b/example/turtlebot3/behavior_trees/pose.xml index 4c2be4c..4f853f9 100644 --- a/example/turtlebot3/behavior_trees/pose.xml +++ b/example/turtlebot3/behavior_trees/pose.xml @@ -1,9 +1,4 @@ - @@ -11,12 +6,18 @@ - + + + + - - + + + + + @@ -28,7 +29,7 @@ - + diff --git a/example/turtlebot3/behavior_trees/poses.xml b/example/turtlebot3/behavior_trees/poses.xml index 1f4f15d..e8df1e5 100644 --- a/example/turtlebot3/behavior_trees/poses.xml +++ b/example/turtlebot3/behavior_trees/poses.xml @@ -5,15 +5,21 @@ - - + + - + + + + - - - + + + + + + @@ -25,9 +31,9 @@ - + - \ No newline at end of file + diff --git a/example/turtlebot3/behavior_trees/posses.xml b/example/turtlebot3/behavior_trees/posses.xml new file mode 100644 index 0000000..e8df1e5 --- /dev/null +++ b/example/turtlebot3/behavior_trees/posses.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/turtlebot3/nav2_config/waffle.yaml b/example/turtlebot3/nav2_config/waffle.yaml index 8c655de..16b1546 100644 --- a/example/turtlebot3/nav2_config/waffle.yaml +++ b/example/turtlebot3/nav2_config/waffle.yaml @@ -106,7 +106,7 @@ controller_server: failure_tolerance: 0.3 progress_checker_plugin: "progress_checker" goal_checker_plugins: ["general_goal_checker"] - controller_plugins: ["MPPI","DWB_RSC","RPP", "DWB", "RPP_RSC"] + controller_plugins: ["MPPI","DWB_RSC","RPP", "DWB", "RPP_RSC","DWB_1","DWB_2"] # Progress checker parameters progress_checker: @@ -238,7 +238,86 @@ controller_server: RotateToGoal.scale: 32.0 RotateToGoal.slowing_factor: 5.0 RotateToGoal.lookahead_time: -1.0 + + DWB_1: + plugin: "dwb_core::DWBLocalPlanner" + debug_trajectory_details: True + min_vel_x: 0.0 + min_vel_y: 0.0 + max_vel_x: 0.22 + max_vel_y: 0.0 + max_vel_theta: 1.0 + min_speed_xy: 0.0 + max_speed_xy: 0.22 + min_speed_theta: 0.0 + acc_lim_x: 2.5 + acc_lim_y: 0.0 + acc_lim_theta: 3.2 + decel_lim_x: -2.5 + decel_lim_y: 0.0 + decel_lim_theta: -3.2 + vx_samples: 20 + vy_samples: 0 + vtheta_samples: 40 + sim_time: 1.5 + linear_granularity: 0.05 + angular_granularity: 0.025 + transform_tolerance: 0.2 + xy_goal_tolerance: 0.25 + trans_stopped_velocity: 0.25 + short_circuit_trajectory_evaluation: True + stateful: True + critics: ["RotateToGoal", "Oscillation", "BaseObstacle", "GoalAlign", "PathAlign", "PathDist", "GoalDist"] + BaseObstacle.scale: 0.02 + PathAlign.scale: 32.0 + PathAlign.forward_point_distance: 0.1 + GoalAlign.scale: 24.0 + GoalAlign.forward_point_distance: 0.1 + PathDist.scale: 32.0 + GoalDist.scale: 24.0 + RotateToGoal.scale: 32.0 + RotateToGoal.slowing_factor: 5.0 + RotateToGoal.lookahead_time: -1.0 + DWB_2: + plugin: "dwb_core::DWBLocalPlanner" + debug_trajectory_details: True + min_vel_x: 0.0 + min_vel_y: 0.0 + max_vel_x: 0.22 + max_vel_y: 0.0 + max_vel_theta: 1.0 + min_speed_xy: 0.0 + max_speed_xy: 0.22 + min_speed_theta: 0.0 + acc_lim_x: 2.5 + acc_lim_y: 0.0 + acc_lim_theta: 3.2 + decel_lim_x: -2.5 + decel_lim_y: 0.0 + decel_lim_theta: -3.2 + vx_samples: 20 + vy_samples: 0 + vtheta_samples: 40 + sim_time: 3.0 + linear_granularity: 0.05 + angular_granularity: 0.025 + transform_tolerance: 0.2 + xy_goal_tolerance: 0.25 + trans_stopped_velocity: 0.25 + short_circuit_trajectory_evaluation: True + stateful: True + critics: ["RotateToGoal", "Oscillation", "BaseObstacle", "GoalAlign", "PathAlign", "PathDist", "GoalDist"] + BaseObstacle.scale: 0.02 + PathAlign.scale: 32.0 + PathAlign.forward_point_distance: 0.1 + GoalAlign.scale: 24.0 + GoalAlign.forward_point_distance: 0.1 + PathDist.scale: 32.0 + GoalDist.scale: 24.0 + RotateToGoal.scale: 32.0 + RotateToGoal.slowing_factor: 5.0 + RotateToGoal.lookahead_time: -1.0 # Controller 4: RPP_RSC RPP_RSC: plugin: "nav2_rotation_shim_controller::RotationShimController" @@ -271,18 +350,20 @@ controller_server: use_interpolation: false - MPPI: +############# + + MPPI: plugin: "nav2_mppi_controller::MPPIController" time_steps: 56 model_dt: 0.05 batch_size: 2000 - vx_std: 0.2 + vx_std: 0.22 vy_std: 0.2 wz_std: 0.4 - vx_max: 0.5 + vx_max: 0.22 vx_min: -0.35 - vy_max: 0.5 - wz_max: 1.9 + vy_max: 0.0 + wz_max: 1.0 iteration_count: 1 prune_distance: 1.7 transform_tolerance: 0.1 @@ -290,10 +371,12 @@ controller_server: gamma: 0.015 motion_model: "DiffDrive" visualize: false + reset_period: 1.0 # (only in Humble) + regenerate_noises: false TrajectoryVisualizer: trajectory_step: 5 time_step: 3 - AckermannConstrains: + AckermannConstraints: min_turning_r: 0.2 critics: ["ConstraintCritic", "ObstaclesCritic", "GoalCritic", "GoalAngleCritic", "PathAlignCritic", "PathFollowCritic", "PathAngleCritic", "PreferForwardCritic"] ConstraintCritic: @@ -324,6 +407,8 @@ controller_server: collision_cost: 10000.0 collision_margin_distance: 0.1 near_goal_distance: 0.5 + inflation_radius: 0.55 # (only in Humble) + cost_scaling_factor: 10.0 # (only in Humble) PathAlignCritic: enabled: true cost_power: 1 @@ -346,11 +431,12 @@ controller_server: offset_from_furthest: 4 threshold_to_consider: 0.5 max_angle_to_furthest: 1.0 - forward_preference: true + mode: 0 # TwirlingCritic: # enabled: true # twirling_cost_power: 1 # twirling_cost_weight: 10.0 + controller_server_rclcpp_node: ros__parameters: use_sim_time: true diff --git a/launch/main.launch.py b/launch/main.launch.py index 37d5537..5e16e05 100644 --- a/launch/main.launch.py +++ b/launch/main.launch.py @@ -25,11 +25,6 @@ def generate_launch_description(): # Get the name of config file of the current experiment specs = os.environ['PARAMS_FILE'] # Opening the config file to take the experiment data such as spawn pose - # specs= os.path.join( - # get_package_share_directory('ROSNavBench'), - # 'config', - # params_file+'.yaml' - # ) with open(specs, 'r') as file: robot_specs = yaml.safe_load(file) @@ -39,19 +34,10 @@ def generate_launch_description(): y = robot_specs['spawn_pose_y'] yaw = robot_specs['spawn_pose_yaw'] trajectory_type = robot_specs['trajectory_type'] - trails_num = robot_specs['trails_num'] - if trails_num>0: - controller_type=[controller_type[0]]*trails_num - planner_type=[planner_type[0]] - # Node for generating pdf - pdf_generator=Node( - name='benchmarking_single_controller', - executable='benchmarking_single_controller', - package='ROSNavBench', - ) - else: - # Node for generating pdf - pdf_generator=Node( + instances_num= robot_specs['instances_num'] + + # Node for generating pdf + pdf_generator=Node( name='main_pdf_generator', executable='main_pdf_generator', package='ROSNavBench', @@ -83,7 +69,7 @@ def generate_launch_description(): ld.add_action(SetEnvironmentVariable(name='round_num',value="1")) # Generating different nodes to publish the type of running controller controller_node=[] - for j in range(len(controller_type)*len(planner_type)): + for j in range(len(controller_type)*len(planner_type)*instances_num): controller_node.append(Node( name='marker_publisher', executable='marker_publisher', @@ -91,7 +77,7 @@ def generate_launch_description(): )) # Generating different nodes for sending the goal and recording the data nodes=[] - for j in range(len(controller_type)*len(planner_type)): + for j in range(len(controller_type)*len(planner_type)*instances_num): nodes.append(Node( name='follow_path_0', executable='follow_path', @@ -99,7 +85,7 @@ def generate_launch_description(): )) # Generating different nodes for reseting the pose of the robot to intial pose after each controller scenario state_nodes=[] - for k in range(len(controller_type)*len(planner_type)-1): + for k in range(len(controller_type)*len(planner_type)*instances_num-1): state_nodes.append(ExecuteProcess( cmd=[[ FindExecutable(name='ros2'), @@ -112,23 +98,20 @@ def generate_launch_description(): ) ) - # This loop is responsible for assgining the events of sending the goal and reseting the state - # Each event will start once the previous event is done +# Each event will start once the previous event is done for k in range(len(planner_type)): for i in range(len(controller_type)): - if i==0 and k==0: - ld.add_action(nodes[0]) - ld.add_action(controller_node[0]) - else: - if k==0: - increament=i-1 + for q in range(instances_num): + if i==0 and k==0 and q==0: + ld.add_action(nodes[0]) + ld.add_action(controller_node[0]) else: - increament=len(controller_type)*k+i-1 - ld.add_action(RegisterEventHandler(OnProcessExit(target_action= nodes[increament], on_exit=[state_nodes[increament]]))) #edit - ld.add_action(RegisterEventHandler(OnProcessExit(target_action=state_nodes[increament], on_exit=[SetEnvironmentVariable(name='planner',value=planner_type[k]),SetEnvironmentVariable(name='controller',value=controller_type[i]),SetEnvironmentVariable(name='round_num',value=str(increament+2)),nodes[increament+1],controller_node[increament+1]]))) + increament=k*len(controller_type)*instances_num+i*instances_num+q-1 + ld.add_action(RegisterEventHandler(OnProcessExit(target_action= nodes[increament], on_exit=[state_nodes[increament]]))) #edit + ld.add_action(RegisterEventHandler(OnProcessExit(target_action=state_nodes[increament], on_exit=[SetEnvironmentVariable(name='planner',value=planner_type[k]),SetEnvironmentVariable(name='controller',value=controller_type[i]),SetEnvironmentVariable(name='round_num',value=str(increament+2)),nodes[increament+1],controller_node[increament+1]]))) # Once all events are done, the node of generating a pdf will start - ld.add_action(RegisterEventHandler(OnProcessExit(target_action=nodes[len(controller_type)*len(planner_type)-1], on_exit=[pdf_generator] ))) + ld.add_action(RegisterEventHandler(OnProcessExit(target_action=nodes[len(controller_type)*len(planner_type)*instances_num-1], on_exit=[pdf_generator] ))) return ld From 4e70a7118781bf8000ed46035bb19afc535a854e Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Wed, 1 Nov 2023 09:27:45 +0300 Subject: [PATCH 2/8] Delete ROSNavBench/benchmarking_single_controller.py --- ROSNavBench/benchmarking_single_controller.py | 533 ------------------ 1 file changed, 533 deletions(-) delete mode 100644 ROSNavBench/benchmarking_single_controller.py diff --git a/ROSNavBench/benchmarking_single_controller.py b/ROSNavBench/benchmarking_single_controller.py deleted file mode 100644 index ac45b67..0000000 --- a/ROSNavBench/benchmarking_single_controller.py +++ /dev/null @@ -1,533 +0,0 @@ -#! /usr/bin/env python3 -import numpy as np -import yaml -import csv -import os -import math -from ament_index_python.packages import get_package_share_directory -from reportlab.lib.pagesizes import inch, letter, A4 -from reportlab.graphics import shapes -from reportlab.graphics.shapes import * -from reportlab.graphics.charts.axes import XCategoryAxis, YCategoryAxis -from reportlab.graphics.charts.lineplots import LinePlot -from reportlab.graphics.charts.textlabels import Label -from reportlab.graphics.widgets.markers import makeMarker -from reportlab.platypus import SimpleDocTemplate, Table, TableStyle -from reportlab.lib import colors -from reportlab.lib.styles import ParagraphStyle, getSampleStyleSheet -from reportlab.lib.enums import TA_CENTER -from reportlab.graphics.charts.legends import Legend, LineLegend, LineSwatch -from reportlab.graphics.charts.barcharts import VerticalBarChart -from matplotlib import pyplot as plt -from PIL import Image -from numpy import asarray -from reportlab.platypus import Image as Image_pdf -from ROSNavBench.follow_path import circle_points,square_points -from ROSNavBench.performace_analysis import performance_analysis_repeatability - -def main(): - ''' - The function performs the following: - 1. Take the data form csv files of the exeriment, and arrange data into arrays - 2. Perform analysis of data such as fining the average and max of CPU - 3. Gnerating plots - 4. Generating a report in form of pdf - ''' - # Functions used inside main() function - - def path_length(controller_number): - ''' - Calculate the path taken through adding the distance between each two consective - The euclidean distance formula is used. - - Args: - controller_number: Specify which controller by giving the place of the controller in the list - E.g., xy_points=[[x points for the 1st controller],[x points for the 2nd controller],...] - - Returns: - A path length in decimal form - ''' - path=0 - for j in range(len(xy_points[controller_number])-1): - path+=math.sqrt(np.square(xy_points[controller_number][j+1][0]-xy_points[controller_number][j][0])+np.square(xy_points[controller_number][j+1][1]-xy_points[controller_number][j][1])) - - return path - - def generate_list(min_val,max_val,step_size): - ''' - Generating a list of values between max and min value with a specfic increament - - Args: - min_value: minimum value in the list - max_value: maximum value in the list - step_size: increment for each element in the list - Returns: - A list - ''' - generated_list=[] - current_val=min_val - while current_val<=max_val: - generated_list.append(current_val) - current_val+=step_size - return generated_list - - #CPU of all trails - def axis_scalling(min_val,max_val,value): - ''' - Generate a min or a max value for scalling the axis in the plot. - It alters the min or max value by 1 if the difference between the max and min value is minor. - As a result, the plot will be well poltted and not represents the minor varition in CPU or trajectoy poses. - - Args: - min_val: minimum value of the plotted axis - max_val: maximum value of the plotted axis - value: 1 for finding the min value, 0 for finding the max value - - Returns: - min_value or max_value - ''' - difference=max_val-min_val - if value==0: #for max value - if difference<1: - max_val=max_val+1 - return max_val - elif value==1: #for min val - if difference<1: - min_val=min_val-1 - return min_val - # Create a matrix of specifc size - def create_matrix(cols): - return ["" for _ in range(cols)] - # Get the name of config file of the current experiment - specs = os.environ['PARAMS_FILE'] - # Open config file and extact data - with open(specs, 'r') as file: - robot_specs = yaml.safe_load(file) - - pdf_name=robot_specs['experiment_name'] - trails_num = robot_specs['trails_num'] - controller_type=robot_specs['controller_type'] - planner_type=robot_specs['planner_type'] - results_directory=robot_specs['results_directory'] - x = robot_specs['spawn_pose_x'] - y = robot_specs['spawn_pose_y'] - map_path=robot_specs['map_path'] - map_png_path=robot_specs['map_png_path'] - trajectory_type= robot_specs['trajectory_type'] - trails_num = robot_specs['trails_num'] - if trails_num>0: - controller_type=[controller_type[0]]*trails_num - # list of arrays to hold data of experiment - # This is a way to arrange data to be used for analysis and ploting - controller_num=len(controller_type) - data=[] - summary=[] - CPU=[] - Memory=[] - CPU_data=[] - Memory_data=[] - xy_points=[] - x_points=[] - y_points=[] - time=[] - global_CPU=[] - global_Memory=[] - global_x_points=[] - global_y_points=[] - global_time=[] - distance_to_obstacles=[] - global_distance_to_obstacles=[] - # nested arrays equal to number of controllers - # E.g., x_points=[[x points for the 1st controller],[x points for the 2nd controller],...] - for i in range(len(controller_type)): - data.append([]) - #log_msgs.append([]) - CPU.append([]) - Memory.append([]) - CPU_data.append([]) - Memory_data.append([]) - xy_points.append([]) - x_points.append([]) - y_points.append([]) - time.append([]) - distance_to_obstacles.append([]) - # open each csv file for the different used controllers, and add all data to data array - for i in range(len(controller_type)): - f=open(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data', - pdf_name+'_'+controller_type[i]+planner_type[0]+str(i+1)+'.csv'),'r') - writer=csv.reader(f,quoting=csv.QUOTE_NONNUMERIC,delimiter=' ') - for lines in writer: - data[i].append(lines[:]) - - - # Extarct data from data array and arrange them into different arrays - for k in range(len(controller_type)): - for i in range(len(data[k])-5): - CPU[k].append(data[k][i+2][0]) - Memory[k].append(data[k][i+2][1]) - time[k].append(data[k][i+2][6]) - x_points[k].append(data[k][i+2][2]) - y_points[k].append(data[k][i+2][3]) - CPU_data[k].append((data[k][i+2][6],data[k][i+2][0])) - Memory_data[k].append((data[k][i+2][6],data[k][i+2][1])) - xy_points[k].append((data[k][i+2][2],data[k][i+2][3])) - global_CPU.append(data[k][i+2][0]) - global_Memory.append(data[k][i+2][1]) - global_x_points.append(data[k][i+2][2]) - global_y_points.append(data[k][i+2][3]) - global_time.append(data[k][i+2][6]) - distance_to_obstacles[k].append(data[k][i+2][7]) - global_distance_to_obstacles.append(data[k][i+2][7]) - - # Convert the nested array into tuples to satisfy the requirment of Label() function of reportlab - for k in range(len(controller_type)): - CPU_data[k]=tuple(CPU_data[k]) - Memory_data[k]=tuple(Memory_data[k]) - xy_points[k]=tuple(xy_points[k]) - # Extracting the result as a string from data array - def result(controller_num): - result='' - for i in range(len(data[controller_num][len(data[controller_num])-3])): - result+=data[controller_num][len(data[controller_num])-3][i] - return result - # Generating the pdf - elements=[] - if results_directory!='': - doc=SimpleDocTemplate(os.path.join(results_directory, - pdf_name+".pdf"),pagesize=A4) - else: - doc=SimpleDocTemplate(os.path.join(get_package_share_directory('ROSNavBench'), - 'results', - pdf_name+".pdf"),pagesize=A4) - d=shapes.Drawing(5,40) - d.add(String(1,20,pdf_name,fontSize=20)) - elements.append(d) - - d=shapes.Drawing(250,40) - d.add(String(1,20,"Comparsion of controllers",fontSize=15)) - elements.append(d) - d=shapes.Drawing(250,40) - d.add(String(1,20,"-Global planner: "+planner_type[0],fontSize=12,fontName= 'Times-Bold')) - elements.append(d) - table= [["Controller\ntype","Result","Execution\nTime (sec)","CPU(%)","","Memory usage(%)","Memory usage (%)","Number of\nrecoveries","Path\nlength\n(m)","Proximity\nto\n obstacles(m)"]] - table.append(["","","","Average","Max","Average","Max","","",""]) - for k in range(len(controller_type)): - table_data=[] - if trails_num>0: - table_data.append(controller_type[k]+' #'+str(k+1)) - else: - table_data.append(controller_type[k]) - table_data.append(result(k)) - table_data.append(str(data[k][len(data[k])-4][6])) - table_data.append(str('{0:.2f}'.format(sum(CPU[k])/len(CPU[k])))) - table_data.append(str(max(CPU[k]))) - table_data.append(str('{0:.2f}'.format(sum(Memory[k])/len(Memory[k])))) - table_data.append(str(max(Memory[k]))) - table_data.append(str(data[k][len(data[k])-4][4])) - table_data.append(str(round(path_length(k),2))) - table_data.append(str(min(distance_to_obstacles[k]))) - table.append(table_data) - - - t=Table(table) - t.setStyle(TableStyle([('INNERGRID',(0,0), (-1,-1), 0.25, colors.black), - ('BOX',(0,0), (-1,-1), 0.25, colors.black), - ('SPAN',(0,0),(0,1)), - ('SPAN',(1,0),(1,1)), - ('SPAN',(2,0),(2,1)), - ('SPAN',(7,0),(7,1)), - ('SPAN',(8,0),(8,1)), - ('SPAN',(9,0),(9,1)), - ('SPAN',(3,0),(4,0)), - ('SPAN',(5,0),(6,0)), - ('FONTNAME',(0,0),(9,1),'Times-Bold'), - ])) - elements.append(t) - # Performace analysis - data_variation,success_rate,time_11,path_11=performance_analysis_repeatability([table],planner_type,controller_type) - d=shapes.Drawing(250,55) - d.add(String(1,20,"Graphs",fontSize=15)) - elements.append(d) - - for j in range(math.ceil(len(controller_type)/8)): - d = Drawing(500, 50) - v=j*8 - legend = LineLegend() - legend.alignment = 'right' - legend.x = 1 - legend.y = 40 - legend.deltax = 60 - legend.dxTextSpace = 10 - legend.columnMaximum = 1 - items = 'red green blue yellow pink black aqua bisque blueviolet brown burlywood cadetblue chartreuse chocolate cornflowerblue crimson cyan darkblue darkcyan darkgoldenrod darkgray coral darkgreen darkkhaki darkmagenta darkolivegreen darkorange darkred darksalmon darkseagreen darkslateblue darkslategray darkturquoise darkviolet deeppink deepskyblue dimgray firebrick forestgreen fuchsia grey greenyellow gold hotpink indianred ivory lavender lime maroon navy olive'.split() - cnp = [] - r=8 - if j==(math.ceil(len(controller_type)/8)-1) and len(controller_type)%8!=0: - r=len(controller_type)%8 - for i in range(0, r): - l = LineSwatch() - l.strokeColor = getattr(colors, items[i+v]) - if trails_num>0: - cnp.append((l, controller_type[i+v]+' #'+str(i+1+v))) - else: - cnp.append((l, controller_type[i+v])) - legend.colorNamePairs = cnp - d.add(legend, 'legend') - #elements.append(d) - # Box plot - - data_1 = global_Memory - data_2 = global_CPU - data_3 = global_distance_to_obstacles - data_4 = time_11 - data_5 =path_11 - - fig = plt.figure(figsize =(10, 6)) - plt.subplots_adjust(wspace= 0.75) - plt.subplot(1,5,1) - plt.boxplot(data_1) - plt.xticks(ticks = [1] ,labels = ["Memory (%)"], rotation = 'horizontal',fontdict={'family':'serif','size':12}) - plt.subplot(1,5,2) - plt.boxplot(data_2) - plt.xticks(ticks = [1] ,labels = ["CPU (%)"], rotation = 'horizontal',fontdict={'family':'serif','size':12}) - plt.subplot(1,5,3) - plt.boxplot(data_3) - plt.xticks(ticks = [1] ,labels = ["Proximity to\n obstcales (m)"], rotation = 'horizontal',fontdict={'family':'serif','size':12}) - plt.subplot(1,5,4) - plt.boxplot(data_4) - plt.xticks(ticks = [1] ,labels = ["Time (sec)"], rotation = 'horizontal',fontdict={'family':'serif','size':12}) - plt.subplot(1,5,5) - plt.boxplot(data_5) - plt.xticks(ticks = [1] ,labels = ["Path \nLength (m)"], rotation = 'horizontal',fontdict={'family':'serif','size':12}) - plt.savefig(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data','graph_box_plot.png')) - drawing = shapes.Drawing(500,10) - drawing.add(String(200,10,'Performace analysis ', fontSize=12, fillColor=colors.black)) - elements.append(drawing) - elements.append(Image_pdf(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data','graph_box_plot.png'),500,300)) - - # CPU plot - legend = LineLegend() - legend.alignment = 'right' - legend.x = 1 - legend.y = 270 - legend.deltax = 60 - legend.dxTextSpace = 10 - legend.columnMaximum = 1 - items = 'red blue yellow pink black aqua bisque blueviolet brown burlywood cadetblue chartreuse chocolate cornflowerblue crimson cyan green darkblue darkcyan darkgoldenrod darkgray coral darkgreen darkkhaki darkmagenta darkolivegreen darkorange darkred darksalmon darkseagreen darkslateblue darkslategray darkturquoise darkviolet deeppink deepskyblue dimgray firebrick forestgreen fuchsia grey greenyellow gold hotpink indianred ivory lavender lime maroon navy olive'.split() - cnp = [] - l = LineSwatch() - l.strokeColor = getattr(colors, items[0]) - cnp.append((l, "Max CPU")) - l = LineSwatch() - l.strokeColor = getattr(colors, items[1]) - cnp.append((l, "Average CPU")) - legend.colorNamePairs = cnp - - - drawing = Drawing(500, 310) - lab=Label() - lab.setOrigin(0,130) - lab.angle=90 - lab.setText('CPU(%)') - plot_data=[[],[]] - for i in range(len(controller_type)): - plot_data[0].append(max(CPU[i])) - plot_data[1].append((sum(CPU[i])/len(CPU[i]))) - - plot_data[0]=tuple(plot_data[0]) - plot_data[1]=tuple(plot_data[1]) - catogries=[] - for i in range(len(controller_type)): - catogries.append(str(i+1)) - bc = VerticalBarChart() - bc.x = 40 - bc.y = 35 - bc.height = 220 - bc.width = 450 - bc.data = plot_data - bc.strokeColor = colors.black - - bc.valueAxis.valueMin =0 - bc.valueAxis.valueMax = 100 - bc.valueAxis.configure(global_CPU) - bc.groupSpacing=2 - bc.categoryAxis.labels.boxAnchor = 'ne' - bc.categoryAxis.labels.dx = 1 - bc.categoryAxis.labels.dy = -2 - bc.categoryAxis.labels.angle = 30 - bc.categoryAxis.categoryNames = catogries - drawing.add(String(200,300,'CPU usage(%) ', fontSize=12, fillColor=colors.black)) - drawing.add(legend, 'legend') - drawing.add(lab) - drawing.add(bc) - drawing.add(String(200,5,'Trail # ', fontSize=12, fillColor=colors.black)) - elements.append(drawing) - - # Memory usage plot - legend = LineLegend() - legend.alignment = 'right' - legend.x = 1 - legend.y = 270 - legend.deltax = 60 - legend.dxTextSpace = 10 - legend.columnMaximum = 1 - items = 'red green blue yellow pink black aqua bisque blueviolet brown burlywood cadetblue chartreuse chocolate cornflowerblue crimson cyan darkblue darkcyan darkgoldenrod darkgray coral darkgreen darkkhaki darkmagenta darkolivegreen darkorange darkred darksalmon darkseagreen darkslateblue darkslategray darkturquoise darkviolet deeppink deepskyblue dimgray firebrick forestgreen fuchsia grey greenyellow gold hotpink indianred ivory lavender lime maroon navy olive'.split() - cnp = [] - l = LineSwatch() - l.strokeColor = getattr(colors, items[0]) - cnp.append((l, "Max Memory Usage (%)")) - l = LineSwatch() - l.strokeColor = getattr(colors, items[1]) - cnp.append((l, "Average Memory Usage (%)")) - legend.colorNamePairs = cnp - - drawing = Drawing(500, 350) - lab=Label() - lab.setOrigin(0,130) - lab.angle=90 - lab.setText('Memory(%)') - plot_data=[[],[]] - for i in range(len(controller_type)): - plot_data[0].append(max(Memory[i])) - plot_data[1].append((sum(Memory[i])/len(Memory[i]))) - - plot_data[0]=tuple(plot_data[0]) - plot_data[1]=tuple(plot_data[1]) - bc = VerticalBarChart() - bc.x = 40 - bc.y = 35 - bc.height = 220 - bc.width = 450 - bc.data = plot_data - bc.strokeColor = colors.black - - bc.valueAxis.valueMin =0 - bc.valueAxis.valueMax = 100 - - bc.valueAxis.configure(global_Memory) - bc.groupSpacing=2 - bc.categoryAxis.labels.boxAnchor = 'ne' - bc.categoryAxis.labels.dx = 1 - bc.categoryAxis.labels.dy = -2 - bc.categoryAxis.labels.angle = 30 - bc.categoryAxis.categoryNames = catogries - drawing.add(String(200,300,'Memory usage ', fontSize=12, fillColor=colors.black)) - drawing.add(legend, 'legend') - drawing.add(lab) - drawing.add(bc) - drawing.add(String(200,5,'Trail # ', fontSize=12, fillColor=colors.black)) - elements.append(drawing) - - - # Trajectory plot - with open(map_path, 'r') as file: - map_specs = yaml.safe_load(file) - - origin=map_specs['origin'] - resolution=map_specs['resolution'] - img=Image.open(map_png_path) - numpydata=asarray(img) - - x_length=len(numpydata) - y_length=len(numpydata[0]) # width - img=plt.imread(map_png_path) - fig, ax=plt.subplots() - ax.imshow(img,cmap=plt.cm.gray,extent=[origin[0],0.05*y_length+origin[0],origin[1],0.05*x_length+origin[1]]) - if trajectory_type=="circle": - r= robot_specs['radius'] - waypoints_array=[[x+r,y]] - waypoints_array+=circle_points(x,y,r) - elif trajectory_type=="several_waypoints": - waypoints_array=[[x,y]] - waypoints_array+=robot_specs['waypoints'] - elif trajectory_type=="square": - waypoints_array=[[x,y]] - side_length=robot_specs['side_length'] - waypoints_array=square_points(x,y,side_length) - elif trajectory_type=="one_goal": - waypoints_array=[[x,y],[robot_specs['goal_pose_x'],robot_specs['goal_pose_y']]] - - x_trajectory=[] - y_trajectory=[] - for i in range(len(waypoints_array)): - x_trajectory.append(waypoints_array[i][0]) - y_trajectory.append(waypoints_array[i][1]) - plt.scatter(x_trajectory,y_trajectory,marker='*',c='yellowgreen') - for p in range(len(controller_type)): - plt.plot(x_points[p],y_points[p],c='grey',linestyle='dashed') - plt.plot(x_points[p][len(x_points[p])-1],y_points[p][len(y_points[p])-1],c='grey',marker='o', ms=10) - - plt.xlabel('x-axis (meters)',fontdict={'family':'serif','size':12}) - plt.ylabel('y-axis (meters)',fontdict={'family':'serif','size':12}) - - if trajectory_type=="circle": - plt.plot(x+r,y,marker='*',c='yellowgreen',ms=13) - else: - plt.plot(x,y,marker='*',c='yellowgreen',ms=13) - plt.plot(data[0][len(data[0])-2],data[0][len(data[0])-1],c='yellowgreen',ms=13) - plt.savefig(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data','map_plot.png')) - image_ratio=y_length/x_length - scaling_factor=image_ratio/(500/300) - x_length=int(300*scaling_factor) - y_length=int(500*scaling_factor) - drawing = shapes.Drawing(500,60) - drawing.add(String(200,40,'Traveled path ', fontSize=12, fillColor=colors.black)) - drawing.add(Circle(300,10,3,fillColor=colors.grey,strokeColor=colors.grey)) - drawing.add(String(308,10,'Final pose ',fontSize=12, fillColor=colors.black)) - star_vertices=[201.99,9.78,205.88,11.194,201.04,11.708,200,16,198.8,11.6,194.1,11.091,198.07,9.46,196.3,5.277,200,8,203.86,5.406,201.99,9.78] - drawing.add(Polygon(star_vertices, fillColor=colors.yellowgreen,strokeColor=colors.yellowgreen)) - drawing.add(String(210,10,'Initial pose ',fontSize=12, fillColor=colors.black)) - drawing.add(Line(1,13,7,13, strokeColor=colors.yellowgreen, strokeWidth=3)) - drawing.add(String(9,10,'Global planner path ',fontSize=12, fillColor=colors.black)) - drawing.add(String(115,10,'x ',fontSize=13, fillColor=colors.yellowgreen)) - drawing.add(String(124,10,'Waypoints ',fontSize=12, fillColor=colors.black)) - drawing.add(String(370,10,'-- ',fontSize=15, fillColor=colors.grey)) - drawing.add(String(382,10,'Robot path ',fontSize=12, fillColor=colors.black)) - elements.append(drawing) - elements.append(Image_pdf(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data','map_plot.png'),y_length,x_length)) - - - first_failure=0 - for i in range(len(controller_type)): - log_msgs=[] - if result(i)=="failed" or result(i)=='goal has an invalid return status!': - if first_failure==0: - d=shapes.Drawing(250,40) - d.add(String(1,20,"Failure report",fontSize=15)) - elements.append(d) - first_failure=1 - # Opening the csv of the error msgs - f=open(os.path.join(get_package_share_directory('ROSNavBench'), - 'raw_data', - pdf_name+'_'+controller_type[i]+"_error_msgs_"+str(i+1)+'.csv'),'r') - writer=csv.reader(f,quoting=csv.QUOTE_NONNUMERIC,delimiter=' ') - for lines in writer: - log_msgs.append(lines[:]) - d=shapes.Drawing(250,40) - d.add(String(1,20,"Log messages of "+controller_type[i]+ " #"+str(i),fontSize=15)) - elements.append(d) - table= [["Logger_name", "Level", "Message"]] - table.append([""]) - for k in range(len(log_msgs[i])): - table.append(log_msgs[i][k]) - - - - t=Table(table) - t.setStyle(TableStyle([('INNERGRID',(0,0), (-1,-1), 0.25, colors.black), - ('BOX',(0,0), (-1,-1), 0.25, colors.black), - ('SPAN',(0,0),(0,1)), - ('SPAN',(1,0),(1,1)), - ('SPAN',(2,0),(2,1)), - ('FONTNAME',(0,0),(8,1),'Helvetica-Bold'), - ('FONTSIZE',(0,0), (-1,-1),8) - ])) - elements.append(t) - elements.append(Drawing(500, 10)) - doc.build(elements) - \ No newline at end of file From 8a2317e2fbb48b1489c3630c41a320a2043fc233 Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Wed, 1 Nov 2023 10:16:42 +0300 Subject: [PATCH 3/8] Delete example/turtlebot3/behavior_trees/posses.xml --- example/turtlebot3/behavior_trees/posses.xml | 39 -------------------- 1 file changed, 39 deletions(-) delete mode 100644 example/turtlebot3/behavior_trees/posses.xml diff --git a/example/turtlebot3/behavior_trees/posses.xml b/example/turtlebot3/behavior_trees/posses.xml deleted file mode 100644 index e8df1e5..0000000 --- a/example/turtlebot3/behavior_trees/posses.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From 890cc656e2ed62181716598c94ebb7aec604efa7 Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Wed, 8 Nov 2023 14:43:01 +0300 Subject: [PATCH 4/8] Delete example/turtlebot3/behavior_trees directory --- .../behavior_trees/btNavFn_MPPI.xml | 39 ------------------- .../turtlebot3/behavior_trees/btNavFn_RPP.xml | 39 ------------------- .../behavior_trees/bt_NavFn_DWB.xml | 39 ------------------- .../behavior_trees/bt_NavFn_DWB_1.xml | 36 ----------------- .../behavior_trees/bt_NavFn_DWB_2.xml | 36 ----------------- .../behavior_trees/bt_NavFn_DWB_RSC.xml | 36 ----------------- .../behavior_trees/bt_NavFn_MPPI.xml | 39 ------------------- .../behavior_trees/bt_NavFn_RPP.xml | 39 ------------------- .../behavior_trees/bt_NavFn_RPP_RSC.xml | 36 ----------------- .../behavior_trees/bt_smac_planner_DWB.xml | 39 ------------------- .../bt_smac_planner_DWB_RSC.xml | 36 ----------------- .../behavior_trees/bt_smac_planner_MPPI.xml | 39 ------------------- .../behavior_trees/bt_smac_planner_RPP.xml | 39 ------------------- .../bt_smac_planner_RPP_RSC.xml | 36 ----------------- .../behavior_trees/btsmac_planner_MPPI.xml | 39 ------------------- .../behavior_trees/btsmac_planner_RPP.xml | 39 ------------------- example/turtlebot3/behavior_trees/pose.xml | 37 ------------------ example/turtlebot3/behavior_trees/poses.xml | 39 ------------------- 18 files changed, 682 deletions(-) delete mode 100644 example/turtlebot3/behavior_trees/btNavFn_MPPI.xml delete mode 100644 example/turtlebot3/behavior_trees/btNavFn_RPP.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml delete mode 100644 example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml delete mode 100644 example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml delete mode 100644 example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml delete mode 100644 example/turtlebot3/behavior_trees/pose.xml delete mode 100644 example/turtlebot3/behavior_trees/poses.xml diff --git a/example/turtlebot3/behavior_trees/btNavFn_MPPI.xml b/example/turtlebot3/behavior_trees/btNavFn_MPPI.xml deleted file mode 100644 index 6ec88cc..0000000 --- a/example/turtlebot3/behavior_trees/btNavFn_MPPI.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/btNavFn_RPP.xml b/example/turtlebot3/behavior_trees/btNavFn_RPP.xml deleted file mode 100644 index 6d9f1a4..0000000 --- a/example/turtlebot3/behavior_trees/btNavFn_RPP.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml deleted file mode 100644 index 1151bea..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_DWB.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml deleted file mode 100644 index 1e6e8e0..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_1.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml deleted file mode 100644 index ea5b6d4..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_2.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml b/example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml deleted file mode 100644 index 4b5b1b1..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_DWB_RSC.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml b/example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml deleted file mode 100644 index 6ec88cc..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_MPPI.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml b/example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml deleted file mode 100644 index 6d9f1a4..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_RPP.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml b/example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml deleted file mode 100644 index 62e1eff..0000000 --- a/example/turtlebot3/behavior_trees/bt_NavFn_RPP_RSC.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml deleted file mode 100644 index d15d42c..0000000 --- a/example/turtlebot3/behavior_trees/bt_smac_planner_DWB.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml deleted file mode 100644 index 8d30863..0000000 --- a/example/turtlebot3/behavior_trees/bt_smac_planner_DWB_RSC.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml deleted file mode 100644 index 45f7b62..0000000 --- a/example/turtlebot3/behavior_trees/bt_smac_planner_MPPI.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml deleted file mode 100644 index e57786a..0000000 --- a/example/turtlebot3/behavior_trees/bt_smac_planner_RPP.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml b/example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml deleted file mode 100644 index 86dd4d3..0000000 --- a/example/turtlebot3/behavior_trees/bt_smac_planner_RPP_RSC.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml b/example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml deleted file mode 100644 index 45f7b62..0000000 --- a/example/turtlebot3/behavior_trees/btsmac_planner_MPPI.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml b/example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml deleted file mode 100644 index e57786a..0000000 --- a/example/turtlebot3/behavior_trees/btsmac_planner_RPP.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/example/turtlebot3/behavior_trees/pose.xml b/example/turtlebot3/behavior_trees/pose.xml deleted file mode 100644 index 4f853f9..0000000 --- a/example/turtlebot3/behavior_trees/pose.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/example/turtlebot3/behavior_trees/poses.xml b/example/turtlebot3/behavior_trees/poses.xml deleted file mode 100644 index e8df1e5..0000000 --- a/example/turtlebot3/behavior_trees/poses.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From ff8766e33564d4c4c362d583fde9b5624ebcb5ed Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Wed, 8 Nov 2023 14:43:19 +0300 Subject: [PATCH 5/8] Add files via upload --- example/turtlebot3/behavior_trees/pose.xml | 37 +++++++++++++++++++ example/turtlebot3/behavior_trees/poses.xml | 39 +++++++++++++++++++++ 2 files changed, 76 insertions(+) create mode 100644 example/turtlebot3/behavior_trees/pose.xml create mode 100644 example/turtlebot3/behavior_trees/poses.xml diff --git a/example/turtlebot3/behavior_trees/pose.xml b/example/turtlebot3/behavior_trees/pose.xml new file mode 100644 index 0000000..4f853f9 --- /dev/null +++ b/example/turtlebot3/behavior_trees/pose.xml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/turtlebot3/behavior_trees/poses.xml b/example/turtlebot3/behavior_trees/poses.xml new file mode 100644 index 0000000..e8df1e5 --- /dev/null +++ b/example/turtlebot3/behavior_trees/poses.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 862bc6a5e1b60a1930369954df5096587857ce6f Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Mon, 13 Nov 2023 14:34:27 +0300 Subject: [PATCH 6/8] Delete config directory --- config/circle_path_scenario.yaml | 62 --- config/differen_tunning_DWB.yaml | 64 ---- config/dynamic_obstacles.yaml | 67 ---- config/narrow_path.yaml | 63 ---- config/params.yaml | 68 ---- config/random_waypoints.yaml | 69 ---- config/random_waypoints_2.yaml | 63 ---- config/rviz_config.rviz | 626 ------------------------------- config/square_path_scenario.yaml | 61 --- config/static_2.yaml | 66 ---- config/static_obstacles.yaml | 66 ---- config/straight_line.yaml | 65 ---- 12 files changed, 1340 deletions(-) delete mode 100644 config/circle_path_scenario.yaml delete mode 100644 config/differen_tunning_DWB.yaml delete mode 100644 config/dynamic_obstacles.yaml delete mode 100644 config/narrow_path.yaml delete mode 100644 config/params.yaml delete mode 100644 config/random_waypoints.yaml delete mode 100644 config/random_waypoints_2.yaml delete mode 100644 config/rviz_config.rviz delete mode 100644 config/square_path_scenario.yaml delete mode 100644 config/static_2.yaml delete mode 100644 config/static_obstacles.yaml delete mode 100644 config/straight_line.yaml diff --git a/config/circle_path_scenario.yaml b/config/circle_path_scenario.yaml deleted file mode 100644 index 9ef9cd8..0000000 --- a/config/circle_path_scenario.yaml +++ /dev/null @@ -1,62 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "circular_path_scenario_two_controllers" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/worlds/scenario_world.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 1 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: -1.25 -spawn_pose_y: -2.40 -spawn_pose_yaw: -3.13 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "circle" - -# Circule parameter, note that the place of spawn will be the center of the circle -radius: 1.1 diff --git a/config/differen_tunning_DWB.yaml b/config/differen_tunning_DWB.yaml deleted file mode 100644 index 18f80ac..0000000 --- a/config/differen_tunning_DWB.yaml +++ /dev/null @@ -1,64 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "DWB_tuning" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/dynamic_tunning.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["DWB","DWB_1","DWB_2"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 1 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "CPU"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: -3.3 -spawn_pose_y: -6.9 -spawn_pose_yaw: 1.58 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" -# One goal parameter -goal_pose_x: 0.95 -goal_pose_y: 4.55 -goal_pose_yaw: 2.58 #radians - diff --git a/config/dynamic_obstacles.yaml b/config/dynamic_obstacles.yaml deleted file mode 100644 index eaa1cc5..0000000 --- a/config/dynamic_obstacles.yaml +++ /dev/null @@ -1,67 +0,0 @@ -## Name the experiment. This name will be the name of the report -experiment_name: "dynamic_obstcales_test" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/dynamic_obstacles_industrial.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP", "DWB", "MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 1 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] -#["Time", "Path Length", "CPU", "Memory", "Safety"] -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" -# Provide the pose in a decimal form -spawn_pose_x: 1.34 -spawn_pose_y: 6.9 -spawn_pose_yaw: 1.58 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" -# One goal parameter -goal_pose_x: 1.4 -goal_pose_y: -3.0 -goal_pose_yaw: -3.13 #radians -# Specify way points in this formate [[x0,y0,yaw0_radians], [x1,y1,yaw1_radians], ...]. Type should be float -#waypoints: [[-1.83, 3.26, 1.5], [-4.0, 0.17, 1.5], [-1.39, -3.82, 1.5]] -#[[-2.0, -3.00, -3.13]] -# failure [[-1.83, 3.26, 1.5], [-4.0, 0.17, 1.5], [-1.39, -3.82, 1.5]] -#[[-1.83,3.26,1.5],[-4.0,0.17,1.5],[-1.39,-3.82,1.5],[4.0,-4.0,1.5]] - diff --git a/config/narrow_path.yaml b/config/narrow_path.yaml deleted file mode 100644 index cb52b4c..0000000 --- a/config/narrow_path.yaml +++ /dev/null @@ -1,63 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "narrow_path_scenario_report" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/worlds/new_dynamic.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/map.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/map.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP", "DWB", "MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 1 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: 7.67 -spawn_pose_y: 6.22 -spawn_pose_yaw: -3.13 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" - -# One goal parameter -goal_pose_x: 4.00 -goal_pose_y: 6.22 -goal_pose_yaw: -3.13 #radians - diff --git a/config/params.yaml b/config/params.yaml deleted file mode 100644 index 420d5e5..0000000 --- a/config/params.yaml +++ /dev/null @@ -1,68 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "param_guide" - -#Save directory of results -results_directory: "/home/riotu/ros2_ws2/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/ros2_ws2/src/ROSNavBench/simulations/worlds/scenario_world.world" - -# Add the absolute path of the map -map_path: "/home/riotu/ros2_ws2/src/ROSNavBench/simulations/maps/map.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/ros2_ws2/src/ROSNavBench/simulations/maps/map.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros2_ws2/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP", "DWB", "MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 1 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: 4.0 -spawn_pose_y: -3.0 -spawn_pose_yaw: -3.13 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "circle" -# One goal parameter -goal_pose_x: 4.0 -goal_pose_y: -3.0 -goal_pose_yaw: -3.13 #radians -# Circule parameter, note that the place of spawn will be the center of the circle -radius: 1.1 -# Square parameter -side_length: 3.0 -# Specify way points in this formate [[x0,y0,yaw0_radians], [x1,y1,yaw1_radians], ...] -waypoints: [[-1.3, 2.3, -3.13], [6.0, 2.0, -3.13], [-4.0, 4.0, -3.13]] diff --git a/config/random_waypoints.yaml b/config/random_waypoints.yaml deleted file mode 100644 index b5ebf53..0000000 --- a/config/random_waypoints.yaml +++ /dev/null @@ -1,69 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "several_waypoints_scenario_report" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/industrial_warehouse.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros2_ws2/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP", "DWB"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 1 - -#Number of instances for multiple controllers and planners test -#This will repeat each combination instances_num times -instances_num: 3 -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: 5.6 -spawn_pose_y: 2.0 -spawn_pose_yaw: -3.13 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" - -# Specify way points in this formate [[x0,y0,yaw0_radians], [x1,y1,yaw1_radians], ...] -waypoints: [[3.8,-0.35, -3.13]] -# One goal parameter -goal_pose_x: 3.8 -goal_pose_y: -0.35 -goal_pose_yaw: -3.13 #radians diff --git a/config/random_waypoints_2.yaml b/config/random_waypoints_2.yaml deleted file mode 100644 index f93d369..0000000 --- a/config/random_waypoints_2.yaml +++ /dev/null @@ -1,63 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "several_waypoints_3waypoints_2" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/industrial_warehouse.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP", "DWB","MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller and planner combination several times -# Min value is one -instances_num: 5 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: 1.05 -spawn_pose_y: 6.64 -spawn_pose_yaw: -3.13 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "several_waypoints" - -# Specify way points in this formate [[x0,y0,yaw0_radians], [x1,y1,yaw1_radians], ...] -waypoints: [[1.38,2.12, -3.13],[5.45,1.99, -3.13],[5.5,-2.18, -3.13]] - diff --git a/config/rviz_config.rviz b/config/rviz_config.rviz deleted file mode 100644 index b4eca84..0000000 --- a/config/rviz_config.rviz +++ /dev/null @@ -1,626 +0,0 @@ -Panels: - - Class: rviz_common/Displays - Help Height: 0 - Name: Displays - Property Tree Widget: - Expanded: - - /Global Options1 - - /TF1/Frames1 - - /TF1/Tree1 - Splitter Ratio: 0.5833333134651184 - Tree Height: 515 - - Class: rviz_common/Selection - Name: Selection - - Class: rviz_common/Tool Properties - Expanded: - - /Publish Point1 - Name: Tool Properties - Splitter Ratio: 0.5886790156364441 - - Class: rviz_common/Views - Expanded: - - /Current View1 - Name: Views - Splitter Ratio: 0.5 - - Class: nav2_rviz_plugins/Navigation 2 - Name: Navigation 2 -Visualization Manager: - Class: "" - Displays: - - Alpha: 0.5 - Cell Size: 1 - Class: rviz_default_plugins/Grid - Color: 160; 160; 164 - Enabled: true - Line Style: - Line Width: 0.029999999329447746 - Value: Lines - Name: Grid - Normal Cell Count: 0 - Offset: - X: 0 - Y: 0 - Z: 0 - Plane: XY - Plane Cell Count: 10 - Reference Frame: - Value: true - - Alpha: 1 - Class: rviz_default_plugins/RobotModel - Collision Enabled: false - Description File: "" - Description Source: Topic - Description Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /robot_description - Enabled: false - Links: - All Links Enabled: true - Expand Joint Details: false - Expand Link Details: false - Expand Tree: false - Link Tree Style: "" - Mass Properties: - Inertia: false - Mass: false - Name: RobotModel - TF Prefix: "" - Update Interval: 0 - Value: false - Visual Enabled: true - - Class: rviz_default_plugins/TF - Enabled: true - Frame Timeout: 15 - Frames: - All Enabled: false - base_footprint: - Value: true - base_link: - Value: true - base_scan: - Value: true - camera_depth_frame: - Value: true - camera_depth_optical_frame: - Value: true - camera_link: - Value: true - camera_rgb_frame: - Value: true - camera_rgb_optical_frame: - Value: true - caster_back_left_link: - Value: true - caster_back_right_link: - Value: true - imu_link: - Value: true - map: - Value: true - odom: - Value: true - wheel_left_link: - Value: true - wheel_right_link: - Value: true - Marker Scale: 1 - Name: TF - Show Arrows: true - Show Axes: true - Show Names: false - Tree: - map: - odom: - base_footprint: - base_link: - base_scan: - {} - camera_link: - camera_depth_frame: - camera_depth_optical_frame: - {} - camera_rgb_frame: - camera_rgb_optical_frame: - {} - caster_back_left_link: - {} - caster_back_right_link: - {} - imu_link: - {} - wheel_left_link: - {} - wheel_right_link: - {} - Update Interval: 0 - Value: true - - Alpha: 1 - Autocompute Intensity Bounds: true - Autocompute Value Bounds: - Max Value: 10 - Min Value: -10 - Value: true - Axis: Z - Channel Name: intensity - Class: rviz_default_plugins/LaserScan - Color: 255; 255; 255 - Color Transformer: Intensity - Decay Time: 0 - Enabled: true - Invert Rainbow: false - Max Color: 255; 255; 255 - Max Intensity: 0 - Min Color: 0; 0; 0 - Min Intensity: 0 - Name: LaserScan - Position Transformer: XYZ - Selectable: true - Size (Pixels): 3 - Size (m): 0.009999999776482582 - Style: Points - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Best Effort - Value: /scan - Use Fixed Frame: true - Use rainbow: true - Value: true - - Alpha: 1 - Autocompute Intensity Bounds: true - Autocompute Value Bounds: - Max Value: 10 - Min Value: -10 - Value: true - Axis: Z - Channel Name: intensity - Class: rviz_default_plugins/PointCloud2 - Color: 255; 255; 255 - Color Transformer: "" - Decay Time: 0 - Enabled: true - Invert Rainbow: false - Max Color: 255; 255; 255 - Max Intensity: 4096 - Min Color: 0; 0; 0 - Min Intensity: 0 - Name: Bumper Hit - Position Transformer: "" - Selectable: true - Size (Pixels): 3 - Size (m): 0.07999999821186066 - Style: Spheres - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Best Effort - Value: /mobile_base/sensors/bumper_pointcloud - Use Fixed Frame: true - Use rainbow: true - Value: true - - Alpha: 1 - Class: rviz_default_plugins/Map - Color Scheme: map - Draw Behind: true - Enabled: true - Name: Map - Topic: - Depth: 1 - Durability Policy: Transient Local - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /map - Update Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /map_updates - Use Timestamp: false - Value: true - - Alpha: 1 - Class: nav2_rviz_plugins/ParticleCloud - Color: 0; 180; 0 - Enabled: true - Max Arrow Length: 0.30000001192092896 - Min Arrow Length: 0.019999999552965164 - Name: Amcl Particle Swarm - Shape: Arrow (Flat) - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Best Effort - Value: /particle_cloud - Value: true - - Class: rviz_common/Group - Displays: - - Alpha: 0.30000001192092896 - Class: rviz_default_plugins/Map - Color Scheme: costmap - Draw Behind: false - Enabled: true - Name: Global Costmap - Topic: - Depth: 1 - Durability Policy: Transient Local - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /global_costmap/costmap - Update Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /global_costmap/costmap_updates - Use Timestamp: false - Value: true - - Alpha: 0.30000001192092896 - Class: rviz_default_plugins/Map - Color Scheme: costmap - Draw Behind: false - Enabled: true - Name: Downsampled Costmap - Topic: - Depth: 1 - Durability Policy: Transient Local - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /downsampled_costmap - Update Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /downsampled_costmap_updates - Use Timestamp: false - Value: true - - Alpha: 1 - Buffer Length: 1 - Class: rviz_default_plugins/Path - Color: 255; 0; 0 - Enabled: true - Head Diameter: 0.019999999552965164 - Head Length: 0.019999999552965164 - Length: 0.30000001192092896 - Line Style: Lines - Line Width: 0.029999999329447746 - Name: Path - Offset: - X: 0 - Y: 0 - Z: 0 - Pose Color: 255; 85; 255 - Pose Style: Arrows - Radius: 0.029999999329447746 - Shaft Diameter: 0.004999999888241291 - Shaft Length: 0.019999999552965164 - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /plan - Value: true - - Alpha: 1 - Autocompute Intensity Bounds: true - Autocompute Value Bounds: - Max Value: 10 - Min Value: -10 - Value: true - Axis: Z - Channel Name: intensity - Class: rviz_default_plugins/PointCloud2 - Color: 125; 125; 125 - Color Transformer: FlatColor - Decay Time: 0 - Enabled: true - Invert Rainbow: false - Max Color: 255; 255; 255 - Max Intensity: 4096 - Min Color: 0; 0; 0 - Min Intensity: 0 - Name: VoxelGrid - Position Transformer: XYZ - Selectable: true - Size (Pixels): 3 - Size (m): 0.05000000074505806 - Style: Boxes - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /global_costmap/voxel_marked_cloud - Use Fixed Frame: true - Use rainbow: true - Value: true - - Alpha: 1 - Class: rviz_default_plugins/Polygon - Color: 25; 255; 0 - Enabled: false - Name: Polygon - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /global_costmap/published_footprint - Value: false - Enabled: true - Name: Global Planner - - Class: rviz_common/Group - Displays: - - Alpha: 0.699999988079071 - Class: rviz_default_plugins/Map - Color Scheme: costmap - Draw Behind: false - Enabled: true - Name: Local Costmap - Topic: - Depth: 1 - Durability Policy: Transient Local - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /local_costmap/costmap - Update Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /local_costmap/costmap_updates - Use Timestamp: false - Value: true - - Alpha: 1 - Buffer Length: 1 - Class: rviz_default_plugins/Path - Color: 0; 12; 255 - Enabled: true - Head Diameter: 0.30000001192092896 - Head Length: 0.20000000298023224 - Length: 0.30000001192092896 - Line Style: Lines - Line Width: 0.029999999329447746 - Name: Local Plan - Offset: - X: 0 - Y: 0 - Z: 0 - Pose Color: 255; 85; 255 - Pose Style: None - Radius: 0.029999999329447746 - Shaft Diameter: 0.10000000149011612 - Shaft Length: 0.10000000149011612 - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /local_plan - Value: true - - Class: rviz_default_plugins/MarkerArray - Enabled: false - Name: Trajectories - Namespaces: - {} - Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /marker - Value: false - - Alpha: 1 - Class: rviz_default_plugins/Polygon - Color: 25; 255; 0 - Enabled: true - Name: Polygon - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /local_costmap/published_footprint - Value: true - - Alpha: 1 - Autocompute Intensity Bounds: true - Autocompute Value Bounds: - Max Value: 10 - Min Value: -10 - Value: true - Axis: Z - Channel Name: intensity - Class: rviz_default_plugins/PointCloud2 - Color: 255; 255; 255 - Color Transformer: RGB8 - Decay Time: 0 - Enabled: true - Invert Rainbow: false - Max Color: 255; 255; 255 - Max Intensity: 4096 - Min Color: 0; 0; 0 - Min Intensity: 0 - Name: VoxelGrid - Position Transformer: XYZ - Selectable: true - Size (Pixels): 3 - Size (m): 0.009999999776482582 - Style: Flat Squares - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /local_costmap/voxel_marked_cloud - Use Fixed Frame: true - Use rainbow: true - Value: true - Enabled: true - Name: Controller - - Class: rviz_common/Group - Displays: - - Class: rviz_default_plugins/Image - Enabled: true - Max Value: 1 - Median window: 5 - Min Value: 0 - Name: RealsenseCamera - Normalize Range: true - Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /intel_realsense_r200_depth/image_raw - Value: true - - Alpha: 1 - Autocompute Intensity Bounds: true - Autocompute Value Bounds: - Max Value: 10 - Min Value: -10 - Value: true - Axis: Z - Channel Name: intensity - Class: rviz_default_plugins/PointCloud2 - Color: 255; 255; 255 - Color Transformer: RGB8 - Decay Time: 0 - Enabled: true - Invert Rainbow: false - Max Color: 255; 255; 255 - Max Intensity: 4096 - Min Color: 0; 0; 0 - Min Intensity: 0 - Name: RealsenseDepthImage - Position Transformer: XYZ - Selectable: true - Size (Pixels): 3 - Size (m): 0.009999999776482582 - Style: Flat Squares - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /intel_realsense_r200_depth/points - Use Fixed Frame: true - Use rainbow: true - Value: true - Enabled: false - Name: Realsense - - Class: rviz_default_plugins/MarkerArray - Enabled: true - Name: MarkerArray - Namespaces: - {} - Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /waypoints - Value: true - - Class: rviz_default_plugins/Marker - Enabled: true - Name: Marker - Namespaces: - basic_shapes: true - Topic: - Depth: 5 - Durability Policy: Volatile - Filter size: 10 - History Policy: Keep Last - Reliability Policy: Reliable - Value: /visualization_marker - Value: true - Enabled: true - Global Options: - Background Color: 48; 48; 48 - Fixed Frame: map - Frame Rate: 30 - Name: root - Tools: - - Class: rviz_default_plugins/MoveCamera - - Class: rviz_default_plugins/Select - - Class: rviz_default_plugins/FocusCamera - - Class: rviz_default_plugins/Measure - Line color: 128; 128; 0 - - Class: rviz_default_plugins/SetInitialPose - Covariance x: 0.25 - Covariance y: 0.25 - Covariance yaw: 0.06853891909122467 - Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /initialpose - - Class: rviz_default_plugins/PublishPoint - Single click: true - Topic: - Depth: 5 - Durability Policy: Volatile - History Policy: Keep Last - Reliability Policy: Reliable - Value: /clicked_point - - Class: nav2_rviz_plugins/GoalTool - Transformation: - Current: - Class: rviz_default_plugins/TF - Value: true - Views: - Current: - Angle: -1.6150002479553223 - Class: rviz_default_plugins/TopDownOrtho - Enable Stereo Rendering: - Stereo Eye Separation: 0.05999999865889549 - Stereo Focal Distance: 1 - Swap Stereo Eyes: false - Value: false - Invert Z Axis: false - Name: Current View - Near Clip Distance: 0.009999999776482582 - Scale: 36.80799865722656 - Target Frame: - Value: TopDownOrtho (rviz_default_plugins) - X: -0.044467076659202576 - Y: -0.38726311922073364 - Saved: ~ -Window Geometry: - Displays: - collapsed: false - Height: 1016 - Hide Left Dock: false - Hide Right Dock: true - Navigation 2: - collapsed: false - QMainWindow State: 000000ff00000000fd00000004000000000000016a0000039efc020000000afb0000001200530065006c0065006300740069006f006e00000001e10000009b0000005c00fffffffb0000001e0054006f006f006c002000500072006f007000650072007400690065007302000001ed000001df00000185000000a3fb000000120056006900650077007300200054006f006f02000001df000002110000018500000122fb000000200054006f006f006c002000500072006f0070006500720074006900650073003203000002880000011d000002210000017afb000000100044006900730070006c006100790073010000003d00000240000000c900fffffffb0000002000730065006c0065006300740069006f006e00200062007500660066006500720200000138000000aa0000023a00000294fb00000014005700690064006500530074006500720065006f02000000e6000000d2000003ee0000030bfb0000000c004b0069006e0065006300740200000186000001060000030c00000261fb00000018004e0061007600690067006100740069006f006e002000320100000283000001580000013900fffffffb0000001e005200650061006c00730065006e0073006500430061006d00650072006100000002c6000000c10000002800ffffff000000010000010f0000034afc0200000003fb0000001e0054006f006f006c002000500072006f00700065007200740069006500730100000041000000780000000000000000fb0000000a00560069006500770073000000003d0000034a000000a400fffffffb0000001200530065006c0065006300740069006f006e010000025a000000b200000000000000000000000200000490000000a9fc0100000001fb0000000a00560069006500770073030000004e00000080000002e10000019700000003000004420000003efc0100000002fb0000000800540069006d00650100000000000004420000000000000000fb0000000800540069006d00650100000000000004500000000000000000000005ca0000039e00000004000000040000000800000008fc0000000100000002000000010000000a0054006f006f006c00730100000000ffffffff0000000000000000 - RealsenseCamera: - collapsed: false - Selection: - collapsed: false - Tool Properties: - collapsed: false - Views: - collapsed: true - Width: 1850 - X: 70 - Y: 27 diff --git a/config/square_path_scenario.yaml b/config/square_path_scenario.yaml deleted file mode 100644 index e58c87b..0000000 --- a/config/square_path_scenario.yaml +++ /dev/null @@ -1,61 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "square_path_scenario" - -#Save directory of results -results_directory: "/home/riotu/ros2_ws2/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/ros2_ws2/src/ROSNavBench/simulations/worlds/scenario_world.world" - -# Add the absolute path of the map -map_path: "/home/riotu/ros2_ws2/src/ROSNavBench/simulations/maps/map.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/ros2_ws2/src/ROSNavBench/simulations/maps/map.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros2_ws2/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["RPP", "DWB", "MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller several times -# if the user do not need this test, set it to zero -trails_num: 0 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: 2.5 -spawn_pose_y: -4.25 -spawn_pose_yaw: 0.026 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "square" - -# Square parameter -side_length: 2.5 diff --git a/config/static_2.yaml b/config/static_2.yaml deleted file mode 100644 index d43195e..0000000 --- a/config/static_2.yaml +++ /dev/null @@ -1,66 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "static_obstacles_scenario_report_f" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/industrial_warehouse.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["DWB","RPP","MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller several times -# if the user do not need this test, set it to zero -trails_num: 0 -#Number of instances for multiple controllers and planners test -#This will repeat each combination instances_num times -instances_num: 1 -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "CPU"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: -3.43 -spawn_pose_y: 2.03 -spawn_pose_yaw: 1.58 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" -# One goal parameter -goal_pose_x: 4.23 -goal_pose_y: 1.80 -goal_pose_yaw: 1.58 #radians - diff --git a/config/static_obstacles.yaml b/config/static_obstacles.yaml deleted file mode 100644 index 26a6c4a..0000000 --- a/config/static_obstacles.yaml +++ /dev/null @@ -1,66 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "static_obstacles_scenario_report_f" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/industrial_warehouse.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["DWB","RPP","MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller several times -# if the user do not need this test, set it to zero -trails_num: 0 -#Number of instances for multiple controllers and planners test -#This will repeat each combination instances_num times -instances_num: 5 -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "CPU"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: -3.3 -spawn_pose_y: -6.9 -spawn_pose_yaw: 1.58 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" -# One goal parameter -goal_pose_x: 0.95 -goal_pose_y: 4.55 -goal_pose_yaw: 1.58 #radians - diff --git a/config/straight_line.yaml b/config/straight_line.yaml deleted file mode 100644 index 86286e3..0000000 --- a/config/straight_line.yaml +++ /dev/null @@ -1,65 +0,0 @@ -# Name the experiment. This name will be the name of the report -experiment_name: "straight_line_scenario_report" - -#Save directory of results -results_directory: "/home/riotu/perform_ws/src/ROSNavBench/results" - -# Add the absolute path of the world -world_path: "/home/riotu/industrial_warehouse.world" - -# Add the absolute path of the map -map_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" - -# Add the absolute path of the map -map_png_path: "/home/riotu/perform_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" - -# Add gazebo model path, if multiple path, please spereate them by a : -models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/perform_ws/src/ROSNavBench/simulations/models" - -# Choose a type of global local planners to be tested -planner_type: ["NavFn", "smac_planner"] -# Choose one of the following controllers, by adding its name to the controller type list -# Note that these are the avaible controllers for the provided example -# DWB -# RPP -# RPP_RSC -# DWB_RSC -controller_type: ["DWB","RPP","MPPI"] #name of behaviour tree - -# This option is intended for testing the same controller several times -# if the user do not need this test, set it to zero -trails_num: 0 - -# Add the absolute path of the robot navigation configuration -nav_config: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle.yaml" - -# Add the directory of the behaviour tree -behaviour_tree_directory: "/home/riotu/perform_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" - -# Add the absolute path of the urdf and model files inside single qoutes '' -urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle.urdf" - -# If the robot is spawned by only urdf, then set the model_file to 'None' -model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle/model.sdf" - -#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" -criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] - -#Wieght for each criteria as a number from 1 to 9 -#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix -weights: "None" - -# Provide the pose in a decimal form -spawn_pose_x: -3.3 -spawn_pose_y: 1.7 -spawn_pose_yaw: 1.58 #radians - -# Specify either to send one goal, specific trajectory, or several waypoints -# square, circle, several_waypoints, one_goal -trajectory_type: "one_goal" - -# One goal parameter -goal_pose_x: -3.3 -goal_pose_y: -6.9 -goal_pose_yaw: 1.58 #radians - From 598025b6828487d282d94dabb7a2427cf11d1842 Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Mon, 13 Nov 2023 14:35:47 +0300 Subject: [PATCH 7/8] Delete example directory --- example/turtlebot3/behavior_trees/pose.xml | 37 - example/turtlebot3/behavior_trees/poses.xml | 39 -- example/turtlebot3/nav2_config/waffle.yaml | 717 -------------------- 3 files changed, 793 deletions(-) delete mode 100644 example/turtlebot3/behavior_trees/pose.xml delete mode 100644 example/turtlebot3/behavior_trees/poses.xml delete mode 100644 example/turtlebot3/nav2_config/waffle.yaml diff --git a/example/turtlebot3/behavior_trees/pose.xml b/example/turtlebot3/behavior_trees/pose.xml deleted file mode 100644 index 4f853f9..0000000 --- a/example/turtlebot3/behavior_trees/pose.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/example/turtlebot3/behavior_trees/poses.xml b/example/turtlebot3/behavior_trees/poses.xml deleted file mode 100644 index e8df1e5..0000000 --- a/example/turtlebot3/behavior_trees/poses.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/example/turtlebot3/nav2_config/waffle.yaml b/example/turtlebot3/nav2_config/waffle.yaml deleted file mode 100644 index 16b1546..0000000 --- a/example/turtlebot3/nav2_config/waffle.yaml +++ /dev/null @@ -1,717 +0,0 @@ -amcl: - ros__parameters: - use_sim_time: true - alpha1: 0.2 - alpha2: 0.2 - alpha3: 0.2 - alpha4: 0.2 - alpha5: 0.2 - base_frame_id: "base_footprint" - beam_skip_distance: 0.5 - beam_skip_error_threshold: 0.9 - beam_skip_threshold: 0.3 - do_beamskip: false - global_frame_id: "map" - lambda_short: 0.1 - laser_likelihood_max_dist: 2.0 - laser_max_range: 100.0 - laser_min_range: -1.0 - laser_model_type: "likelihood_field" - max_beams: 60 - max_particles: 2000 - min_particles: 500 - odom_frame_id: "odom" - pf_err: 0.05 - pf_z: 0.99 - recovery_alpha_fast: 0.0 - recovery_alpha_slow: 0.0 - resample_interval: 1 - robot_model_type: "nav2_amcl::DifferentialMotionModel" - save_pose_rate: 0.5 - sigma_hit: 0.2 - tf_broadcast: true - transform_tolerance: 1.0 - update_min_a: 0.2 - update_min_d: 0.25 - z_hit: 0.5 - z_max: 0.05 - z_rand: 0.5 - z_short: 0.05 - scan_topic: scan - -amcl_map_client: - ros__parameters: - use_sim_time: true - -amcl_rclcpp_node: - ros__parameters: - use_sim_time: true - -bt_navigator: - ros__parameters: - use_sim_time: true - global_frame: map - robot_base_frame: base_link - odom_topic: /odom - #default_bt_xml_filename: "navigate_w_replanning_and_recovery.xml" - bt_loop_duration: 10 - default_server_timeout: 20 - enable_groot_monitoring: True - groot_zmq_publisher_port: 1666 - groot_zmq_server_port: 1667 - plugin_lib_names: - - nav2_compute_path_to_pose_action_bt_node - - nav2_compute_path_through_poses_action_bt_node - - nav2_follow_path_action_bt_node - - nav2_back_up_action_bt_node - - nav2_spin_action_bt_node - - nav2_wait_action_bt_node - - nav2_clear_costmap_service_bt_node - - nav2_is_stuck_condition_bt_node - - nav2_goal_reached_condition_bt_node - - nav2_goal_updated_condition_bt_node - - nav2_initial_pose_received_condition_bt_node - - nav2_reinitialize_global_localization_service_bt_node - - nav2_rate_controller_bt_node - - nav2_distance_controller_bt_node - - nav2_speed_controller_bt_node - - nav2_truncate_path_action_bt_node - - nav2_goal_updater_node_bt_node - - nav2_recovery_node_bt_node - - nav2_pipeline_sequence_bt_node - - nav2_round_robin_node_bt_node - - nav2_transform_available_condition_bt_node - - nav2_time_expired_condition_bt_node - - nav2_distance_traveled_condition_bt_node - - nav2_single_trigger_bt_node - - nav2_is_battery_low_condition_bt_node - - nav2_navigate_through_poses_action_bt_node - - nav2_navigate_to_pose_action_bt_node - - nav2_remove_passed_goals_action_bt_node - - nav2_planner_selector_bt_node - - nav2_controller_selector_bt_node - - nav2_goal_checker_selector_bt_node - -bt_navigator_rclcpp_node: - ros__parameters: - use_sim_time: true - -controller_server: - ros__parameters: - use_sim_time: true - controller_frequency: 20.0 - min_x_velocity_threshold: 0.001 - min_y_velocity_threshold: 0.5 - min_theta_velocity_threshold: 0.001 - failure_tolerance: 0.3 - progress_checker_plugin: "progress_checker" - goal_checker_plugins: ["general_goal_checker"] - controller_plugins: ["MPPI","DWB_RSC","RPP", "DWB", "RPP_RSC","DWB_1","DWB_2"] - - # Progress checker parameters - progress_checker: - plugin: "nav2_controller::SimpleProgressChecker" - required_movement_radius: 0.5 - movement_time_allowance: 10.0 - - general_goal_checker: - stateful: True - plugin: "nav2_controller::SimpleGoalChecker" - xy_goal_tolerance: 0.25 - yaw_goal_tolerance: 0.25 - - # DWB parameters - - # ROS2 Controller Parameters and Evaluation Criteria - - # Controller 1: DWB_RSC - DWB_RSC: - plugin: "nav2_rotation_shim_controller::RotationShimController" - primary_controller: "dwb_core::DWBLocalPlanner" - debug_trajectory_details: True - angular_dist_threshold: 0.785 - forward_sampling_distance: 0.5 - rotate_to_heading_angular_vel: 1.8 - max_angular_accel: 3.2 - simulate_ahead_time: 1.0 - # DWB parameters - min_vel_x: 0.0 - min_vel_y: 0.0 - max_vel_x: 0.22 - max_vel_y: 0.0 - max_vel_theta: 1.0 - min_speed_xy: 0.0 - max_speed_xy: 0.22 - min_speed_theta: 0.0 - acc_lim_x: 2.5 - acc_lim_y: 0.0 - acc_lim_theta: 3.2 - decel_lim_x: -2.5 - decel_lim_y: 0.0 - decel_lim_theta: -3.2 - vx_samples: 20 - vy_samples: 0 - vtheta_samples: 40 - sim_time: 2.0 - linear_granularity: 0.05 - angular_granularity: 0.025 - transform_tolerance: 0.2 - xy_goal_tolerance: 0.25 - trans_stopped_velocity: 0.05 - short_circuit_trajectory_evaluation: True - stateful: True - critics: ["RotateToGoal", "Oscillation", "BaseObstacle", "GoalAlign", "PathAlign", "PathDist", "GoalDist"] - BaseObstacle.scale: 0.02 - PathAlign.scale: 32.0 - PathAlign.forward_point_distance: 0.1 - GoalAlign.scale: 24.0 - GoalAlign.forward_point_distance: 0.1 - PathDist.scale: 32.0 - GoalDist.scale: 24.0 - RotateToGoal.scale: 32.0 - RotateToGoal.slowing_factor: 5.0 - RotateToGoal.lookahead_time: -1.0 - - # Controller 2: RPP - RPP: - plugin: "nav2_regulated_pure_pursuit_controller::RegulatedPurePursuitController" - desired_linear_vel: 0.22 - lookahead_dist: 0.6 - min_lookahead_dist: 0.3 - max_lookahead_dist: 0.9 - lookahead_time: 1.5 - rotate_to_heading_angular_vel: 1.8 - transform_tolerance: 0.2 - use_velocity_scaled_lookahead_dist: false - min_approach_linear_velocity: 0.05 - approach_velocity_scaling_dist: 0.6 - use_collision_detection: true - max_allowed_time_to_collision_up_to_carrot: 1.0 - use_regulated_linear_velocity_scaling: true - use_cost_regulated_linear_velocity_scaling: false - regulated_linear_scaling_min_radius: 0.9 - regulated_linear_scaling_min_speed: 0.25 - use_rotate_to_heading: true - allow_reversing: false - rotate_to_heading_min_angle: 0.785 - max_angular_accel: 3.2 - max_robot_pose_search_dist: 10.0 - use_interpolation: false - - # Controller 3: DWB - DWB: - plugin: "dwb_core::DWBLocalPlanner" - debug_trajectory_details: True - min_vel_x: 0.0 - min_vel_y: 0.0 - max_vel_x: 0.22 - max_vel_y: 0.0 - max_vel_theta: 1.0 - min_speed_xy: 0.0 - max_speed_xy: 0.22 - min_speed_theta: 0.0 - acc_lim_x: 2.5 - acc_lim_y: 0.0 - acc_lim_theta: 3.2 - decel_lim_x: -2.5 - decel_lim_y: 0.0 - decel_lim_theta: -3.2 - vx_samples: 20 - vy_samples: 0 - vtheta_samples: 40 - sim_time: 2.0 - linear_granularity: 0.05 - angular_granularity: 0.025 - transform_tolerance: 0.2 - xy_goal_tolerance: 0.25 - trans_stopped_velocity: 0.25 - short_circuit_trajectory_evaluation: True - stateful: True - critics: ["RotateToGoal", "Oscillation", "BaseObstacle", "GoalAlign", "PathAlign", "PathDist", "GoalDist"] - BaseObstacle.scale: 0.02 - PathAlign.scale: 32.0 - PathAlign.forward_point_distance: 0.1 - GoalAlign.scale: 24.0 - GoalAlign.forward_point_distance: 0.1 - PathDist.scale: 32.0 - GoalDist.scale: 24.0 - RotateToGoal.scale: 32.0 - RotateToGoal.slowing_factor: 5.0 - RotateToGoal.lookahead_time: -1.0 - - DWB_1: - plugin: "dwb_core::DWBLocalPlanner" - debug_trajectory_details: True - min_vel_x: 0.0 - min_vel_y: 0.0 - max_vel_x: 0.22 - max_vel_y: 0.0 - max_vel_theta: 1.0 - min_speed_xy: 0.0 - max_speed_xy: 0.22 - min_speed_theta: 0.0 - acc_lim_x: 2.5 - acc_lim_y: 0.0 - acc_lim_theta: 3.2 - decel_lim_x: -2.5 - decel_lim_y: 0.0 - decel_lim_theta: -3.2 - vx_samples: 20 - vy_samples: 0 - vtheta_samples: 40 - sim_time: 1.5 - linear_granularity: 0.05 - angular_granularity: 0.025 - transform_tolerance: 0.2 - xy_goal_tolerance: 0.25 - trans_stopped_velocity: 0.25 - short_circuit_trajectory_evaluation: True - stateful: True - critics: ["RotateToGoal", "Oscillation", "BaseObstacle", "GoalAlign", "PathAlign", "PathDist", "GoalDist"] - BaseObstacle.scale: 0.02 - PathAlign.scale: 32.0 - PathAlign.forward_point_distance: 0.1 - GoalAlign.scale: 24.0 - GoalAlign.forward_point_distance: 0.1 - PathDist.scale: 32.0 - GoalDist.scale: 24.0 - RotateToGoal.scale: 32.0 - RotateToGoal.slowing_factor: 5.0 - RotateToGoal.lookahead_time: -1.0 - - DWB_2: - plugin: "dwb_core::DWBLocalPlanner" - debug_trajectory_details: True - min_vel_x: 0.0 - min_vel_y: 0.0 - max_vel_x: 0.22 - max_vel_y: 0.0 - max_vel_theta: 1.0 - min_speed_xy: 0.0 - max_speed_xy: 0.22 - min_speed_theta: 0.0 - acc_lim_x: 2.5 - acc_lim_y: 0.0 - acc_lim_theta: 3.2 - decel_lim_x: -2.5 - decel_lim_y: 0.0 - decel_lim_theta: -3.2 - vx_samples: 20 - vy_samples: 0 - vtheta_samples: 40 - sim_time: 3.0 - linear_granularity: 0.05 - angular_granularity: 0.025 - transform_tolerance: 0.2 - xy_goal_tolerance: 0.25 - trans_stopped_velocity: 0.25 - short_circuit_trajectory_evaluation: True - stateful: True - critics: ["RotateToGoal", "Oscillation", "BaseObstacle", "GoalAlign", "PathAlign", "PathDist", "GoalDist"] - BaseObstacle.scale: 0.02 - PathAlign.scale: 32.0 - PathAlign.forward_point_distance: 0.1 - GoalAlign.scale: 24.0 - GoalAlign.forward_point_distance: 0.1 - PathDist.scale: 32.0 - GoalDist.scale: 24.0 - RotateToGoal.scale: 32.0 - RotateToGoal.slowing_factor: 5.0 - RotateToGoal.lookahead_time: -1.0 - # Controller 4: RPP_RSC - RPP_RSC: - plugin: "nav2_rotation_shim_controller::RotationShimController" - primary_controller: "nav2_regulated_pure_pursuit_controller::RegulatedPurePursuitController" - debug_trajectory_details: True - angular_dist_threshold: 0.785 - forward_sampling_distance: 0.5 - rotate_to_heading_angular_vel: 1.8 - max_angular_accel: 3.2 - simulate_ahead_time: 1.0 - desired_linear_vel: 0.22 - lookahead_dist: 0.6 - min_lookahead_dist: 0.3 - max_lookahead_dist: 0.9 - lookahead_time: 1.5 - transform_tolerance: 0.2 - use_velocity_scaled_lookahead_dist: false - min_approach_linear_velocity: 0.05 - approach_velocity_scaling_dist: 0.6 - use_collision_detection: true - max_allowed_time_to_collision_up_to_carrot: 1.0 - use_regulated_linear_velocity_scaling: true - use_cost_regulated_linear_velocity_scaling: false - regulated_linear_scaling_min_radius: 0.9 - regulated_linear_scaling_min_speed: 0.25 - use_rotate_to_heading: true - allow_reversing: false - rotate_to_heading_min_angle: 0.785 - max_robot_pose_search_dist: 10.0 - use_interpolation: false - - -############# - - MPPI: - plugin: "nav2_mppi_controller::MPPIController" - time_steps: 56 - model_dt: 0.05 - batch_size: 2000 - vx_std: 0.22 - vy_std: 0.2 - wz_std: 0.4 - vx_max: 0.22 - vx_min: -0.35 - vy_max: 0.0 - wz_max: 1.0 - iteration_count: 1 - prune_distance: 1.7 - transform_tolerance: 0.1 - temperature: 0.3 - gamma: 0.015 - motion_model: "DiffDrive" - visualize: false - reset_period: 1.0 # (only in Humble) - regenerate_noises: false - TrajectoryVisualizer: - trajectory_step: 5 - time_step: 3 - AckermannConstraints: - min_turning_r: 0.2 - critics: ["ConstraintCritic", "ObstaclesCritic", "GoalCritic", "GoalAngleCritic", "PathAlignCritic", "PathFollowCritic", "PathAngleCritic", "PreferForwardCritic"] - ConstraintCritic: - enabled: true - cost_power: 1 - cost_weight: 4.0 - GoalCritic: - enabled: true - cost_power: 1 - cost_weight: 5.0 - threshold_to_consider: 1.4 - GoalAngleCritic: - enabled: true - cost_power: 1 - cost_weight: 3.0 - threshold_to_consider: 0.5 - PreferForwardCritic: - enabled: true - cost_power: 1 - cost_weight: 5.0 - threshold_to_consider: 0.5 - ObstaclesCritic: - enabled: true - cost_power: 1 - repulsion_weight: 1.5 - critical_weight: 20.0 - consider_footprint: false - collision_cost: 10000.0 - collision_margin_distance: 0.1 - near_goal_distance: 0.5 - inflation_radius: 0.55 # (only in Humble) - cost_scaling_factor: 10.0 # (only in Humble) - PathAlignCritic: - enabled: true - cost_power: 1 - cost_weight: 14.0 - max_path_occupancy_ratio: 0.05 - trajectory_point_step: 3 - threshold_to_consider: 0.5 - offset_from_furthest: 20 - use_path_orientations: false - PathFollowCritic: - enabled: true - cost_power: 1 - cost_weight: 5.0 - offset_from_furthest: 5 - threshold_to_consider: 1.4 - PathAngleCritic: - enabled: true - cost_power: 1 - cost_weight: 2.0 - offset_from_furthest: 4 - threshold_to_consider: 0.5 - max_angle_to_furthest: 1.0 - mode: 0 - # TwirlingCritic: - # enabled: true - # twirling_cost_power: 1 - # twirling_cost_weight: 10.0 - -controller_server_rclcpp_node: - ros__parameters: - use_sim_time: true - -local_costmap: - local_costmap: - ros__parameters: - update_frequency: 5.0 - publish_frequency: 2.0 - global_frame: odom - robot_base_frame: base_link - use_sim_time: true - rolling_window: true - width: 3 - height: 3 - resolution: 0.05 - robot_radius: 0.22 - plugins: ["obstacle_layer", "voxel_layer", "inflation_layer"] - inflation_layer: - plugin: "nav2_costmap_2d::InflationLayer" - cost_scaling_factor: 1.0 - inflation_radius: 0.55 - obstacle_layer: - plugin: "nav2_costmap_2d::ObstacleLayer" - enabled: True - observation_sources: scan - scan: - topic: /scan - max_obstacle_height: 2.0 - clearing: True - marking: True - data_type: "LaserScan" - voxel_layer: - plugin: "nav2_costmap_2d::VoxelLayer" - enabled: True - publish_voxel_map: True - origin_z: 0.0 - z_resolution: 0.05 - z_voxels: 16 - max_obstacle_height: 2.0 - mark_threshold: 0 - observation_sources: scan - scan: - topic: /scan - max_obstacle_height: 2.0 - clearing: True - marking: True - data_type: "LaserScan" - raytrace_max_range: 3.0 - raytrace_min_range: 0.0 - obstacle_max_range: 2.5 - obstacle_min_range: 0.0 - static_layer: - map_subscribe_transient_local: True - always_send_full_costmap: True - local_costmap_client: - ros__parameters: - use_sim_time: true - local_costmap_rclcpp_node: - ros__parameters: - use_sim_time: true - -global_costmap: - global_costmap: - ros__parameters: - update_frequency: 1.0 - publish_frequency: 1.0 - global_frame: map - robot_base_frame: base_link - use_sim_time: True - robot_radius: 0.22 - resolution: 0.05 - track_unknown_space: true - plugins: ["static_layer", "obstacle_layer", "voxel_layer", "inflation_layer"] - obstacle_layer: - plugin: "nav2_costmap_2d::ObstacleLayer" - enabled: True - observation_sources: scan - scan: - topic: /scan - max_obstacle_height: 2.0 - clearing: True - marking: True - data_type: "LaserScan" - raytrace_max_range: 3.0 - raytrace_min_range: 0.0 - obstacle_max_range: 2.5 - obstacle_min_range: 0.0 - voxel_layer: - plugin: "nav2_costmap_2d::VoxelLayer" - enabled: True - publish_voxel_map: True - origin_z: 0.0 - z_resolution: 0.05 - z_voxels: 16 - max_obstacle_height: 2.0 - mark_threshold: 0 - observation_sources: scan - scan: - topic: /scan - max_obstacle_height: 2.0 - clearing: True - marking: True - data_type: "LaserScan" - raytrace_max_range: 3.0 - raytrace_min_range: 0.0 - obstacle_max_range: 2.5 - obstacle_min_range: 0.0 - static_layer: - plugin: "nav2_costmap_2d::StaticLayer" - map_subscribe_transient_local: True - inflation_layer: - plugin: "nav2_costmap_2d::InflationLayer" - cost_scaling_factor: 3.0 - inflation_radius: 0.55 - always_send_full_costmap: True - global_costmap_client: - ros__parameters: - use_sim_time: true - global_costmap_rclcpp_node: - ros__parameters: - use_sim_time: true - -map_server: - ros__parameters: - use_sim_time: true - yaml_filename: "/home/riot/src/ros2_ws/src/TFG_Husky_UAL/husky_navigation/maps/warehouse_slam_toolbox.yaml" - -map_saver: - ros__parameters: - use_sim_time: true - save_map_timeout: 5.0 - free_thresh_default: 0.25 - occupied_thresh_default: 0.65 - map_subscribe_transient_local: True - -planner_server: - ros__parameters: - expected_planner_frequency: 20.0 - use_sim_time: true - planner_plugins: ["NavFn", "smac_planner", "HybridA", "ThetaStar"] - - # ROS2 Planner Parameters and Evaluation Criteria - - # Planner 1: NavFn - NavFn: - plugin: "nav2_navfn_planner/NavfnPlanner" - tolerance: 0.5 - use_astar: false - allow_unknown: true - - # Planner 2: smac_planner - smac_planner: - plugin: "nav2_smac_planner/SmacPlanner2D" - tolerance: 0.125 - downsample_costmap: false - downsampling_factor: 1 - allow_unknown: true - max_iterations: 1000000 - max_on_approach_iterations: 1000 - max_planning_time: 2.0 - cost_travel_multiplier: 2.0 - use_final_approach_orientation: false - smoother: - max_iterations: 1000 - w_smooth: 0.3 - w_data: 0.2 - tolerance: 0.0000000001 - - # Planner 3: HybridA - HybridA: - plugin: "nav2_smac_planner/SmacPlannerHybrid" - downsample_costmap: true - downsampling_factor: 1 - tolerance: 0.25 - allow_unknown: true - max_iterations: 1000000 - max_on_approach_iterations: 1000 - max_planning_time: 5.0 - motion_model_for_search: "DUBIN" - angle_quantization_bins: 72 - analytic_expansion_ratio: 3.5 - analytic_expansion_max_length: 3.0 - minimum_turning_radius: 0.40 - reverse_penalty: 2.0 - change_penalty: 0.0 - non_straight_penalty: 1.2 - cost_penalty: 2.0 - retrospective_penalty: 0.015 - lookup_table_size: 20.0 - cache_obstacle_heuristic: false - debug_visualizations: false - smooth_path: True - smoother: - max_iterations: 1000 - w_smooth: 0.3 - w_data: 0.2 - tolerance: 0.0000000001 - do_refinement: true - refinement_num: 2 - - # Planner 4: Lattice - Lattice: - plugin: "nav2_smac_planner/SmacPlannerLattice" - allow_unknown: true - tolerance: 0.25 - max_iterations: 1000000 - max_on_approach_iterations: 1000 - max_planning_time: 5.0 - analytic_expansion_ratio: 3.5 - analytic_expansion_max_length: 3.0 - reverse_penalty: 2.0 - change_penalty: 0.05 - non_straight_penalty: 1.05 - cost_penalty: 2.0 - rotation_penalty: 5.0 - retrospective_penalty: 0.015 - lattice_filepath: "/home/riot/src/ros2_ws/src/ROSNavBench/examples/nav2_config/config.json" - lookup_table_size: 20.0 - cache_obstacle_heuristic: false - allow_reverse_expansion: false - smooth_path: True - smoother: - max_iterations: 1000 - w_smooth: 0.3 - w_data: 0.2 - tolerance: 0.0000000001 - do_refinement: true - refinement_num: 2 - - # Planner 5: ThetaStar - ThetaStar: - plugin: "nav2_theta_star_planner/ThetaStarPlanner" - how_many_corners: 8 - w_euc_cost: 1.0 - w_traversal_cost: 2.0 - w_heuristic_cost: 1.0 - - - -planner_server_rclcpp_node: - ros__parameters: - use_sim_time: true - -recoveries_server: - ros__parameters: - costmap_topic: local_costmap/costmap_raw - footprint_topic: local_costmap/published_footprint - cycle_frequency: 10.0 - recovery_plugins: ["spin", "backup", "wait"] - spin: - plugin: "nav2_recoveries/Spin" - backup: - plugin: "nav2_recoveries/BackUp" - wait: - plugin: "nav2_recoveries/Wait" - global_frame: odom - robot_base_frame: base_link - transform_timeout: 0.1 - use_sim_time: true - simulate_ahead_time: 2.0 - max_rotational_vel: 1.0 - min_rotational_vel: 0.4 - rotational_acc_lim: 3.2 - -robot_state_publisher: - ros__parameters: - use_sim_time: true - -waypoint_follower: - ros__parameters: - loop_rate: 200 - stop_on_failure: false - waypoint_task_executor_plugin: "wait_at_waypoint" - wait_at_waypoint: - plugin: "nav2_waypoint_follower::WaitAtWaypoint" - enabled: True - waypoint_pause_duration: 200 From f7ee591f9414a851265157fd0eace045babcc5d1 Mon Sep 17 00:00:00 2001 From: Fatimah Alahmed <63425641+Fatimah-Alahmed@users.noreply.github.com> Date: Mon, 13 Nov 2023 14:36:48 +0300 Subject: [PATCH 8/8] adding config and example files --- config/circle_path_scenario.yaml | 62 ++ config/differen_tunning_DWB.yaml | 64 ++ config/params.yaml | 68 ++ config/random_waypoints_2.yaml | 63 ++ config/rviz_config.rviz | 626 ++++++++++++++ config/square_path_scenario.yaml | 61 ++ config/static_obstacles.yaml | 63 ++ example/turtlebot3/behavior_trees/pose.xml | 37 + example/turtlebot3/behavior_trees/poses.xml | 39 + example/turtlebot3/nav2_config/waffle_pi.yaml | 763 ++++++++++++++++++ 10 files changed, 1846 insertions(+) create mode 100644 config/circle_path_scenario.yaml create mode 100644 config/differen_tunning_DWB.yaml create mode 100644 config/params.yaml create mode 100644 config/random_waypoints_2.yaml create mode 100644 config/rviz_config.rviz create mode 100644 config/square_path_scenario.yaml create mode 100644 config/static_obstacles.yaml create mode 100644 example/turtlebot3/behavior_trees/pose.xml create mode 100644 example/turtlebot3/behavior_trees/poses.xml create mode 100644 example/turtlebot3/nav2_config/waffle_pi.yaml diff --git a/config/circle_path_scenario.yaml b/config/circle_path_scenario.yaml new file mode 100644 index 0000000..0f05e52 --- /dev/null +++ b/config/circle_path_scenario.yaml @@ -0,0 +1,62 @@ +# Name the experiment. This name will be the name of the report +experiment_name: "circular_path_scenario_two_controllers" + +#Save directory of results +results_directory: "/home/riotu/ros5_ws/src/ROSNavBench/results" + +# Add the absolute path of the world +world_path: "/home/riotu/industrial_warehouse.world" + +# Add the absolute path of the map +map_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" + +# Add the absolute path of the map +map_png_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" + +# Add gazebo model path, if multiple path, please spereate them by a : +models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros5_ws/src/ROSNavBench/simulations/models" + +# Choose a type of global local planners to be tested +planner_type: ["NavFn"] +# Choose one of the following controllers, by adding its name to the controller type list +# Note that these are the avaible controllers for the provided example +# DWB +# RPP +# RPP_RSC +# DWB_RSC +controller_type: ["RPP"] #name of behaviour tree + +# This option is intended for testing the same controller and planner combination several times +# Min value is one +instances_num: 1 + +# Add the absolute path of the robot navigation configuration +nav_config: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle_pi.yaml" + +# Add the directory of the behaviour tree +behaviour_tree_directory: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" + +# Add the absolute path of the urdf and model files inside single qoutes '' +urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" + +# If the robot is spawned by only urdf, then set the model_file to 'None' +model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" + +#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" +criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] + +#Wieght for each criteria as a number from 1 to 9 +#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix +weights: "None" + +# Provide the pose in a decimal form +spawn_pose_x: -1.25 +spawn_pose_y: -2.40 +spawn_pose_yaw: -3.13 #radians + +# Specify either to send one goal, specific trajectory, or several waypoints +# square, circle, several_waypoints, one_goal +trajectory_type: "circle" + +# Circule parameter, note that the place of spawn will be the center of the circle +radius: 2.0 diff --git a/config/differen_tunning_DWB.yaml b/config/differen_tunning_DWB.yaml new file mode 100644 index 0000000..d0feb72 --- /dev/null +++ b/config/differen_tunning_DWB.yaml @@ -0,0 +1,64 @@ +# Name the experiment. This name will be the name of the report +experiment_name: "DWB_tuning" + +#Save directory of results +results_directory: "/home/riotu/ros5_ws/src/ROSNavBench/results" + +# Add the absolute path of the world +world_path: "/home/riotu/industrial_warehouse.world" + +# Add the absolute path of the map +map_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" + +# Add the absolute path of the map +map_png_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" + +# Add gazebo model path, if multiple path, please spereate them by a : +models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros5_ws/src/ROSNavBench/simulations/models" + +# Choose a type of global local planners to be tested +planner_type: ["NavFn"] +# Choose one of the following controllers, by adding its name to the controller type list +# Note that these are the avaible controllers for the provided example +# DWB +# RPP +# RPP_RSC +# DWB_RSC +controller_type: ["DWB","DWB_1","DWB_2"] #name of behaviour tree + +# This option is intended for testing the same controller and planner combination several times +# Min value is one +instances_num: 1 + +# Add the absolute path of the robot navigation configuration +nav_config: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle_pi.yaml" + +# Add the directory of the behaviour tree +behaviour_tree_directory: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" + +# Add the absolute path of the urdf and model files inside single qoutes '' +urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" + +# If the robot is spawned by only urdf, then set the model_file to 'None' +model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" + +#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" +criteria: ["Time", "CPU"] + +#Wieght for each criteria as a number from 1 to 9 +#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix +weights: "None" + +# Provide the pose in a decimal form +spawn_pose_x: 1.57 +spawn_pose_y: 8.66 +spawn_pose_yaw: -3.13 #radians + +# Specify either to send one goal, specific trajectory, or several waypoints +# square, circle, several_waypoints, one_goal +trajectory_type: "one_goal" +# One goal parameter +goal_pose_x: -3.86 +goal_pose_y: 4.29 +goal_pose_yaw: 2.58 #radians + diff --git a/config/params.yaml b/config/params.yaml new file mode 100644 index 0000000..c76813c --- /dev/null +++ b/config/params.yaml @@ -0,0 +1,68 @@ +# Name the experiment. This name will be the name of the report +experiment_name: "param_guide" + +#Save directory of results +results_directory: "/home/riotu/ros_ws/src/ROSNavBench/results" + +# Add the absolute path of the world +world_path: "/home/riotu/ros_ws/src/ROSNavBench/simulations/worlds/scenario_world.world" + +# Add the absolute path of the map +map_path: "/home/riotu/ros_ws/src/ROSNavBench/simulations/maps/map.yaml" + +# Add the absolute path of the map +map_png_path: "/home/riotu/ros_ws/src/ROSNavBench/simulations/maps/map.pgm" + +# Add gazebo model path, if multiple path, please spereate them by a : +models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros_ws/src/ROSNavBench/simulations/models" + +# Choose a type of global local planners to be tested +planner_type: ["NavFn", "smac_planner"] +# Choose one of the following controllers, by adding its name to the controller type list +# Note that these are the avaible controllers for the provided example +# DWB +# RPP +# RPP_RSC +# DWB_RSC +controller_type: ["RPP", "DWB", "MPPI"] #name of behaviour tree + +# This option is intended for testing the same controller and planner combination several times +# Min value is one +instances_num: 1 + +# Add the absolute path of the robot navigation configuration +nav_config: "/home/riotu/ros_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle_pi.yaml" + +# Add the directory of the behaviour tree +behaviour_tree_directory: "/home/riotu/ros_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" + +# Add the absolute path of the urdf and model files inside single qoutes '' +urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" + +# If the robot is spawned by only urdf, then set the model_file to 'None' +model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" +#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" +criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] + +#Wieght for each criteria as a number from 1 to 9 +#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix +weights: "None" + +# Provide the pose in a decimal form +spawn_pose_x: 4.0 +spawn_pose_y: -3.0 +spawn_pose_yaw: -3.13 #radians + +# Specify either to send one goal, specific trajectory, or several waypoints +# square, circle, several_waypoints, one_goal +trajectory_type: "circle" +# One goal parameter +goal_pose_x: 4.0 +goal_pose_y: -3.0 +goal_pose_yaw: -3.13 #radians +# Circule parameter, note that the place of spawn will be the center of the circle +radius: 1.1 +# Square parameter +side_length: 3.0 +# Specify way points in this formate [[x0,y0,yaw0_radians], [x1,y1,yaw1_radians], ...] +waypoints: [[-1.3, 2.3, -3.13], [6.0, 2.0, -3.13], [-4.0, 4.0, -3.13]] diff --git a/config/random_waypoints_2.yaml b/config/random_waypoints_2.yaml new file mode 100644 index 0000000..04514b2 --- /dev/null +++ b/config/random_waypoints_2.yaml @@ -0,0 +1,63 @@ +# Name the experiment. This name will be the name of the report +experiment_name: "several_waypoints" + +#Save directory of results +results_directory: "/home/riotu/ros5_ws/src/ROSNavBench/results" + +# Add the absolute path of the world +world_path: "/home/riotu/industrial_warehouse.world" + +# Add the absolute path of the map +map_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" + +# Add the absolute path of the map +map_png_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" + +# Add gazebo model path, if multiple path, please spereate them by a : +models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros5_ws/src/ROSNavBench/simulations/models" + +# Choose a type of global local planners to be tested +planner_type: ["NavFn", "smac_planner"] +# Choose one of the following controllers, by adding its name to the controller type list +# Note that these are the avaible controllers for the provided example +# DWB +# RPP +# RPP_RSC +# DWB_RSC +controller_type: ["RPP", "DWB","MPPI"] #name of behaviour tree + +# This option is intended for testing the same controller and planner combination several times +# Min value is one +instances_num: 5 + +# Add the absolute path of the robot navigation configuration +nav_config: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle_pi.yaml" + +# Add the directory of the behaviour tree +behaviour_tree_directory: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" + +# Add the absolute path of the urdf and model files inside single qoutes '' +urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" + +# If the robot is spawned by only urdf, then set the model_file to 'None' +model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" + +#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" +criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] + +#Wieght for each criteria as a number from 1 to 9 +#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix +weights: "None" + +# Provide the pose in a decimal form +spawn_pose_x: 1.05 +spawn_pose_y: 6.64 +spawn_pose_yaw: -3.13 #radians + +# Specify either to send one goal, specific trajectory, or several waypoints +# square, circle, several_waypoints, one_goal +trajectory_type: "several_waypoints" + +# Specify way points in this formate [[x0,y0,yaw0_radians], [x1,y1,yaw1_radians], ...] +waypoints: [[1.38,2.12, -3.13],[5.45,1.99, -3.13],[5.5,-2.18, -3.13]] + diff --git a/config/rviz_config.rviz b/config/rviz_config.rviz new file mode 100644 index 0000000..b4eca84 --- /dev/null +++ b/config/rviz_config.rviz @@ -0,0 +1,626 @@ +Panels: + - Class: rviz_common/Displays + Help Height: 0 + Name: Displays + Property Tree Widget: + Expanded: + - /Global Options1 + - /TF1/Frames1 + - /TF1/Tree1 + Splitter Ratio: 0.5833333134651184 + Tree Height: 515 + - Class: rviz_common/Selection + Name: Selection + - Class: rviz_common/Tool Properties + Expanded: + - /Publish Point1 + Name: Tool Properties + Splitter Ratio: 0.5886790156364441 + - Class: rviz_common/Views + Expanded: + - /Current View1 + Name: Views + Splitter Ratio: 0.5 + - Class: nav2_rviz_plugins/Navigation 2 + Name: Navigation 2 +Visualization Manager: + Class: "" + Displays: + - Alpha: 0.5 + Cell Size: 1 + Class: rviz_default_plugins/Grid + Color: 160; 160; 164 + Enabled: true + Line Style: + Line Width: 0.029999999329447746 + Value: Lines + Name: Grid + Normal Cell Count: 0 + Offset: + X: 0 + Y: 0 + Z: 0 + Plane: XY + Plane Cell Count: 10 + Reference Frame: + Value: true + - Alpha: 1 + Class: rviz_default_plugins/RobotModel + Collision Enabled: false + Description File: "" + Description Source: Topic + Description Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /robot_description + Enabled: false + Links: + All Links Enabled: true + Expand Joint Details: false + Expand Link Details: false + Expand Tree: false + Link Tree Style: "" + Mass Properties: + Inertia: false + Mass: false + Name: RobotModel + TF Prefix: "" + Update Interval: 0 + Value: false + Visual Enabled: true + - Class: rviz_default_plugins/TF + Enabled: true + Frame Timeout: 15 + Frames: + All Enabled: false + base_footprint: + Value: true + base_link: + Value: true + base_scan: + Value: true + camera_depth_frame: + Value: true + camera_depth_optical_frame: + Value: true + camera_link: + Value: true + camera_rgb_frame: + Value: true + camera_rgb_optical_frame: + Value: true + caster_back_left_link: + Value: true + caster_back_right_link: + Value: true + imu_link: + Value: true + map: + Value: true + odom: + Value: true + wheel_left_link: + Value: true + wheel_right_link: + Value: true + Marker Scale: 1 + Name: TF + Show Arrows: true + Show Axes: true + Show Names: false + Tree: + map: + odom: + base_footprint: + base_link: + base_scan: + {} + camera_link: + camera_depth_frame: + camera_depth_optical_frame: + {} + camera_rgb_frame: + camera_rgb_optical_frame: + {} + caster_back_left_link: + {} + caster_back_right_link: + {} + imu_link: + {} + wheel_left_link: + {} + wheel_right_link: + {} + Update Interval: 0 + Value: true + - Alpha: 1 + Autocompute Intensity Bounds: true + Autocompute Value Bounds: + Max Value: 10 + Min Value: -10 + Value: true + Axis: Z + Channel Name: intensity + Class: rviz_default_plugins/LaserScan + Color: 255; 255; 255 + Color Transformer: Intensity + Decay Time: 0 + Enabled: true + Invert Rainbow: false + Max Color: 255; 255; 255 + Max Intensity: 0 + Min Color: 0; 0; 0 + Min Intensity: 0 + Name: LaserScan + Position Transformer: XYZ + Selectable: true + Size (Pixels): 3 + Size (m): 0.009999999776482582 + Style: Points + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Best Effort + Value: /scan + Use Fixed Frame: true + Use rainbow: true + Value: true + - Alpha: 1 + Autocompute Intensity Bounds: true + Autocompute Value Bounds: + Max Value: 10 + Min Value: -10 + Value: true + Axis: Z + Channel Name: intensity + Class: rviz_default_plugins/PointCloud2 + Color: 255; 255; 255 + Color Transformer: "" + Decay Time: 0 + Enabled: true + Invert Rainbow: false + Max Color: 255; 255; 255 + Max Intensity: 4096 + Min Color: 0; 0; 0 + Min Intensity: 0 + Name: Bumper Hit + Position Transformer: "" + Selectable: true + Size (Pixels): 3 + Size (m): 0.07999999821186066 + Style: Spheres + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Best Effort + Value: /mobile_base/sensors/bumper_pointcloud + Use Fixed Frame: true + Use rainbow: true + Value: true + - Alpha: 1 + Class: rviz_default_plugins/Map + Color Scheme: map + Draw Behind: true + Enabled: true + Name: Map + Topic: + Depth: 1 + Durability Policy: Transient Local + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /map + Update Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /map_updates + Use Timestamp: false + Value: true + - Alpha: 1 + Class: nav2_rviz_plugins/ParticleCloud + Color: 0; 180; 0 + Enabled: true + Max Arrow Length: 0.30000001192092896 + Min Arrow Length: 0.019999999552965164 + Name: Amcl Particle Swarm + Shape: Arrow (Flat) + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Best Effort + Value: /particle_cloud + Value: true + - Class: rviz_common/Group + Displays: + - Alpha: 0.30000001192092896 + Class: rviz_default_plugins/Map + Color Scheme: costmap + Draw Behind: false + Enabled: true + Name: Global Costmap + Topic: + Depth: 1 + Durability Policy: Transient Local + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /global_costmap/costmap + Update Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /global_costmap/costmap_updates + Use Timestamp: false + Value: true + - Alpha: 0.30000001192092896 + Class: rviz_default_plugins/Map + Color Scheme: costmap + Draw Behind: false + Enabled: true + Name: Downsampled Costmap + Topic: + Depth: 1 + Durability Policy: Transient Local + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /downsampled_costmap + Update Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /downsampled_costmap_updates + Use Timestamp: false + Value: true + - Alpha: 1 + Buffer Length: 1 + Class: rviz_default_plugins/Path + Color: 255; 0; 0 + Enabled: true + Head Diameter: 0.019999999552965164 + Head Length: 0.019999999552965164 + Length: 0.30000001192092896 + Line Style: Lines + Line Width: 0.029999999329447746 + Name: Path + Offset: + X: 0 + Y: 0 + Z: 0 + Pose Color: 255; 85; 255 + Pose Style: Arrows + Radius: 0.029999999329447746 + Shaft Diameter: 0.004999999888241291 + Shaft Length: 0.019999999552965164 + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /plan + Value: true + - Alpha: 1 + Autocompute Intensity Bounds: true + Autocompute Value Bounds: + Max Value: 10 + Min Value: -10 + Value: true + Axis: Z + Channel Name: intensity + Class: rviz_default_plugins/PointCloud2 + Color: 125; 125; 125 + Color Transformer: FlatColor + Decay Time: 0 + Enabled: true + Invert Rainbow: false + Max Color: 255; 255; 255 + Max Intensity: 4096 + Min Color: 0; 0; 0 + Min Intensity: 0 + Name: VoxelGrid + Position Transformer: XYZ + Selectable: true + Size (Pixels): 3 + Size (m): 0.05000000074505806 + Style: Boxes + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /global_costmap/voxel_marked_cloud + Use Fixed Frame: true + Use rainbow: true + Value: true + - Alpha: 1 + Class: rviz_default_plugins/Polygon + Color: 25; 255; 0 + Enabled: false + Name: Polygon + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /global_costmap/published_footprint + Value: false + Enabled: true + Name: Global Planner + - Class: rviz_common/Group + Displays: + - Alpha: 0.699999988079071 + Class: rviz_default_plugins/Map + Color Scheme: costmap + Draw Behind: false + Enabled: true + Name: Local Costmap + Topic: + Depth: 1 + Durability Policy: Transient Local + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /local_costmap/costmap + Update Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /local_costmap/costmap_updates + Use Timestamp: false + Value: true + - Alpha: 1 + Buffer Length: 1 + Class: rviz_default_plugins/Path + Color: 0; 12; 255 + Enabled: true + Head Diameter: 0.30000001192092896 + Head Length: 0.20000000298023224 + Length: 0.30000001192092896 + Line Style: Lines + Line Width: 0.029999999329447746 + Name: Local Plan + Offset: + X: 0 + Y: 0 + Z: 0 + Pose Color: 255; 85; 255 + Pose Style: None + Radius: 0.029999999329447746 + Shaft Diameter: 0.10000000149011612 + Shaft Length: 0.10000000149011612 + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /local_plan + Value: true + - Class: rviz_default_plugins/MarkerArray + Enabled: false + Name: Trajectories + Namespaces: + {} + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /marker + Value: false + - Alpha: 1 + Class: rviz_default_plugins/Polygon + Color: 25; 255; 0 + Enabled: true + Name: Polygon + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /local_costmap/published_footprint + Value: true + - Alpha: 1 + Autocompute Intensity Bounds: true + Autocompute Value Bounds: + Max Value: 10 + Min Value: -10 + Value: true + Axis: Z + Channel Name: intensity + Class: rviz_default_plugins/PointCloud2 + Color: 255; 255; 255 + Color Transformer: RGB8 + Decay Time: 0 + Enabled: true + Invert Rainbow: false + Max Color: 255; 255; 255 + Max Intensity: 4096 + Min Color: 0; 0; 0 + Min Intensity: 0 + Name: VoxelGrid + Position Transformer: XYZ + Selectable: true + Size (Pixels): 3 + Size (m): 0.009999999776482582 + Style: Flat Squares + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /local_costmap/voxel_marked_cloud + Use Fixed Frame: true + Use rainbow: true + Value: true + Enabled: true + Name: Controller + - Class: rviz_common/Group + Displays: + - Class: rviz_default_plugins/Image + Enabled: true + Max Value: 1 + Median window: 5 + Min Value: 0 + Name: RealsenseCamera + Normalize Range: true + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /intel_realsense_r200_depth/image_raw + Value: true + - Alpha: 1 + Autocompute Intensity Bounds: true + Autocompute Value Bounds: + Max Value: 10 + Min Value: -10 + Value: true + Axis: Z + Channel Name: intensity + Class: rviz_default_plugins/PointCloud2 + Color: 255; 255; 255 + Color Transformer: RGB8 + Decay Time: 0 + Enabled: true + Invert Rainbow: false + Max Color: 255; 255; 255 + Max Intensity: 4096 + Min Color: 0; 0; 0 + Min Intensity: 0 + Name: RealsenseDepthImage + Position Transformer: XYZ + Selectable: true + Size (Pixels): 3 + Size (m): 0.009999999776482582 + Style: Flat Squares + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /intel_realsense_r200_depth/points + Use Fixed Frame: true + Use rainbow: true + Value: true + Enabled: false + Name: Realsense + - Class: rviz_default_plugins/MarkerArray + Enabled: true + Name: MarkerArray + Namespaces: + {} + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /waypoints + Value: true + - Class: rviz_default_plugins/Marker + Enabled: true + Name: Marker + Namespaces: + basic_shapes: true + Topic: + Depth: 5 + Durability Policy: Volatile + Filter size: 10 + History Policy: Keep Last + Reliability Policy: Reliable + Value: /visualization_marker + Value: true + Enabled: true + Global Options: + Background Color: 48; 48; 48 + Fixed Frame: map + Frame Rate: 30 + Name: root + Tools: + - Class: rviz_default_plugins/MoveCamera + - Class: rviz_default_plugins/Select + - Class: rviz_default_plugins/FocusCamera + - Class: rviz_default_plugins/Measure + Line color: 128; 128; 0 + - Class: rviz_default_plugins/SetInitialPose + Covariance x: 0.25 + Covariance y: 0.25 + Covariance yaw: 0.06853891909122467 + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /initialpose + - Class: rviz_default_plugins/PublishPoint + Single click: true + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /clicked_point + - Class: nav2_rviz_plugins/GoalTool + Transformation: + Current: + Class: rviz_default_plugins/TF + Value: true + Views: + Current: + Angle: -1.6150002479553223 + Class: rviz_default_plugins/TopDownOrtho + Enable Stereo Rendering: + Stereo Eye Separation: 0.05999999865889549 + Stereo Focal Distance: 1 + Swap Stereo Eyes: false + Value: false + Invert Z Axis: false + Name: Current View + Near Clip Distance: 0.009999999776482582 + Scale: 36.80799865722656 + Target Frame: + Value: TopDownOrtho (rviz_default_plugins) + X: -0.044467076659202576 + Y: -0.38726311922073364 + Saved: ~ +Window Geometry: + Displays: + collapsed: false + Height: 1016 + Hide Left Dock: false + Hide Right Dock: true + Navigation 2: + collapsed: false + QMainWindow State: 000000ff00000000fd00000004000000000000016a0000039efc020000000afb0000001200530065006c0065006300740069006f006e00000001e10000009b0000005c00fffffffb0000001e0054006f006f006c002000500072006f007000650072007400690065007302000001ed000001df00000185000000a3fb000000120056006900650077007300200054006f006f02000001df000002110000018500000122fb000000200054006f006f006c002000500072006f0070006500720074006900650073003203000002880000011d000002210000017afb000000100044006900730070006c006100790073010000003d00000240000000c900fffffffb0000002000730065006c0065006300740069006f006e00200062007500660066006500720200000138000000aa0000023a00000294fb00000014005700690064006500530074006500720065006f02000000e6000000d2000003ee0000030bfb0000000c004b0069006e0065006300740200000186000001060000030c00000261fb00000018004e0061007600690067006100740069006f006e002000320100000283000001580000013900fffffffb0000001e005200650061006c00730065006e0073006500430061006d00650072006100000002c6000000c10000002800ffffff000000010000010f0000034afc0200000003fb0000001e0054006f006f006c002000500072006f00700065007200740069006500730100000041000000780000000000000000fb0000000a00560069006500770073000000003d0000034a000000a400fffffffb0000001200530065006c0065006300740069006f006e010000025a000000b200000000000000000000000200000490000000a9fc0100000001fb0000000a00560069006500770073030000004e00000080000002e10000019700000003000004420000003efc0100000002fb0000000800540069006d00650100000000000004420000000000000000fb0000000800540069006d00650100000000000004500000000000000000000005ca0000039e00000004000000040000000800000008fc0000000100000002000000010000000a0054006f006f006c00730100000000ffffffff0000000000000000 + RealsenseCamera: + collapsed: false + Selection: + collapsed: false + Tool Properties: + collapsed: false + Views: + collapsed: true + Width: 1850 + X: 70 + Y: 27 diff --git a/config/square_path_scenario.yaml b/config/square_path_scenario.yaml new file mode 100644 index 0000000..ec9d116 --- /dev/null +++ b/config/square_path_scenario.yaml @@ -0,0 +1,61 @@ +# Name the experiment. This name will be the name of the report +experiment_name: "square_path_scenario" + +#Save directory of results +results_directory: "/home/riotu/ros5_ws/src/ROSNavBench/results" + +# Add the absolute path of the world +world_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/worlds/scenario_world.world" + +# Add the absolute path of the map +map_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/map.yaml" + +# Add the absolute path of the map +map_png_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/map.pgm" + +# Add gazebo model path, if multiple path, please spereate them by a : +models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros5_ws/src/ROSNavBench/simulations/models" + +# Choose a type of global local planners to be tested +planner_type: ["NavFn", "smac_planner"] +# Choose one of the following controllers, by adding its name to the controller type list +# Note that these are the avaible controllers for the provided example +# DWB +# RPP +# RPP_RSC +# DWB_RSC +controller_type: ["RPP", "DWB", "MPPI"] #name of behaviour tree + +# This option is intended for testing the same controller and planner combination several times +# Min value is one +instances_num: 1 + +# Add the absolute path of the robot navigation configuration +nav_config: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle_pi.yaml" + +# Add the directory of the behaviour tree +behaviour_tree_directory: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" + +# Add the absolute path of the urdf and model files inside single qoutes '' +urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" + +# If the robot is spawned by only urdf, then set the model_file to 'None' +model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" +#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" +criteria: ["Time", "Path Length", "CPU", "Memory", "Safety"] + +#Wieght for each criteria as a number from 1 to 9 +#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix +weights: "None" + +# Provide the pose in a decimal form +spawn_pose_x: 2.5 +spawn_pose_y: -4.25 +spawn_pose_yaw: 0.026 #radians + +# Specify either to send one goal, specific trajectory, or several waypoints +# square, circle, several_waypoints, one_goal +trajectory_type: "square" + +# Square parameter +side_length: 2.5 diff --git a/config/static_obstacles.yaml b/config/static_obstacles.yaml new file mode 100644 index 0000000..987d1be --- /dev/null +++ b/config/static_obstacles.yaml @@ -0,0 +1,63 @@ +# Name the experiment. This name will be the name of the report +experiment_name: "static_obstacles_scenario_report_f" + +#Save directory of results +results_directory: "/home/riotu/ros5_ws/src/ROSNavBench/results" + +# Add the absolute path of the world +world_path: "/home/riotu/industrial_warehouse.world" + +# Add the absolute path of the map +map_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.yaml" + +# Add the absolute path of the map +map_png_path: "/home/riotu/ros5_ws/src/ROSNavBench/simulations/maps/warehouse_slam_toolbox.pgm" + +# Add gazebo model path, if multiple path, please spereate them by a : +models_path: "/opt/ros/humble/share/turtlebot3_gazebo/models:/home/riotu/ros5_ws/src/ROSNavBench/simulations/models" + +# Choose a type of global local planners to be tested +planner_type: ["NavFn", "smac_planner"] +# Choose one of the following controllers, by adding its name to the controller type list +# Note that these are the avaible controllers for the provided example +# DWB +# RPP +# RPP_RSC +# DWB_RSC +controller_type: ["RPP", "DWB", "DWB_RSC", "RPP_RSC"] #name of behaviour tree + +# This option is intended for testing the same controller and planner combination several times +# Min value is one +instances_num: 1 +# Add the absolute path of the robot navigation configuration +nav_config: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/nav2_config/waffle_pi.yaml" + +# Add the directory of the behaviour tree +behaviour_tree_directory: "/home/riotu/ros5_ws/src/ROSNavBench/example/turtlebot3/behavior_trees" + +# Add the absolute path of the urdf and model files inside single qoutes '' +urdf_file: "/opt/ros/humble/share/turtlebot3_description/urdf/turtlebot3_waffle_pi.urdf" + +# If the robot is spawned by only urdf, then set the model_file to 'None' +model_file: "/opt/ros/humble/share/turtlebot3_gazebo/models/turtlebot3_waffle_pi/model.sdf" + +#Citeria for performace analysis includes: "Time" ,"CPU", "Memory", "Path Length" , "Safety" +criteria: ["Time", "CPU"] + +#Wieght for each criteria as a number from 1 to 9 +#Set None if the wieght to be set automatcally giving that the importance to the eariler criteria in the matrix +weights: "None" + +# Provide the pose in a decimal form +spawn_pose_x: 1.05 +spawn_pose_y: 6.64 +spawn_pose_yaw: -3.13 #radians + +# Specify either to send one goal, specific trajectory, or several waypoints +# square, circle, several_waypoints, one_goal +trajectory_type: "one_goal" +# One goal parameter +goal_pose_x: -5.6 +goal_pose_y: 2.2 +goal_pose_yaw: -3.13 #radians + diff --git a/example/turtlebot3/behavior_trees/pose.xml b/example/turtlebot3/behavior_trees/pose.xml new file mode 100644 index 0000000..4f853f9 --- /dev/null +++ b/example/turtlebot3/behavior_trees/pose.xml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/turtlebot3/behavior_trees/poses.xml b/example/turtlebot3/behavior_trees/poses.xml new file mode 100644 index 0000000..e8df1e5 --- /dev/null +++ b/example/turtlebot3/behavior_trees/poses.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/turtlebot3/nav2_config/waffle_pi.yaml b/example/turtlebot3/nav2_config/waffle_pi.yaml new file mode 100644 index 0000000..431ef67 --- /dev/null +++ b/example/turtlebot3/nav2_config/waffle_pi.yaml @@ -0,0 +1,763 @@ +amcl: + ros__parameters: + use_sim_time: true + alpha1: 0.2 + alpha2: 0.2 + alpha3: 0.2 + alpha4: 0.2 + alpha5: 0.2 + base_frame_id: "base_footprint" + beam_skip_distance: 0.5 + beam_skip_error_threshold: 0.9 + beam_skip_threshold: 0.3 + do_beamskip: false + global_frame_id: "map" + lambda_short: 0.1 + laser_likelihood_max_dist: 2.0 + laser_max_range: 100.0 + laser_min_range: -1.0 + laser_model_type: "likelihood_field" + max_beams: 60 + max_particles: 2000 + min_particles: 500 + odom_frame_id: "odom" + pf_err: 0.05 + pf_z: 0.99 + recovery_alpha_fast: 0.0 + recovery_alpha_slow: 0.0 + resample_interval: 1 + robot_model_type: "nav2_amcl::DifferentialMotionModel" + save_pose_rate: 0.5 + sigma_hit: 0.2 + tf_broadcast: true + transform_tolerance: 1.0 + update_min_a: 0.2 + update_min_d: 0.25 + z_hit: 0.5 + z_max: 0.05 + z_rand: 0.5 + z_short: 0.05 + scan_topic: scan + +amcl_map_client: + ros__parameters: + use_sim_time: true + +amcl_rclcpp_node: + ros__parameters: + use_sim_time: true + +bt_navigator: + ros__parameters: + use_sim_time: true + global_frame: map + robot_base_frame: base_link + odom_topic: /odom + #default_bt_xml_filename: "navigate_w_replanning_and_recovery.xml" + bt_loop_duration: 10 + default_server_timeout: 20 + enable_groot_monitoring: True + groot_zmq_publisher_port: 1666 + groot_zmq_server_port: 1667 + plugin_lib_names: + - nav2_compute_path_to_pose_action_bt_node + - nav2_compute_path_through_poses_action_bt_node + - nav2_follow_path_action_bt_node + - nav2_back_up_action_bt_node + - nav2_spin_action_bt_node + - nav2_wait_action_bt_node + - nav2_clear_costmap_service_bt_node + - nav2_is_stuck_condition_bt_node + - nav2_goal_reached_condition_bt_node + - nav2_goal_updated_condition_bt_node + - nav2_initial_pose_received_condition_bt_node + - nav2_reinitialize_global_localization_service_bt_node + - nav2_rate_controller_bt_node + - nav2_distance_controller_bt_node + - nav2_speed_controller_bt_node + - nav2_truncate_path_action_bt_node + - nav2_goal_updater_node_bt_node + - nav2_recovery_node_bt_node + - nav2_pipeline_sequence_bt_node + - nav2_round_robin_node_bt_node + - nav2_transform_available_condition_bt_node + - nav2_time_expired_condition_bt_node + - nav2_distance_traveled_condition_bt_node + - nav2_single_trigger_bt_node + - nav2_is_battery_low_condition_bt_node + - nav2_navigate_through_poses_action_bt_node + - nav2_navigate_to_pose_action_bt_node + - nav2_remove_passed_goals_action_bt_node + - nav2_planner_selector_bt_node + - nav2_controller_selector_bt_node + - nav2_goal_checker_selector_bt_node + +bt_navigator_rclcpp_node: + ros__parameters: + use_sim_time: true + +controller_server: + ros__parameters: + use_sim_time: true + controller_frequency: 20.0 + min_x_velocity_threshold: 0.001 + min_y_velocity_threshold: 0.5 + min_theta_velocity_threshold: 0.001 + failure_tolerance: 0.3 + progress_checker_plugin: "progress_checker" + goal_checker_plugins: ["general_goal_checker"] + controller_plugins: + ["MPPI", "DWB_RSC", "RPP", "DWB", "RPP_RSC", "DWB_1", "DWB_2"] + + # Progress checker parameters + progress_checker: + plugin: "nav2_controller::SimpleProgressChecker" + required_movement_radius: 0.5 + movement_time_allowance: 10.0 + + general_goal_checker: + stateful: True + plugin: "nav2_controller::SimpleGoalChecker" + xy_goal_tolerance: 0.25 + yaw_goal_tolerance: 0.25 + + # DWB parameters + + # ROS2 Controller Parameters and Evaluation Criteria + + # Controller 1: DWB_RSC + DWB_RSC: + plugin: "nav2_rotation_shim_controller::RotationShimController" + primary_controller: "dwb_core::DWBLocalPlanner" + debug_trajectory_details: True + angular_dist_threshold: 0.785 + forward_sampling_distance: 0.5 + rotate_to_heading_angular_vel: 1.8 + max_angular_accel: 3.2 + simulate_ahead_time: 1.0 + # DWB parameters + min_vel_x: 0.0 + min_vel_y: 0.0 + max_vel_x: 0.22 + max_vel_y: 0.0 + max_vel_theta: 1.0 + min_speed_xy: 0.0 + max_speed_xy: 0.22 + min_speed_theta: 0.0 + acc_lim_x: 2.5 + acc_lim_y: 0.0 + acc_lim_theta: 3.2 + decel_lim_x: -2.5 + decel_lim_y: 0.0 + decel_lim_theta: -3.2 + vx_samples: 20 + vy_samples: 0 + vtheta_samples: 40 + sim_time: 2.0 + linear_granularity: 0.05 + angular_granularity: 0.025 + transform_tolerance: 0.2 + xy_goal_tolerance: 0.25 + trans_stopped_velocity: 0.05 + short_circuit_trajectory_evaluation: True + stateful: True + critics: + [ + "RotateToGoal", + "Oscillation", + "BaseObstacle", + "GoalAlign", + "PathAlign", + "PathDist", + "GoalDist", + ] + BaseObstacle.scale: 0.02 + PathAlign.scale: 32.0 + PathAlign.forward_point_distance: 0.1 + GoalAlign.scale: 24.0 + GoalAlign.forward_point_distance: 0.1 + PathDist.scale: 32.0 + GoalDist.scale: 24.0 + RotateToGoal.scale: 32.0 + RotateToGoal.slowing_factor: 5.0 + RotateToGoal.lookahead_time: -1.0 + + # Controller 2: RPP + RPP: + plugin: "nav2_regulated_pure_pursuit_controller::RegulatedPurePursuitController" + desired_linear_vel: 0.22 + lookahead_dist: 0.6 + min_lookahead_dist: 0.3 + max_lookahead_dist: 0.9 + lookahead_time: 1.5 + rotate_to_heading_angular_vel: 1.8 + transform_tolerance: 0.2 + use_velocity_scaled_lookahead_dist: false + min_approach_linear_velocity: 0.05 + approach_ve7740404e8c4f locity_scaling_dist: 0.6 + use_collision_detection: true + max_allowed_time_to_collision_up_to_carrot: 1.0 + use_regulated_linear_velocity_scaling: true + use_cost_regulated_linear_velocity_scaling: false + regulated_linear_scaling_min_radius: 0.9 + regulated_linear_scaling_min_speed: 0.25 + use_rotate_to_heading: true + allow_reversing: false + rotate_to_heading_min_angle: 0.785 + max_angular_accel: 3.2 + max_robot_pose_search_dist: 10.0 + use_interpolation: false + + # Controller 3: DWB + DWB: + plugin: "dwb_core::DWBLocalPlanner" + debug_trajectory_details: True + min_vel_x: 0.0 + min_vel_y: 0.0 + max_vel_x: 0.22 + max_vel_y: 0.0 + max_vel_theta: 1.0 + min_speed_xy: 0.0 + max_speed_xy: 0.22 + min_speed_theta: 0.0 + acc_lim_x: 2.5 + acc_lim_y: 0.0 + acc_lim_theta: 3.2 + decel_lim_x: -2.5 + decel_lim_y: 0.0 + decel_lim_theta: -3.2 + vx_samples: 20 + vy_samples: 0 + vtheta_samples: 40 + sim_time: 2.0 + linear_granularity: 0.05 + angular_granularity: 0.025 + transform_tolerance: 0.2 + xy_goal_tolerance: 0.25 + trans_stopped_velocity: 0.25 + short_circuit_trajectory_evaluation: True + stateful: True + critics: + [ + "RotateToGoal", + "Oscillation", + "BaseObstacle", + "GoalAlign", + "PathAlign", + "PathDist", + "GoalDist", + ] + BaseObstacle.scale: 0.02 + PathAlign.scale: 32.0 + PathAlign.forward_point_distance: 0.1 + GoalAlign.scale: 24.0 + GoalAlign.forward_point_distance: 0.1 + PathDist.scale: 32.0 + GoalDist.scale: 24.0 + RotateToGoal.scale: 32.0 + RotateToGoal.slowing_factor: 5.0 + RotateToGoal.lookahead_time: -1.0 + + DWB_1: + plugin: "dwb_core::DWBLocalPlanner" + debug_trajectory_details: True + min_vel_x: 0.0 + min_vel_y: 0.0 + max_vel_x: 0.22 + max_vel_y: 0.0 + max_vel_theta: 1.0 + min_speed_xy: 0.0 + max_speed_xy: 0.22 + min_speed_theta: 0.0 + acc_lim_x: 2.5 + acc_lim_y: 0.0 + acc_lim_theta: 3.2 + decel_lim_x: -2.5 + decel_lim_y: 0.0 + decel_lim_theta: -3.2 + vx_samples: 20 + vy_samples: 0 + vtheta_samples: 40 + sim_time: 3.0 + linear_granularity: 0.05 + angular_granularity: 0.025 + transform_tolerance: 0.2 + xy_goal_tolerance: 0.25 + trans_stopped_velocity: 0.25 + short_circuit_trajectory_evaluation: True + stateful: True + critics: + [ + "RotateToGoal", + "Oscillation", + "BaseObstacle", + "GoalAlign", + "PathAlign", + "PathDist", + "GoalDist", + ] + BaseObstacle.scale: 0.02 + PathAlign.scale: 32.0 + PathAlign.forward_point_distance: 0.1 + GoalAlign.scale: 24.0 + GoalAlign.forward_point_distance: 0.1 + PathDist.scale: 32.0 + GoalDist.scale: 24.0 + RotateToGoal.scale: 32.0 + RotateToGoal.slowing_factor: 5.0 + RotateToGoal.lookahead_time: -1.0 + + DWB_2: + plugin: "dwb_core::DWBLocalPlanner" + debug_trajectory_details: True + min_vel_x: 0.0 + min_vel_y: 0.0 + max_vel_x: 0.22 + max_vel_y: 0.0 + max_vel_theta: 1.0 + min_speed_xy: 0.0 + max_speed_xy: 0.22 + min_speed_theta: 0.0 + acc_lim_x: 2.5 + acc_lim_y: 0.0 + acc_lim_theta: 3.2 + decel_lim_x: -2.5 + decel_lim_y: 0.0 + decel_lim_theta: -3.2 + vx_samples: 20 + vy_samples: 0 + vtheta_samples: 40 + sim_time: 4.0 + linear_granularity: 0.05 + angular_granularity: 0.025 + transform_tolerance: 0.2 + xy_goal_tolerance: 0.25 + trans_stopped_velocity: 0.25 + short_circuit_trajectory_evaluation: True + stateful: True + critics: + [ + "RotateToGoal", + "Oscillation", + "BaseObstacle", + "GoalAlign", + "PathAlign", + "PathDist", + "GoalDist", + ] + BaseObstacle.scale: 0.02 + PathAlign.scale: 32.0 + PathAlign.forward_point_distance: 0.1 + GoalAlign.scale: 24.0 + GoalAlign.forward_point_distance: 0.1 + PathDist.scale: 32.0 + GoalDist.scale: 24.0 + RotateToGoal.scale: 32.0 + RotateToGoal.slowing_factor: 5.0 + RotateToGoal.lookahead_time: -1.0 + + # Controller 4: RPP_RSC + RPP_RSC: + plugin: "nav2_rotation_shim_controller::RotationShimController" + primary_controller: "nav2_regulated_pure_pursuit_controller::RegulatedPurePursuitController" + debug_trajectory_details: True + angular_dist_threshold: 0.785 + forward_sampling_distance: 0.5 + rotate_to_heading_angular_vel: 1.8 + max_angular_accel: 3.2 + simulate_ahead_time: 1.0 + desired_linear_vel: 0.22 + lookahead_dist: 0.6 + min_lookahead_dist: 0.3 + max_lookahead_dist: 0.9 + lookahead_time: 1.5 + transform_tolerance: 0.2 + use_velocity_scaled_lookahead_dist: false + min_approach_linear_velocity: 0.05 + approach_velocity_scaling_dist: 0.6 + use_collision_detection: true + max_allowed_time_to_collision_up_to_carrot: 1.0 + use_regulated_linear_velocity_scaling: true + use_cost_regulated_linear_velocity_scaling: false + regulated_linear_scaling_min_radius: 0.9 + regulated_linear_scaling_min_speed: 0.25 + use_rotate_to_heading: true + allow_reversing: false + rotate_to_heading_min_angle: 0.785 + max_robot_pose_search_dist: 10.0 + use_interpolation: false + + ############# + + MPPI: + plugin: "nav2_mppi_controller::MPPIController" + time_steps: 56 + model_dt: 0.05 + batch_size: 2000 + vx_std: 0.22 + vy_std: 0.2 + wz_std: 0.4 + vx_max: 0.22 + vx_min: -0.35 + vy_max: 0.0 + wz_max: 1.0 + iteration_count: 1 + prune_distance: 1.7 + transform_tolerance: 0.1 + temperature: 0.3 + gamma: 0.015 + motion_model: "DiffDrive" + visualize: false + reset_period: 1.0 # (only in Humble) + regenerate_noises: false + TrajectoryVisualizer: + trajectory_step: 5 + time_step: 3 + AckermannConstraints: + min_turning_r: 0.2 + critics: + [ + "ConstraintCritic", + "ObstaclesCritic", + "GoalCritic", + "GoalAngleCritic", + "PathAlignCritic", + "PathFollowCritic", + "PathAngleCritic", + "PreferForwardCritic", + ] + ConstraintCritic: + enabled: true + cost_power: 1 + cost_weight: 4.0 + GoalCritic: + enabled: true + cost_power: 1 + cost_weight: 5.0 + threshold_to_consider: 1.4 + GoalAngleCritic: + enabled: true + cost_power: 1 + cost_weight: 3.0 + threshold_to_consider: 0.5 + PreferForwardCritic: + enabled: true + cost_power: 1 + cost_weight: 5.0 + threshold_to_consider: 0.5 + ObstaclesCritic: + enabled: true + cost_power: 1 + repulsion_weight: 1.5 + critical_weight: 20.0 + consider_footprint: false + collision_cost: 10000.0 + collision_margin_distance: 0.1 + near_goal_distance: 0.5 + inflation_radius: 0.55 # (only in Humble) + cost_scaling_factor: 10.0 # (only in Humble) + PathAlignCritic: + enabled: true + cost_power: 1 + cost_weight: 14.0 + max_path_occupancy_ratio: 0.05 + trajectory_point_step: 3 + threshold_to_consider: 0.5 + offset_from_furthest: 20 + use_path_orientations: false + PathFollowCritic: + enabled: true + cost_power: 1 + cost_weight: 5.0 + offset_from_furthest: 5 + threshold_to_consider: 1.4 + PathAngleCritic: + enabled: true + cost_power: 1 + cost_weight: 2.0 + offset_from_furthest: 4 + threshold_to_consider: 0.5 + max_angle_to_furthest: 1.0 + mode: 0 + # TwirlingCritic: + # enabled: true + # twirling_cost_power: 1 + # twirling_cost_weight: 10.0 + +controller_server_rclcpp_node: + ros__parameters: + use_sim_time: true + +local_costmap: + local_costmap: + ros__parameters: + update_frequency: 5.0 + publish_frequency: 2.0 + global_frame: odom + robot_base_frame: base_link + use_sim_time: true + rolling_window: true + width: 3 + height: 3 + resolution: 0.05 + robot_radius: 0.22 + plugins: ["obstacle_layer", "voxel_layer", "inflation_layer"] + inflation_layer: + plugin: "nav2_costmap_2d::InflationLayer" + cost_scaling_factor: 1.0 + inflation_radius: 0.55 + obstacle_layer: + plugin: "nav2_costmap_2d::ObstacleLayer" + enabled: True + observation_sources: scan + scan: + topic: /scan + max_obstacle_height: 2.0 + clearing: True + marking: True + data_type: "LaserScan" + voxel_layer: + plugin: "nav2_costmap_2d::VoxelLayer" + enabled: True + publish_voxel_map: True + origin_z: 0.0 + z_resolution: 0.05 + z_voxels: 16 + max_obstacle_height: 2.0 + mark_threshold: 0 + observation_sources: scan + scan: + topic: /scan + max_obstacle_height: 2.0 + clearing: True + marking: True + data_type: "LaserScan" + raytrace_max_range: 3.0 + raytrace_min_range: 0.0 + obstacle_max_range: 2.5 + obstacle_min_range: 0.0 + static_layer: + map_subscribe_transient_local: True + always_send_full_costmap: True + local_costmap_client: + ros__parameters: + use_sim_time: true + local_costmap_rclcpp_node: + ros__parameters: + use_sim_time: true + +global_costmap: + global_costmap: + ros__parameters: + update_frequency: 1.0 + publish_frequency: 1.0 + global_frame: map + robot_base_frame: base_link + use_sim_time: True + robot_radius: 0.22 + resolution: 0.05 + track_unknown_space: true + plugins: + ["static_layer", "obstacle_layer", "voxel_layer", "inflation_layer"] + obstacle_layer: + plugin: "nav2_costmap_2d::ObstacleLayer" + enabled: True + observation_sources: scan + scan: + topic: /scan + max_obstacle_height: 2.0 + clearing: True + marking: True + data_type: "LaserScan" + raytrace_max_range: 3.0 + raytrace_min_range: 0.0 + obstacle_max_range: 2.5 + obstacle_min_range: 0.0 + voxel_layer: + plugin: "nav2_costmap_2d::VoxelLayer" + enabled: True + publish_voxel_map: True + origin_z: 0.0 + z_resolution: 0.05 + z_voxels: 16 + max_obstacle_height: 2.0 + mark_threshold: 0 + observation_sources: scan + scan: + topic: /scan + max_obstacle_height: 2.0 + clearing: True + marking: True + data_type: "LaserScan" + raytrace_max_range: 3.0 + raytrace_min_range: 0.0 + obstacle_max_range: 2.5 + obstacle_min_range: 0.0 + static_layer: + plugin: "nav2_costmap_2d::StaticLayer" + map_subscribe_transient_local: True + inflation_layer: + plugin: "nav2_costmap_2d::InflationLayer" + cost_scaling_factor: 3.0 + inflation_radius: 0.55 + always_send_full_costmap: True + global_costmap_client: + ros__parameters: + use_sim_time: true + global_costmap_rclcpp_node: + ros__parameters: + use_sim_time: true + +map_server: + ros__parameters: + use_sim_time: true + yaml_filename: "/home/riot/src/ros2_ws/src/TFG_Husky_UAL/husky_navigation/maps/warehouse_slam_toolbox.yaml" + +map_saver: + ros__parameters: + use_sim_time: true + save_map_timeout: 5.0 + free_thresh_default: 0.25 + occupied_thresh_default: 0.65 + map_subscribe_transient_local: True + +planner_server: + ros__parameters: + expected_planner_frequency: 20.0 + use_sim_time: true + planner_plugins: ["NavFn", "smac_planner", "HybridA", "ThetaStar"] + + # ROS2 Planner Parameters and Evaluation Criteria + + # Planner 1: NavFn + NavFn: + plugin: "nav2_navfn_planner/NavfnPlanner" + tolerance: 0.5 + use_astar: false + allow_unknown: true + + # Planner 2: smac_planner + smac_planner: + plugin: "nav2_smac_planner/SmacPlanner2D" + tolerance: 0.125 + downsample_costmap: false + downsampling_factor: 1 + allow_unknown: true + max_iterations: 1000000 + max_on_approach_iterations: 1000 + max_planning_time: 2.0 + cost_travel_multiplier: 2.0 + use_final_approach_orientation: false + smoother: + max_iterations: 1000 + w_smooth: 0.3 + w_data: 0.2 + tolerance: 0.0000000001 + + # Planner 3: HybridA + HybridA: + plugin: "nav2_smac_planner/SmacPlannerHybrid" + downsample_costmap: true + downsampling_factor: 1 + tolerance: 0.25 + allow_unknown: true + max_iterations: 1000000 + max_on_approach_iterations: 1000 + max_planning_time: 5.0 + motion_model_for_search: "DUBIN" + angle_quantization_bins: 72 + analytic_expansion_ratio: 3.5 + analytic_expansion_max_length: 3.0 + minimum_turning_radius: 0.40 + reverse_penalty: 2.0 + change_penalty: 0.0 + non_straight_penalty: 1.2 + cost_penalty: 2.0 + retrospective_penalty: 0.015 + lookup_table_size: 20.0 + cache_obstacle_heuristic: false + debug_visualizations: false + smooth_path: True + smoother: + max_iterations: 1000 + w_smooth: 0.3 + w_data: 0.2 + tolerance: 0.0000000001 + do_refinement: true + refinement_num: 2 + + # Planner 4: Lattice + Lattice: + plugin: "nav2_smac_planner/SmacPlannerLattice" + allow_unknown: true + tolerance: 0.25 + max_iterations: 1000000 + max_on_approach_iterations: 1000 + max_planning_time: 5.0 + analytic_expansion_ratio: 3.5 + analytic_expansion_max_length: 3.0 + reverse_penalty: 2.0 + change_penalty: 0.05 + non_straight_penalty: 1.05 + cost_penalty: 2.0 + rotation_penalty: 5.0 + retrospective_penalty: 0.015 + lattice_filepath: "/home/riot/src/ros2_ws/src/ROSNavBench/examples/nav2_config/config.json" + lookup_table_size: 20.0 + cache_obstacle_heuristic: false + allow_reverse_expansion: false + smooth_path: True + smoother: + max_iterations: 1000 + w_smooth: 0.3 + w_data: 0.2 + tolerance: 0.0000000001 + do_refinement: true + refinement_num: 2 + + # Planner 5: ThetaStar + ThetaStar: + plugin: "nav2_theta_star_planner/ThetaStarPlanner" + how_many_corners: 8 + w_euc_cost: 1.0 + w_traversal_cost: 2.0 + w_heuristic_cost: 1.0 + +planner_server_rclcpp_node: + ros__parameters: + use_sim_time: true + +recoveries_server: + ros__parameters: + costmap_topic: local_costmap/costmap_raw + footprint_topic: local_costmap/published_footprint + cycle_frequency: 10.0 + recovery_plugins: ["spin", "backup", "wait"] + spin: + plugin: "nav2_recoveries/Spin" + backup: + plugin: "nav2_recoveries/BackUp" + wait: + plugin: "nav2_recoveries/Wait" + global_frame: odom + robot_base_frame: base_link + transform_timeout: 0.1 + use_sim_time: true + simulate_ahead_time: 2.0 + max_rotational_vel: 1.0 + min_rotational_vel: 0.4 + rotational_acc_lim: 3.2 + +robot_state_publisher: + ros__parameters: + use_sim_time: true + +waypoint_follower: + ros__parameters: + loop_rate: 200 + stop_on_failure: false + waypoint_task_executor_plugin: "wait_at_waypoint" + wait_at_waypoint: + plugin: "nav2_waypoint_follower::WaitAtWaypoint" + enabled: True + waypoint_pause_duration: 200