Re: [sumo-user] Mismatch between chosen lane using TraCI and lane change state

2022-05-24 Thread Hriday Sanghvi via sumo-user
Hello,

I hope you are able to access the files from the attachment as intended?

Thank you.

Sincerely,
Hriday


On Thu, 19 May 2022 at 12:36, Hriday Sanghvi  wrote:

>
> Hello again,
>
> Thank you for your response. I am reattaching the zip file with the
> following files renamed:
> - simulate-sublane.sh renamed to simulate-sublane.txt
> - sublanechange.py renamed to sublanechange.txt
>
>
> >>> ex1: looks ok: the vehicle could change lane but just doesn't want to
> (left/right are missing from the state) - couldAndWant requires both
> opportunity *and* intent
> The information missing from the state is what is causing my doubt. I
> can't tell *why* it doesn't want to after being commanded by TraCI to do
> the same. Not sure where the 'want' even arises from - as in SUMO wants to
> do something else? That is if there is an opportunity to lane change
> (couldChangeLane is True), and TraCI tells it to (wants to change Lane),
> should it not follow the command?
>
> >>> ex4: like ex1 but the screenshot doesn't show the agents in question
> Agent f.4 is just inserted into the lane with index 1 at the beginning of
> the lane, and agent f.5 is one of the vehicles in the middle of the lane
> with index 0. The vehicle ids are shown in red on top of the vehicles. I'm
> not sure if the screenshots were filtered in some way.
>
> Looking forward to your response.
>
> Sincerely,
> Hriday
>
> On Thu, 19 May 2022 at 11:47, Jakob Erdmann  wrote:
>
>> > Thank you for your response. The exact method calls are the same as
>> those provided in the actual code (in the zip file previously):
>>
>> The previous zip did not contain your traci code but only XML files, so
>> please send this again.
>>
>>
>> > The attached files ordered from ex0.png to ex5.png are some example
>> screenshots of the issues.
>>
>> - ex0 : working as intended: invalid targets are supposed to return false
>> to 'could/want' calls
>> - ex1: looks ok: the vehicle could change lane but just doesn't want to
>> (left/right are missing from the state) - couldAndWant requires both
>> opportunity *and* intent
>> - ex2: needs further investigation (once I can run your code)
>> - ex3: looks to me like a mixup of directions: the vehicle wants to do a
>> (sublane) change to the left and you're asking whether it could change to
>> the right (no). Looks still a bit strange because the 'sublane' flag is
>> missing from it's state so I'd still look at this
>> - ex4: like ex1 but the screenshot doesn't show the agents in question
>> - ex5: needs further investigation (once I can run your code)
>>
>> ___
>> sumo-user mailing list
>> sumo-user@eclipse.org
>> To unsubscribe from this list, visit
>> https://www.eclipse.org/mailman/listinfo/sumo-user
>>
>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] Mismatch between chosen lane using TraCI and lane change state

2022-05-19 Thread Hriday Sanghvi via sumo-user
Hello again,

Thank you for your response. I am reattaching the zip file with the
following files renamed:
- simulate-sublane.sh renamed to simulate-sublane.txt
- sublanechange.py renamed to sublanechange.txt


>>> ex1: looks ok: the vehicle could change lane but just doesn't want to
(left/right are missing from the state) - couldAndWant requires both
opportunity *and* intent
The information missing from the state is what is causing my doubt. I can't
tell *why* it doesn't want to after being commanded by TraCI to do the
same. Not sure where the 'want' even arises from - as in SUMO wants to do
something else? That is if there is an opportunity to lane change
(couldChangeLane is True), and TraCI tells it to (wants to change Lane),
should it not follow the command?

>>> ex4: like ex1 but the screenshot doesn't show the agents in question
Agent f.4 is just inserted into the lane with index 1 at the beginning of
the lane, and agent f.5 is one of the vehicles in the middle of the lane
with index 0. The vehicle ids are shown in red on top of the vehicles. I'm
not sure if the screenshots were filtered in some way.

Looking forward to your response.

Sincerely,
Hriday

On Thu, 19 May 2022 at 11:47, Jakob Erdmann  wrote:

> > Thank you for your response. The exact method calls are the same as
> those provided in the actual code (in the zip file previously):
>
> The previous zip did not contain your traci code but only XML files, so
> please send this again.
>
>
> > The attached files ordered from ex0.png to ex5.png are some example
> screenshots of the issues.
>
> - ex0 : working as intended: invalid targets are supposed to return false
> to 'could/want' calls
> - ex1: looks ok: the vehicle could change lane but just doesn't want to
> (left/right are missing from the state) - couldAndWant requires both
> opportunity *and* intent
> - ex2: needs further investigation (once I can run your code)
> - ex3: looks to me like a mixup of directions: the vehicle wants to do a
> (sublane) change to the left and you're asking whether it could change to
> the right (no). Looks still a bit strange because the 'sublane' flag is
> missing from it's state so I'd still look at this
> - ex4: like ex1 but the screenshot doesn't show the agents in question
> - ex5: needs further investigation (once I can run your code)
>
> ___
> sumo-user mailing list
> sumo-user@eclipse.org
> To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
>
<>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] Mismatch between chosen lane using TraCI and lane change state

2022-05-19 Thread Jakob Erdmann
> Thank you for your response. The exact method calls are the same as those
provided in the actual code (in the zip file previously):

The previous zip did not contain your traci code but only XML files, so
please send this again.


> The attached files ordered from ex0.png to ex5.png are some example
screenshots of the issues.

- ex0 : working as intended: invalid targets are supposed to return false
to 'could/want' calls
- ex1: looks ok: the vehicle could change lane but just doesn't want to
(left/right are missing from the state) - couldAndWant requires both
opportunity *and* intent
- ex2: needs further investigation (once I can run your code)
- ex3: looks to me like a mixup of directions: the vehicle wants to do a
(sublane) change to the left and you're asking whether it could change to
the right (no). Looks still a bit strange because the 'sublane' flag is
missing from it's state so I'd still look at this
- ex4: like ex1 but the screenshot doesn't show the agents in question
- ex5: needs further investigation (once I can run your code)
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] Mismatch between chosen lane using TraCI and lane change state

2022-05-17 Thread Jakob Erdmann
- Please provide screenshots
- Please provide the exact method calls that computed the outputs


*couldChangeLane TraCI: XXXwantsAndCouldChangeLane TraCI: XXX*

Am Sa., 14. Mai 2022 um 20:29 Uhr schrieb Hriday Sanghvi via sumo-user <
sumo-user@eclipse.org>:

>
> Hello,
>
> Please let me know if there is any additional information required? I
> could also make screenshots for the given conditions if needed.
>
> Sincerely,
> Hriday
>
>
> On Thu, 12 May 2022 at 16:43, Hriday Sanghvi  wrote:
>
>> Hello,
>>
>> I am trying to detect when a lane change is "complete" or even an
>> indication of its success reliably. For this, I am currently using
>> wantsAndCouldLaneChange() and passing the lane change state of TraCI since
>> I am explicitly controlling the vehicles using changeLaneRelative().
>>
>> In the attached observations.txt file, you will find the output of every
>> step of a simulation run. Some examples of mismatch between the TraCI
>> command and the output of LaneChangeState (TraCI) in my_observations.txt
>> are:
>>
>> A.
>>  SIM STEP COUNT: 2 
>> AGENT f.0
>> CURRENT LANE: 1
>> ACTION SELECTED: move right
>>
>> *ACTION DIRECTION: -1*
>> LANE CHANGE STATE SUMO: ['stay', 'sublane']
>>
>> *LANE CHANGE STATE TraCI: ['sublane']*
>>
>>
>> *couldChangeLane TraCI: TruewantsAndCouldChangeLane TraCI: False*
>>
>> wantsAndCouldChangeLane TraCI indicates False, which means the lane
>> change isn't possible (or will not complete), but couldChangeLane clearly
>> indicates that is True (And that it in fact CAN lane change as per my TraCI
>> command to move from lane with index 1 in a direction -1, resulting in the
>> lane 0).
>>
>> - If there is a blocking vehicle, shouldn't the cooperative speed
>> adjustments take care of the blocking vehicle? If not, then how do I
>> compute that there is a blocking vehicle from the given information - so
>> then I can proceed to do something about it?
>>
>>
>> B.
>>  SIM STEP COUNT: 2 
>> AGENT f.1
>> CURRENT LANE: 0
>> ACTION SELECTED: stay
>> ACTION DIRECTION: 0
>>
>> *LANE CHANGE STATE TraCI: []*couldChangeLane TraCI: False
>> wantsAndCouldChangeLane TraCI: False
>>
>>  SIM STEP COUNT: 3 
>> AGENT f.1
>> CURRENT LANE: 0
>> ACTION SELECTED: stay
>> ACTION DIRECTION: 0
>>
>> *LANE CHANGE STATE TraCI: ['stay', 'TraCI', 'sublane']*couldChangeLane
>> TraCI: True
>> wantsAndCouldChangeLane TraCI: False
>>
>> A minor issue (but might indicate a larger misunderstanding on my part).
>> Both steps 2 and 3 have agent f.1 selecting the action of staying. The
>> wantsAndCouldChangeLane return value (False) is in line with what I have
>> understood from a previous enquiry. However, why does the lane change state
>> differ in both - one is empty, and the other one says something about
>> sublane even though my lane change mode is 512 (sublane changes are
>> disabled).
>>
>> C.
>>  SIM STEP COUNT: 4 
>> AGENT f.5
>> CURRENT LANE: 0
>>
>>
>>
>> *ACTION SELECTED: move leftACTION DIRECTION: 1LANE CHANGE STATE TraCI: 
>> []*couldChangeLane
>> TraCI: False
>> wantsAndCouldChangeLane TraCI: False
>>
>> Could not really determine the reason for not being able to move to that
>> lane (similar to A)
>> - would the cooperative speed adjustments even be taken into account to
>> determine if a lane change can be completed?
>> - how many seconds does it see into the future to determine if a lane
>> change can be completed?
>>
>> I have attached the minimal reproducing code, that can be run using
>> *python sublanechange.py -nb 1 -bls 250 -blp 750 -bll 0 --fast *(which
>> will spawn a blockage of size 250m on lane with index 0 ending at the 750m
>> mark, and run a simulation of 100 vehicles going through 1000 m length of
>> road with two lanes). The scenario related information is found in
>> scenario_sublane. There is also a helper script "simulate-sublane.sh" which
>> can be run on a different terminal (for GUI) when you omit the "--fast"
>> flag from the python command.
>>
>> Please advise.
>>
>> (Eclipse SUMO sumo Version 7d0fa177e)
>> Thank you.
>>
>> Sincerely,
>> Hriday
>>
> ___
> sumo-user mailing list
> sumo-user@eclipse.org
> To unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/sumo-user
>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user


Re: [sumo-user] Mismatch between chosen lane using TraCI and lane change state

2022-05-14 Thread Hriday Sanghvi via sumo-user
Hello,

Please let me know if there is any additional information required? I could
also make screenshots for the given conditions if needed.

Sincerely,
Hriday


On Thu, 12 May 2022 at 16:43, Hriday Sanghvi  wrote:

> Hello,
>
> I am trying to detect when a lane change is "complete" or even an
> indication of its success reliably. For this, I am currently using
> wantsAndCouldLaneChange() and passing the lane change state of TraCI since
> I am explicitly controlling the vehicles using changeLaneRelative().
>
> In the attached observations.txt file, you will find the output of every
> step of a simulation run. Some examples of mismatch between the TraCI
> command and the output of LaneChangeState (TraCI) in my_observations.txt
> are:
>
> A.
>  SIM STEP COUNT: 2 
> AGENT f.0
> CURRENT LANE: 1
> ACTION SELECTED: move right
>
> *ACTION DIRECTION: -1*
> LANE CHANGE STATE SUMO: ['stay', 'sublane']
>
> *LANE CHANGE STATE TraCI: ['sublane']*
>
>
> *couldChangeLane TraCI: TruewantsAndCouldChangeLane TraCI: False*
>
> wantsAndCouldChangeLane TraCI indicates False, which means the lane change
> isn't possible (or will not complete), but couldChangeLane clearly
> indicates that is True (And that it in fact CAN lane change as per my TraCI
> command to move from lane with index 1 in a direction -1, resulting in the
> lane 0).
>
> - If there is a blocking vehicle, shouldn't the cooperative speed
> adjustments take care of the blocking vehicle? If not, then how do I
> compute that there is a blocking vehicle from the given information - so
> then I can proceed to do something about it?
>
>
> B.
>  SIM STEP COUNT: 2 
> AGENT f.1
> CURRENT LANE: 0
> ACTION SELECTED: stay
> ACTION DIRECTION: 0
>
> *LANE CHANGE STATE TraCI: []*couldChangeLane TraCI: False
> wantsAndCouldChangeLane TraCI: False
>
>  SIM STEP COUNT: 3 
> AGENT f.1
> CURRENT LANE: 0
> ACTION SELECTED: stay
> ACTION DIRECTION: 0
>
> *LANE CHANGE STATE TraCI: ['stay', 'TraCI', 'sublane']*couldChangeLane
> TraCI: True
> wantsAndCouldChangeLane TraCI: False
>
> A minor issue (but might indicate a larger misunderstanding on my part).
> Both steps 2 and 3 have agent f.1 selecting the action of staying. The
> wantsAndCouldChangeLane return value (False) is in line with what I have
> understood from a previous enquiry. However, why does the lane change state
> differ in both - one is empty, and the other one says something about
> sublane even though my lane change mode is 512 (sublane changes are
> disabled).
>
> C.
>  SIM STEP COUNT: 4 
> AGENT f.5
> CURRENT LANE: 0
>
>
>
> *ACTION SELECTED: move leftACTION DIRECTION: 1LANE CHANGE STATE TraCI: 
> []*couldChangeLane
> TraCI: False
> wantsAndCouldChangeLane TraCI: False
>
> Could not really determine the reason for not being able to move to that
> lane (similar to A)
> - would the cooperative speed adjustments even be taken into account to
> determine if a lane change can be completed?
> - how many seconds does it see into the future to determine if a lane
> change can be completed?
>
> I have attached the minimal reproducing code, that can be run using
> *python sublanechange.py -nb 1 -bls 250 -blp 750 -bll 0 --fast *(which
> will spawn a blockage of size 250m on lane with index 0 ending at the 750m
> mark, and run a simulation of 100 vehicles going through 1000 m length of
> road with two lanes). The scenario related information is found in
> scenario_sublane. There is also a helper script "simulate-sublane.sh" which
> can be run on a different terminal (for GUI) when you omit the "--fast"
> flag from the python command.
>
> Please advise.
>
> (Eclipse SUMO sumo Version 7d0fa177e)
> Thank you.
>
> Sincerely,
> Hriday
>
___
sumo-user mailing list
sumo-user@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/sumo-user