From: Daniel K. <d.k...@go...> - 2012-01-23 14:57:56
|
Dear Emilio, I would extend the vehroutes (MSDevice_Vehroute) class. MSVehicle is already very big an in the case you want your modifications be included in SUMO, you should not pollute MSVehicle even more... In MSDevice_Vehroutes you already are informed about the entry and the leaving time. What I do not understand, yet, is how you plan to use the values; I mean: the average travel time changes in each second, right? When do you want to read it? After the simulation's run? If not, then how do you want to obtain it? sincerely, Daniel 2012/1/20 Emilio Martin <emi...@gm...> > Dear Daniel, > > Yes I mean, average speed since the vehicle have entered in the lane. I > have been taking a look to MSDevice_Vehroutes class, as far I knwo which is > the responsable of writing your aforementioned XML, however this class only > implements exit times. One could be modify this class in order to fulfill > our requirements. In my non-expert opinion the easy way is to insert two > new atritubutes in MSVehicle, SUMOTime timeEnterCurrLane, and SUMOReal > initialPositionLane. > > In this case with the current position vehicle on lane, and the > currentTimeStep we could calculate the avaragespeed on Lane = > (currentPostionOnLane- initialPositionLane) / > (currentTimeStep-timeEnterCurrLane), the other values are quiet simples. > > Here my question is, in wich methods i should modify the above atributes > (timeEnterCurrLane, initialPositionLane). I mean, in what method of > MSVehicle class is performed the movement's vehicles ? > > Thanks in advance, and kind regards. > > > > > El 20 de enero de 2012 12:20, Daniel Krajzewicz < > d.k...@go...> escribió: > > Dear Emilio, >> >> Maybe you can use the vehroutes output, which, if you start SUMO with >> --vehroute-output.exit-times --vehroute-output=vehroutes.xml, contains the >> times the vehicle leaves each edge as following: >> <vehicle id="0" depart="0.00" arrival="147.00"> >> <route edges="4/1to3/1 3/1to2/1 2/1to1/1 1/1to0/1" >> exitTimes="30.00 69.00 108.00 147.00"/> >> </vehicle> >> >> I mean, what you are trying to have is the edge, the lane, lane enter >> time, average speed on lane, time on lane. You know, the average speed at >> least is ambigous - do you mean the average speed since entering the lane >> or the average speed for passing the lane. Also, if you want to have it at >> each time step, you won't have entry and exit times at once... >> >> My idea was to implement a variable output where one can define what >> shall be written and when. But I haven't started to implement it, yet. Will >> also not start in the next time, I think. >> >> sincerely, >> Daniel >> >> >> 2012/1/19 Emilio Martin <emi...@gm...> >> >>> Hi, >>> >>> I would know which would be the easier way to modify SUMO in order to >>> obtain the following XML, >>> >>> <timestep="" >>> <edge="" >>> <lane="" >>> <vehicle >>> time_enter_line = "Time wich vehicle was inserted at this lane" >>> Average_speed = "Avarge speed in this lane" >>> time_into_line = Time spent to move along the lane >>> /> >>> /> >>> >>> Of course, using the original raw data output and a post-processing with >>> a >>> SAX parser, we could obtain this information, but we will obtain a worse >>> performance. >>> >>> So we decided to try to modify Sumo. We are trying to modify class >>> MSXMLRawOut in order to obtain the desired output, but the fact is that >>> the >>> MSVehicle class doesn't provide this information, so I suppose that I >>> should modify also MSVehicle class. >>> >>> Here is my problem I don't know how modify this class in order obtain >>> correct values for the aforementioned propierties (time_enter_line, >>> Average_speed, time_into_line) , I'm a bit confused about how sumo >>> performs >>> the vehicle's movements. >>> >>> I hope that some Sumo's developer can help me :-) >>> >>> >>> Thanks in advance and king regards. >>> >>> >>> *********************************************** >>> Emilio Martin Gallardo >>> *********************************************** >>> >>> ------------------------------------------------------------------------------ >>> Keep Your Developer Skills Current with LearnDevNow! >>> The most comprehensive online learning library for Microsoft developers >>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >>> Metro Style Apps, more. Free future releases when you subscribe now! >>> http://p.sf.net/sfu/learndevnow-d2d >>> _______________________________________________ >>> sumo-user mailing list >>> sum...@li... >>> https://lists.sourceforge.net/lists/listinfo/sumo-user >>> >> >> > > > -- > *********************************************** > Emilio Martín Gallardo > Departamento de Informática > Despacho: 2.1.B16 > Telefono: 916248879 > Universidad Carlos III de Madrid > Escuela Politécnica Superior (Leganés) > *********************************************** > |