 
 MAXBUFFER = 1024 * 1024 * 64  # 64MB
 SAVERAW = process.env.SAVERAW
+
+
+osmid = (o) -> "#{o.type}/#{o.id}"
 
 
 exec = (cmd, stdin='') ->


  point = (node) -> turf.point(projectNode(node))

  linestring = (nodes) -> turf.linestring(projectNode(obj[n]) for n in nodes)

  polygon = (nodes) -> turf.polygon([projectNode(obj[n]) for n in nodes])

  bboxPoly = turf.polygon([[
    [bbox[0], bbox[1]]


  segment = (id) ->
    f = linestring(obj[id].nodes)
    f.id = id.split('/')[1]
    return f

  natural = (node) ->
