signetlabdei / sem

A framework to manage ns-3 simulation campaigns: let SEM perform multiple parallelized executions of your ns-3 scenario, permanently save the results and output them in plotting-friendly data structures. All from the comfort of the command line or in a few, clean lines of Python code.
https://simulationexecutionmanager.rtfd.io
GNU General Public License v2.0
34 stars 30 forks source link

Allow re-use of RngRun parameter #29

Closed DvdMgr closed 6 years ago

DvdMgr commented 6 years ago

We should devise an ergonomic way to allow users to specify an RngRun parameter together with their simulation parameter combinations. This can come in handy if one wants to compare two simulations using the same RngRun (to get the same placement of buildings and devices, for instance) and compare two different parameter combinations.

DvdMgr commented 6 years ago

Implemented in a2f8b68

matbord commented 3 years ago

Hi, where can I find an example of how to re-use the RngRun parameters? I would like to compare two simulations using the same set of RngRun parameters. For each simulation I'm actually doing

parameters= #set of parameters for NS3  
runs = 4  
campaign.run_missing_simulations(parameters, runs=runs)

Thank you

DvdMgr commented 3 years ago

You can omit the runs argument in run_missing_simulations, and instead specify the desired RngRun range directly from the parameter dictionary! So, something along the lines of:

params = {
    'aParameter': [someValue],
    'RngRun': [1, 2, 3]
}
campaign.run_missing_simulations(params)

should work. You can also specify RngRun in the parameter dictionary you use for queries and to get data out of the database.