if you modified the network, make sure that the call to randomTrips is using that new network when passing option -n
Am Mo., 20. März 2023 um 23:40 Uhr schrieb Gervalino Bilas < [email protected]>: > You are right. > > Really gave me just 50 pedestrians and finally I understood the > intermediate parameter (1000 intermediate walks). But I'm still having > problems running my simulation. > I'm trying to change a simulation that I built using the OSM Wizard to > have a restricted area. Running what wizard gave to me, the simulation runs > fine - but not with just 50 pedestrians. > > This is the build.bat file changed with your tip: python > "%SUMO_HOME%\tools\randomTrips.py" -n osm.net.xml.gz -o > osm.pedestrian.trips.xml -r osm.pedestrian.rou.xml -e 50 --vclass > pedestrian --prefix ped --pedestrians --intermediate 1000. > But when I run it, the simulation doesn't run anymore. I think it is > because the "osm.pedestrian.rou.xml" is empty. > > I tried to run using a python script based on Traci Tutorials, but it > didn't work either. > Method "getMinExpectedNumber" returns zero and getIDList as well. > > def run(): > while traci.simulation.getMinExpectedNumber() > 0: > traci.simulationStep() > > lstPeopleId = traci.person.getIDList() > > for personId in lstPeopleId: > x, y = traci.person.getPosition(personId); > > lon, lat = traci.simulation.convertGeo(x, y) > > person = [personId, x, y, lat, lon, random.randint(0,355), > traci.simulation.getTime()] > print(person) > > traci.close() > > > Em seg., 20 de mar. de 2023 às 04:50, Jakob Erdmann <[email protected]> > escreveu: > >> With the suggested option, what you should be getting are 50 pedestrians >> (not 60) each having a number of walks. >> Effektively, each pedestrian will keep walking around the network and you >> won't really see where one walk ends and another walk starts (if you look >> at fcd-output). >> You can take the position of each pedestrian at some fixed time of your >> choice to get those locations. (i.e. once per hour by using options >> --fcd-output fcd.xml --person-device.fcd.period 3600). >> >> Am Do., 16. März 2023 um 19:15 Uhr schrieb Gervalino Bilas < >> [email protected]>: >> >>> Hi Jacob. >>> Thanks for anwer me. >>> >>> Well, running with your tip I do get 50 pedestrian (actually 60 because >>> the --intermediate parameter). >>> Those pedestrians have ids from 0 to 50. (ex: *ped01)* >>> >>> But what I need is to have 50 walks for 50 different pedestrians and >>> check their final location (x,y). Then, one after that, I have to do >>> another 50 walks but *with the same *50 pedestrians. >>> I have to do this 13 times. >>> At the end of this simulations, I got to have 13 registers of >>> each pedestrians with their location (after the walk) >>> >>> Any clue will be helpful. >>> >>> Regards, >>> >>> Em qua., 15 de mar. de 2023 às 21:06, Jakob Erdmann < >>> [email protected]> escreveu: >>> >>>> use: randomTrips.py -e 50 --pedestrians --intermediate 1000 >>>> >>>> The value of 1000 is just a placeholder. The needed number of >>>> intermediate locations depends roughly on the desired travel duration >>>> divided by the time it takes to traverse the network from one end to >>>> another. >>>> >>>> >>>> Am Mi., 15. März 2023 um 19:49 Uhr schrieb Gervalino Bilas < >>>> [email protected]>: >>>> >>>>> Hello. >>>>> >>>>> I'm trying to simulate 50 pedestrians walking by some fixed area for >>>>> 13 hours. >>>>> My goal is to get the position (x,y ou geographic location) from every >>>>> one of them hour by hour. So my simulation has to run with the same 50 >>>>> pedestrians. >>>>> >>>>> By now, using OSM Web Wizard, I could generate a simulation in my >>>>> fixed area only for pedestrians by 13 hours. But it's not the same >>>>> pedestrians - 743 pedestrians were generated. >>>>> I tried to repeat the same *pedID *13 times, but it didn't work. >>>>> >>>>> How can I run a simulation with the 50 pedestrians for 13 hours >>>>> getting their position hour by hour? >>>>> >>>>> Best regards, >>>>> _______________________________________________ >>>>> sumo-user mailing list >>>>> [email protected] >>>>> To unsubscribe from this list, visit >>>>> https://www.eclipse.org/mailman/listinfo/sumo-user >>>>> >>>> _______________________________________________ >>>> sumo-user mailing list >>>> [email protected] >>>> To unsubscribe from this list, visit >>>> https://www.eclipse.org/mailman/listinfo/sumo-user >>>> >>> _______________________________________________ >>> sumo-user mailing list >>> [email protected] >>> To unsubscribe from this list, visit >>> https://www.eclipse.org/mailman/listinfo/sumo-user >>> >> _______________________________________________ >> sumo-user mailing list >> [email protected] >> To unsubscribe from this list, visit >> https://www.eclipse.org/mailman/listinfo/sumo-user >> > _______________________________________________ > sumo-user mailing list > [email protected] > To unsubscribe from this list, visit > https://www.eclipse.org/mailman/listinfo/sumo-user >
_______________________________________________ sumo-user mailing list [email protected] To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user
