Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding Bicycle as Network Mode in equil scenario #1189

Open
CianGraham opened this issue Dec 13, 2024 · 0 comments
Open

Adding Bicycle as Network Mode in equil scenario #1189

CianGraham opened this issue Dec 13, 2024 · 0 comments

Comments

@CianGraham
Copy link

I would like to add a new network mode, NLBicycle, in the equil scenario. I have adapted my network, and config, and add scoring parameter, but still it is not working... I will attach my config and network at the end of this message.

equil.zip

The code I used is:

`public class RunMatsim{

public static void main(String[] args) {

	Config config;
	if ( args==null || args.length==0 || args[0]==null ){
		config = ConfigUtils.loadConfig( "scenarios/equil/config.xml" );
	} else {
		config = ConfigUtils.loadConfig( args );
	}

	config.controller().setOverwriteFileSetting( OverwriteFileSetting.overwriteExistingFiles );

	ScoringConfigGroup.ModeParams NLBicycleParam = new ScoringConfigGroup.ModeParams("NLBicycle");
	NLBicycleParam.setConstant(99);
	config.scoring().addModeParams(NLBicycleParam);

	// possibly modify config here

	// ---
	
	Scenario scenario = ScenarioUtils.loadScenario(config) ;

	// possibly modify scenario here

	
	// ---
	
	Controler controler = new Controler( scenario ) ;
	
	// possibly modify controler here

// controler.addOverridingModule( new OTFVisLiveModule() ) ;

// controler.addOverridingModule( new SimWrapperModule() );

	// ---


	controler.run();
}

}`

The error I have is:
2024-12-13T17:56:47,732 ERROR AbstractController:225 Mobsim did not complete normally! afterMobsimListeners will be called anyway. java.lang.RuntimeException: teleportation does not work when travel time is undefined. There is also really no magic fix for this, since we cannot guess travel times for arbitrary modes and arbitrary landscapes. kai/mz, apr'15 & feb'16 at org.matsim.core.mobsim.qsim.DefaultTeleportationEngine.handleDeparture(DefaultTeleportationEngine.java:93) ~[matsim-2024.0.jar:?]

@CianGraham CianGraham changed the title Adding Bicycle as Network Mode in equil scenario (Please Help, thanks very much in advance, it really means a lot to me) Adding Bicycle as Network Mode in equil scenario Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant