Hello Folks,
Hope you're having a cool Summer :)
*Randomization*:
I have written to script to automate the seed and period values so that I
may run multiple simulation one after other.
veh_period = [3, 4, 6]
PORT = [9534]
op_path = 'C:/Users/vr2002/Music/sumo-win64-0.28.0/sumo-0.28.0/tools/xml/'
import randomTrips
for now_period in veh_period: #loop for varying vehicle density, for same
vehicle density different seeds will be tested, 'Period loop'
for now_port in PORT: #loop for runnning simualtion for different
seeds 'Port loop'
randomTrips.main(randomTrips.get_options([
'--net-file', 'simexp.net.xml',
'--min-distance', '1500',
'--period', str(now_period),
'--binomial', '1',
'--seed', str(now_port),
'--trip-attributes', 'type = \"vdis\" departSpeed = \"max\"',
'--additional-file', 'vdis_rand.add.xml',
'--route-file', 'randomroute.rou.xml']))
Concern:
The output files generated show same no. of vehicles for all the three
values of period I have used, equivalent to period of 6 (close to 580
vehicles). Correct me if I am wrong but periods 4 and 3 should generate
900 and 1200 vehicles respectively.
While saving the output file I include the corresponding value of period in
filename.
*Use of xml2csv.py*:
I have to convert over 150 files from .xml to .csv
So far, the analysis was in it's initial phase and I could do that one file
at a time using the command from command prompt.
I plan to import xml2csv to another python program and pass on the file
name as strings over a loop (the file names will be in a pattern).
Concern:
I don't know how to call xml2csv.py as a subroutine or the required
arguments to pass the filename.
Kindly suggest how I may fix these problems or any another approach to do
the same. Thanks.
Regards,
Vaibhav Rungta
Graduate Student - Industrial and Systems Engineering
585-754-7133
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
sumo-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sumo-user