matsim-org / matsim-code-examples

A repository containing code examples around MATSim
GNU General Public License v3.0
83 stars 180 forks source link

Mixed Traffic Population - Cars and Taxis #409

Closed NikolaAndro closed 3 years ago

NikolaAndro commented 4 years ago

Hello,

I am trying to combine cars and taxis.

When creating the mixed population, I tried to set it to population_v5.dtd or population_v6.dtd type file, but neither of them worked. Do I need to create one for such a case?

My Failure Trace directs me to the calcDistanceExcludingStartEndLink function. I do not see why that would be a problem since the same network worked for the separate examples.

I am attaching my GitHub link where you can see my code and my error information inside the output/pigou_mixed_traffic.

https://github.com/NikolaAndro/Pigou-s-Example

Thank you!

michalmac commented 4 years ago

the modified config contains:

<param name="inputPlansFile" value="plans_mixed_traffic.xml.gz"/>

but your file is just plans_mixed_traffic.xml

NikolaAndro commented 4 years ago

Mr. Michal,

Thank you for your response. plans_mixewd_traffic.xml file is jut there because I need to have it in that format in order to edit it. Once I edit it, I convert it back to .gz file and use it in the config file as .gz file. I do not think that is an issue.

Those are the last 3 lines of the output when I try to run it. It won't load population_v5.dtd for some reason.

2020-10-04T10:25:18,242 INFO MatsimXmlParser:160 starting to parse xml from url file:/C:/Users/Admin/Desktop/Pigou's%20Example/Pigou's%20Example/scenarios/Pigou_multiModal_2020/plans_mixed_traffic.xml.gz ... 2020-10-04T10:25:18,250 INFO PopulationReader:130 using population_v5-reader. 2020-10-04T10:25:18,250 INFO MatsimXmlParser:275 Trying to load http://www.matsim.org/files/dtd/population_v5.dtd. In some cases (e.g. network interface up but no connection), this may take a bit.

michalmac commented 4 years ago

It looks like the network file does not contain all links referred to in the plans file.

NikolaAndro commented 4 years ago

Thank you so much! I was referring to nodes instead of links.... Again, thank you!