riebl / artery

OMNeT++ V2X simulation framework for ETSI ITS-G5
GNU General Public License v2.0
203 stars 131 forks source link

Running Artery with different values of a parameter #290

Closed HuyTyskland closed 1 year ago

HuyTyskland commented 1 year ago

Hello everyone,

Currently, I am trying to run Artery with different values of a parameter. To be specific, I run a scenario with fixed rate CAM and for the minInterval, I set it to be 0.1 0.2 0.4 0.6 0.8 just to test the iteration feature of Omnetpp.

However, based on section 10.3 of this book or (this instruction)[https://docs.omnetpp.org/tutorials/tictoc/part7/], I need some kind of executable files. And I am not sure how to create one that allow me to do such run.

I want to ask: How can I, in Artery, do "multiple runs based on multiple values of a parameter with just one click"

Best regards, Huy Nguyen.

awillecke commented 1 year ago

Hi,

Artery builds a runner script in your build directory. I think it can be run like this: bash run_artery.sh ../scenarios/artery/omnetpp.ini -c envmod --all. You might need to add -u Cmdenv as a parameter to run Artery on the command line without the GUI.

In this script, you can also see, that Artery is started by executing the OMNeT++ binary (opp_run{all, _release, _debug}), and Artery's components are loaded via shared libraries.

Best regards Alex

HuyTyskland commented 1 year ago

Hello @awillecke , thank you for your response. I know how to do it now.

However, when I run my scenario which use the highway similar to the highway-police scenario, there is an error Could not access configuration 'highway.sumocfg'. Then I tried to run highway-police the same way and the error still there. The error is showed in General-#0.out in highway-police/results:

<!> Error: tcpip::SocketException: tcpip::Socket::connect() @ connect: Connection refused -- in module (traci::Core) World.traci.core (id=5), at t=0s, event #1
HuyTyskland commented 1 year ago

Oh, I figured the error out. Instead of running the command in the build folder in Artery (which I did leading to the error above), I run the command in the folder of my scenario (change the directory in the command) and it worked.