code: def parse_file(filename, parse_direction=False, **kwargs):
      
      importer, parser = make_importer_parser(OSMParser, **kwargs)
      parser.parse(filename)
  
      return importer.get_graph(parse_direction=parse_direction)
docs: Return an OSM networkx graph from the input OSM file
  
      Only works with OSM xml, xml.bz2 and pbf files. This function cannot take
      OSM QA tile files. Use parse_qa_tile() for QA tiles.
  
      >>> graph = parse_file(filename)