Commit ce299cba authored by Moritz Klischat's avatar Moritz Klischat
Browse files

updated to commonroad-io 2020.2

parent f532a126
...@@ -10,7 +10,7 @@ import warnings ...@@ -10,7 +10,7 @@ import warnings
from commonroad.common.util import Interval from commonroad.common.util import Interval
from lxml import etree from lxml import etree
from commonroad.common.file_writer import CommonRoadFileWriter from commonroad.common.file_writer import CommonRoadFileWriter, OverwriteExistingFile
from opendrive2lanelet.network import Network from opendrive2lanelet.network import Network
from opendrive2lanelet.opendriveparser.parser import parse_opendrive from opendrive2lanelet.opendriveparser.parser import parse_opendrive
from sumo_config.default import EGO_ID_START from sumo_config.default import EGO_ID_START
...@@ -61,9 +61,9 @@ def convert_net_to_cr(net_file:str, out_folder:str=None,verbose=False) -> str: ...@@ -61,9 +61,9 @@ def convert_net_to_cr(net_file:str, out_folder:str=None,verbose=False) -> str:
# write CommonRoad scenario to file # write CommonRoad scenario to file
commonroad_writer = CommonRoadFileWriter(scenario, planning_problem_set=None, commonroad_writer = CommonRoadFileWriter(scenario, planning_problem_set=None,
source="Converted from SUMO net using netconvert and OpenDRIVE 2 Lanelet Converter", source="Converted from SUMO net using netconvert and OpenDRIVE 2 Lanelet Converter",
tags='',author='',affiliation='') tags=set(), author='',affiliation='')
with open(cr_map_file, "w") as fh:
commonroad_writer.write_scenario_to_file_io(file_io=fh) commonroad_writer.write_scenario_to_file(filename=cr_map_file, overwrite_existing_file=OverwriteExistingFile.ALWAYS)
return cr_map_file return cr_map_file
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment