Exemple of issue 314ΒΆ

This example illustrates how to get a region from open stree map database description from its coordinates.

(57.696495, 12.006234) Near Gothenburg (Sweden)

  • ../_images/sphx_glr_plot_issue314_001.png
  • ../_images/sphx_glr_plot_issue314_002.png

Out:

/home/uguen/Bureau/P1/struc/lay/lat_12_0065911_lon_57_6954186.lay

from pylayers.gis.layout import *
# Load the layout from open street map
L = Layout((57.696495, 12.006234),dist_m=200)
# Show the layout
L.showG('s')
plt.show(block=True)
# Load the layout from its .ini file in $BASENAME/struc/ini
L = Layout('lat_57_696495_lon_12_006234.lay')
# Build all the graphs
L.build()
# Check graphs
L._visual_check()
plt.show(block=True)

Total running time of the script: ( 2 minutes 1.636 seconds)

Gallery generated by Sphinx-Gallery