def graph_lines(lines):
    graph = BidirectedGraph()
    if isinstance(lines, LineString):
        lines = [lines]
    for line in lines:
        last_coord = None
        for coord in line.coords:
            if graph not in coord:
                graph.add_node(coord)
            if last_coord:
                val = {"visited": False}
                graph.connect(coord, last_coord, val)
            last_coord = coord
    return graph
dataset/ETHPy150Open vishnubob/silhouette/printsvg.py/graph_lines/swapped operands of `not in`