5 def test(strUrl, iPoints):
6 #define bounding box for test
7 # sw: left-lower corner
13 aXvalues = np.linspace(ne_lng, sw_lng, num=iPoints)
14 aYvalues = np.linspace(sw_lat, ne_lat, num=iPoints)
17 url.urlopen( strUrl % (y,x))
19 strUrlLine = "http://localhost/nominatim/reverse.php?format=json&lat=%f&lon=%f"
20 start_time_line=time.time()
22 end_time_line=time.time()
23 strUrlOld = "http://localhost/nominatim_old/reverse.php?format=json&lat=%f&lon=%f"
24 start_time_old=time.time()
26 end_time_old=time.time()
27 print("Line: --- %s seconds ---" % (end_time_line-start_time_line))
28 print("Old: --- %s seconds ---" % (end_time_old-start_time_old))
30 #tested on 9th March 2016: Line: 354 seconds, Old: 363 seconds (with iPoints=100 => 10.000 single points)
31 # Line: 3.586 sec, Old: 3.643 sec (witch iPoints=10 => 100 single points)