Re: [sumo-user] problem in xml2csv

2016-10-07 Thread François Vaudrin
Hello,

I use Ubuntu. and I suggest to close all the windows at the end of the 
simulation to complete the result file. 

[Simulation ended]
Do you want to close all open files and views?
Answer : Yes

Best regards

François 

De : Michael Behrisch [behri...@users.sourceforge.net]
Envoyé : 7 octobre 2016 11:57
À : Sangeetha M; sumo-user@lists.sourceforge.net
Objet : Re: [sumo-user] problem in xml2csv

Hi,
the error suggests that the simulation was not finished or the file was
not closed properly. Please have a look at the file whether it looks
like it ended in the middle and double checked whether your simulation
was aborted for some reason.

Best regards,
Michael

Am 07.10.2016 um 12:38 schrieb Sangeetha M:
>   I am not able to convert output files in xml to csv, I used the following 
> command.
> "xml2csv.py mbfcdout.xml"
> Yesterday it worked, but not today. Please help me in resolving the issue. 
> The errors I get are attached.Sangeetha
>
>
>
> --
> 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
> sumo-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/sumo-user
>


--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user

--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


Re: [sumo-user] Bug in TraCI doc on vehicle reroute

2016-10-07 Thread Michael Behrisch
Hi,
thanks for pointing it out, it is fixed now.

Best regards,
Michael

Am 07.10.2016 um 16:17 schrieb Dominik S. Buse:
> Hello,
> 
> it seems as if the description in this section is incorrect:
> http://sumo.dlr.de/wiki/TraCI/Change_Vehicle_State#reroute_.28compute_new_route.29_by_effort_.280x91.29
> 
> In the current source of TraCIServerAPI_Vehicle.cpp it even says:
> 
>> "Rerouting should obtain an empty compound object."
> 
> 
> Kind regards,
> Dominik S. Buse
> 


--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


[sumo-user] Rerouting traffic with traci

2016-10-07 Thread Iris Bekker
Dear SUMO list,

I am still busy with setting up some experiments with routing traffic. 
Originally I intended to do all the route-calculations myself, and then 
assign the new routes to vehicles using traci. However, SUMO also 
supports its own rerouting. Time to investigate!

As usual, I find myself getting stuck with details. So let's start: 
changeTarget(self, vehID, edgeID) reroutes the car to the chosen edge. I 
belief the routing algorithm used is the one selected with the 
--routing-algorithm option when initializing SUMO? Is it true that the 
Dijkstra's algorithm being used is not randomized? And does this reroute 
use distance or expected travel times?

Second, I wonder about rerouteTravelTime() and rerouteEffort(). The 
latter reroutes based on the amount of energy is required to finish the 
route I presume? Do I understand correctly that rerouteTravelTime() on a 
car traveling from A to B should give the same result as calling 
changeTarget() on a car standing at A heading to B?

Also, is there a way of having a car automatically using the routing 
algorithm when it gets added? Right now, I intend to use 
traci.vehicle.addFull(vehID, "ID of edge car is currently on", ...) and 
then changeTarget() to get this behaviour.

I expect that having SUMO do the routing will be quicker than calling 
all the edge's adapted travel times through traci, finding a route, and 
then sending that back through traci. However, I will try and run some 
benchmarks in the near future. Also, I am interested in how SUMO 
calculates the adapted travel time of an edge, though I expect I can 
find this on the wiki if I look for it more thoroughly.

As always, thank you very much for all your help,

Iris Bekker


--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


[sumo-user] Bug in TraCI doc on vehicle reroute

2016-10-07 Thread Dominik S. Buse
Hello,

it seems as if the description in this section is incorrect:
http://sumo.dlr.de/wiki/TraCI/Change_Vehicle_State#reroute_.28compute_new_route.29_by_effort_.280x91.29

In the current source of TraCIServerAPI_Vehicle.cpp it even says:

> "Rerouting should obtain an empty compound object."


Kind regards,
Dominik S. Buse

-- 
Dominik Buse M.Sc.
Distributed Embedded Systems (CCS Labs)
Heinz Nixdorf Institut, Paderborn University, Germany
http://www.ccs-labs.org/~buse/


--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


[sumo-user] Save the Date May 8 - 10 SUMO 2017 conference Berlin

2016-10-07 Thread Michael Behrisch
Dear friends and users,
time is running and we are starting to prepare the next SUMO user 
conference.
So please open your calendars and book your flights to Berlin for the 
fifth edition
of this event taking place from

  8th to 10th May 2017 at DLR Berlin.

Due to the positive feedback we will start again with a tutorial 
followed by two days
of talks about results and experiments with microscopic traffic 
simulation.
A call for paper and a website will follow soon.

Best regards,
Michael

--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


Re: [sumo-user] randomTrips

2016-10-07 Thread Michael Behrisch
Hi Hannah,
this is not possible, because the script cannot know which vehicle 
should get which type. If you want to assign them at random you can use 
a vehicle type distribution 
http://sumo.dlr.de/wiki/Definition_of_Vehicles,_Vehicle_Types,_and_Routes#Route_and_vehicle_type_distributions
 
and give the name of the distribution there. If you have some other 
parameters determining the type simply do multiple runs of 
randomTrips.py for all different types and feed all resulting route file 
sinto the simulation.

Best regards,
Michael

Am 2016-10-07 10:18, schrieb Hannah Parker:
> Hi,
> 
> I'm using randomTrips to create traffic for my network. I am using an
> additional file with all my vtypes in it and using the command from the
> example on http://sumo.dlr.de/wiki/Tools/Trip :
> 
> /tools/randomTrips.py -n input_net.net.xml
> --trip-attributes="type=\"myType\"" --additional-file type.add.xml
>--edge-permission passenger
> 
> I have several vtypes defined in my additional file. Is it possible to 
> add
> multiple type="myType" parameters into the --trip-attributes=?
> 
> Thank you.
> 
> Hannah
> --
> 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
> sumo-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/sumo-user

--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


Re: [sumo-user] How to convert from string to double for TraCI python code

2016-10-07 Thread Michael Behrisch
Hi Ankur Sarker,
your code looks OK except that you did not cover the case in 
decideSpeedValue when the condition "abc <= float(dis[j])" never gets 
true. The function will return None in this case which is not a valid 
float. So string conversion may not be your real problem.

Best regards,
Michael

Am 2016-10-06 23:14, schrieb Ankur Sarker:
> Or, can anyone tell me how to convert String (in python) to TYPE_DOUBLE 
> (
> in SUMO)? *TYPE_DOUBLE* is defined in Sumo/tools/traci/constant.py.
> 
> Actually, I am not so familiar with python programming language.
> 
> Thanks,
> Ankur Sarker
> 
> 
> On Thu, Oct 6, 2016 at 1:38 PM, Ankur Sarker  
> wrote:
> 
>> Hi,
>> 
>> I am trying to call traci.vehicle.setSpeed() using TraCI python 
>> interface
>> and I am having hard time to convert string to double.
>> 
>> Can anyone give me suggestion?
>> 
>> *-*
>> *My function: *
>> 
>> def decideSpeedValue(abc):
>> dis = [line.rstrip('\n') for line in open('distance.txt')]
>> speed = [line.rstrip('\n') for line in open('speed.txt')]
>> for j in range(len(dis)):
>> if abc <= float(dis[j]):
>> return float(speed[j])
>> 
>> *Function call:*
>> 
>> vehicles = traci.vehicle.getIDList()
>> for word in vehicles:
>> if word == "kang":
>> distance = traci.vehicle.getDistance("kang")
>> 
>> *traci.vehicle.setSpeed("kang",decideSpeedValue(distance))*
>> 
>> *I get the following error:*
>> 
>>   File "C:\Program Files (x86)\DLR\Sumo\tools\traci\_vehicle.py", line
>> 757, in s
>> etSpeed
>> tc.CMD_SET_VEHICLE_VARIABLE, tc.VAR_SPEED, vehID, speed)
>>   File "C:\Program Files (x86)\DLR\Sumo\tools\traci\connection.py", 
>> line
>> 139, in
>>  _sendDoubleCmd
>> *self._string += struct.pack("!Bd", tc.TYPE_DOUBLE, value)*
>> *struct.error: required argument is not a floa*t
>> --
>> 
>> Thanks for your time!
>> 
>> With Regards,
>> Ankur Sarker
>> 
> --
> 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
> sumo-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/sumo-user

--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


[sumo-user] randomTrips

2016-10-07 Thread Hannah Parker
Hi,

I'm using randomTrips to create traffic for my network. I am using an
additional file with all my vtypes in it and using the command from the
example on http://sumo.dlr.de/wiki/Tools/Trip :

/tools/randomTrips.py -n input_net.net.xml
--trip-attributes="type=\"myType\"" --additional-file type.add.xml
   --edge-permission passenger

I have several vtypes defined in my additional file. Is it possible to add
multiple type="myType" parameters into the --trip-attributes=?

Thank you.

Hannah
--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


[sumo-user] querry on arrival distribution

2016-10-07 Thread Sangeetha M
  Hi,
How do I generate random vehicles? If I want to use binomial distribution,  
where do I fit  "-b t0 -e t1 -p ((t1 - t0) / n)"? I would like to use different 
distributions for different periods of time during the day(peak and off peak). 
How is it possible with SUMO? Which all distributions are possible with SUMO? 

thank youSangeetha
--
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
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user