Execute model from command line

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Execute model from command line

cnietocoria
Hello,

My model works in this way, I have a number of agents (lets think about 20), all of them at each tick, reads a line from a text file and load in their variables some values. Depending on the values that corresponds to each time step, they generate an output. The output of each agent in a text file is saved (scheduled task). 

I would like to execute my model from a command line, a sort of batch run, although I want to execute just once with out the repast GUI. Hence, I prepared my model as in the documentation suggest. When there is no more information the simulation ends. For each tick i append the new output of the agent in the text file.

Now, I tried with both consoles, the prompt of windows and the bash of Ubuntu for windows. There is something that I'm missing for sure. Because when i perform the batch run, with the wizard it does not generate the text file with the agents output. However, when I execute the model with the repast GUI it stores the agents output in the file and the simulation works fine.

Sorry this might be a silly question, but I'm struggling on this since days

Regards,

Cesar,


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Repast-interest mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/repast-interest
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Execute model from command line

srcnick
Can you confirm that that agent code that creates the file does indeed run? What is the path of the file? If you do a batch run from the wizard it will run in in a temporary location and if the file path is relative, it will be relative to that location.

Nick

On Jun 27, 2017, at 4:48 AM, Cesar Nieto Coria <[hidden email]> wrote:

Hello,

My model works in this way, I have a number of agents (lets think about 20), all of them at each tick, reads a line from a text file and load in their variables some values. Depending on the values that corresponds to each time step, they generate an output. The output of each agent in a text file is saved (scheduled task). 

I would like to execute my model from a command line, a sort of batch run, although I want to execute just once with out the repast GUI. Hence, I prepared my model as in the documentation suggest. When there is no more information the simulation ends. For each tick i append the new output of the agent in the text file.

Now, I tried with both consoles, the prompt of windows and the bash of Ubuntu for windows. There is something that I'm missing for sure. Because when i perform the batch run, with the wizard it does not generate the text file with the agents output. However, when I execute the model with the repast GUI it stores the agents output in the file and the simulation works fine.

Sorry this might be a silly question, but I'm struggling on this since days

Regards,

Cesar,

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________
Repast-interest mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/repast-interest


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Repast-interest mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/repast-interest
Loading...