From: Olivier MATZ Date: Sun, 7 Mar 2010 19:57:58 +0000 (+0100) Subject: merge X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=844fa3427676e08d7e9f92279788def635377714;p=aversive.git merge --- 844fa3427676e08d7e9f92279788def635377714 diff --cc projects/microb2010/tests/tourel_beacon/graph.py index 4d71030,af8edf8..fa87953 --- a/projects/microb2010/tests/tourel_beacon/graph.py +++ b/projects/microb2010/tests/tourel_beacon/graph.py @@@ -267,9 -257,9 +267,9 @@@ def do_random_test() print "---- random %d"%i x = random.randint(0, 3000) y = random.randint(0, 2100) - a = random.random()*2*math.pi + a = random.random()*2*math.pi - math.pi - graph("test%d.png"%i, x, y, a) - graph_da("test_da%d.png"%i, x, y, a) + graph("angle/test%d.png"%i, x, y, a) + graph_da("da/test_da%d.png"%i, x, y, a) def do_graph_2d(data, filename, title): # Make plot with vertical (default) colorbar @@@ -320,27 -310,18 +320,27 @@@ def do_graph_2d_simple_error() else: title = 'Erreur de position en mm, pour une erreur\n' title += 'de mesure de %s deg sur les 3 balises'%(j) - do_graph_2d(data, "error_a%d_%s.png"%(i,j), title) + do_graph_2d(data, "simple_error/error_a%d_%s.png"%(i,j), title) def do_graph_2d_ad_error(): - for d in ["0.0", "0.1", "0.5"]: - for a in ["0.0", "0.1", "0.5"]: + for d in ["0.0", "0.1", "0.5", "1.0"]: + for a in ["0.0", "0.1", "0.5", "1.0"]: for i in ["0", "1", "2"]: print "do_graph_2d_ad_error %s %s %s"%(i, d, a) - data = get_data("./main da_error %s %s %s"%(i, d, a)) + data = get_data("./main da_error %s %s -%s"%(i, d, a)) title = 'Erreur de position en mm, pour une erreur\n' title += "d'angle de %s deg et dist de %s %% (algo %s)"%(a, d, i) - do_graph_2d(data, "error_da_%s_%s_%s.png"%(i, d, a), title) + do_graph_2d(data, "da_error/error_da_%s_%s_%s.png"%(i, d, a), title) +def do_graph_2d_ad_error_mm(): + for d in ["5", "10", "20"]: + for a in ["0.0", "0.1", "0.5", "1.0"]: + print "do_graph_2d_ad_error_mm 0 %s %s"%(d, a) + data = get_data("./main da_error_mm 0 %s -%s"%(d, a)) + title = 'Erreur de position en mm, pour une erreur\n' + title += "d'angle de %s deg et dist de %s mm"%(a, d) - do_graph_2d(data, "error_da_%smm_%s.png"%(d, a), title) ++ do_graph_2d(data, "da_error_mm/error_da_%smm_%s.png"%(d, a), title) + def do_graph_2d_move_error(): i = 0 for period in [ 20, 40 ]: