Code Monkey home page Code Monkey logo

Comments (4)

pei-li-u-m avatar pei-li-u-m commented on May 28, 2024

Hi,

  1. The first issue is related to the speed limit of a lane and the speed of a vehicle. SUMO gives these warnings(errors) because the speed of a vehicle exceeds the speed limit of the lane it is assigned to. Setting random speed could be a quick fix. You can also try to increase the speed limit of lanes in the network.

  2. I was not able to reproduce this error. Could you share more information about it? Did it happen in the beginning of the experiment or after several iterations? Also, some code snippets or screenshots could be helpful.

Thanks.

from naturalistic-sumo-gym.

ShenZC25 avatar ShenZC25 commented on May 28, 2024

Hi,

  1. The first issue is related to the speed limit of a lane and the speed of a vehicle. SUMO gives these warnings(errors) because the speed of a vehicle exceeds the speed limit of the lane it is assigned to. Setting random speed could be a quick fix. You can also try to increase the speed limit of lanes in the network.
  2. I was not able to reproduce this error. Could you share more information about it? Did it happen in the beginning of the experiment or after several iterations? Also, some code snippets or screenshots could be helpful.

Thanks.

Hi,
Thank you for your patient answer.Regarding the second question, I'd like to provide the following screenshots.
image
image

As you can see, I gave an ID, but it seems that the program is running to

Curr _ pos = traci.vehicle.getposition (self.egoid) (probably on line 143)

Previously, only a few cars were loaded into the map, so the ID of the car could not be captured, resulting in LaneID being'', entering the if loop, returning the value of None, obs being NoneType, and an error occurred.

Could you please offer some suggestions? Thank you for your answer.

from naturalistic-sumo-gym.

pei-li-u-m avatar pei-li-u-m commented on May 28, 2024

Hi,

Thanks for providing the information. I believe this is an out-of-network issue that happened to the ego vehicle. We have a checkpoint from Lines 450-482 in sumo_gym.py:

# sim check before traci update
if in_road == False or lane_id == "":
    info["debug"] = "Ego-vehicle is out of network"
    sim_check = True
elif self.egoID in traci.simulation.getCollidingVehiclesIDList():
    info["debug"] = "A crash happened to the Ego-vehicle"
    sim_check = True
else:
   .......

This captures the out-of-network issue and shuts down the program. So it takes care of the None observation issue as well.

I noticed that this error happened in the reset stage in your example? Did it happen at the beginning of the simulation then? Also, did you make any changes to the original code?

Thanks.

from naturalistic-sumo-gym.

arpan-kusari avatar arpan-kusari commented on May 28, 2024

Hi Shen, it seems for some reason, your code is starting with the ego-vehicle being out of network, which suggests some problem with either the road network or the ego vehicle initialization. You can check the net and route files but I dont think its a problem with the code. I am closing this issue but if you still keep on having problems, you can reopen it again.

from naturalistic-sumo-gym.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.