Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Stop-to-stop travel times and Public Transport schedules

Hi Fay,

it has to do something with character encoding (e.g. UTF-8 vs ISO8859).

Check whether the coding in additional.xml (first line) matches the used character set in the rest.

It seems that the parser uses codepage 1253, but in the rest of the file the coding might be UTF-8.

Regards, Harald

Am 10.04.20 um 19:39 schrieb Fay Kostopoulou:
Dear all,

I am trying to import stop to stop travel times and PT schedules via 
running " python -n -s additional.xml -l ptlines.xml  -o flows.rou.xml -p 600 --use-osm-routes ", but it gives me the following error message: 

generating trips...
Traceback (most recent call last):
  File "", line 357, in <module>
  File "", line 350, in main
    trpMap, stopNames = createTrips(options)
  File "", line 119, in createTrips
    for stop in sumolib.output.parse(options.ptstops, 'busStop'):
  File "C:\Program Files (x86)\Eclipse\Sumo\tools\sumolib\", line 252, in parse
    for _, parsenode in ET.iterparse(_open(xmlfile)):
  File "C:\Users\Fay\AppData\Local\Programs\Python\Python38-32\lib\xml\etree\", line 1229, in iterator
    data = "" * 1024)
  File "C:\Users\Fay\AppData\Local\Programs\Python\Python38-32\lib\encodings\", line 23, in decode
    return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x9f in position 1097: character maps to <undefined>

Could you help me with it?

Thank you for your time,

sumo-user mailing list
To unsubscribe from this list, visit

Back to the top