Coder Social home page Coder Social logo

sumo-changing-lane-agent's People

Contributors

dependabot[bot] avatar federicovergallo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

sumo-changing-lane-agent's Issues

CarModel

Sorry, I can't understand the functions of the two lambda and add layers in CarModel

'NoneType' and 'str'

I have this problem:
please help me, thank u!

Traceback (most recent call last):
File "test.py", line 10, in
agent.train(env)
File "D:\02Office_software\Sumo\Github\SUMO-changing-lane-agent-master\a2c.py", line 106, in train
next_obs = env.reset(gui=True, numVehicles=25)
File "D:\02Office_software\Sumo\Github\SUMO-changing-lane-agent-master\gym_sumo\envs\sumo_env.py", line 327, in reset
self.start(gui, numVehicles, vType)
File "D:\02Office_software\Sumo\Github\SUMO-changing-lane-agent-master\gym_sumo\envs\sumo_env.py", line 64, in start
sumoBinary = home + "/gitprograms/sumo/bin/sumo-gui"
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'

When I run to around 1500 rounds, I get an error like this

When I run to around 1500 rounds, I get an error like this
55

**`2023-03-24 22:01:09.380560: W tensorflow/core/framework/op_kernel.cc:1763] OP_REQUIRES failed at sparse_xent_op.cc:90 : Invalid argument: Received a label value of 3 which is outside the valid range of [0, 3). Label values: 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
Traceback (most recent call last):
File "/home/vmware/桌面/SUMO-changing-lane-agent-master/test.py", line 10, in
agent.train(env)
File "/home/vmware/桌面/SUMO-changing-lane-agent-master/a2c.py", line 136, in train
losses = self.model.train_on_batch(observations, [acts_and_advs, returns])
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/keras/engine/training.py", line 1727, in train_on_batch
logs = self.train_function(iterator)
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/eager/def_function.py", line 828, in call
result = self._call(*args, **kwds)
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/eager/def_function.py", line 862, in _call
results = self._stateful_fn(*args, **kwds)
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/eager/function.py", line 2943, in call
filtered_flat_args, captured_inputs=graph_function.captured_inputs) # pylint: disable=protected-access
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/eager/function.py", line 1919, in _call_flat
ctx, args, cancellation_manager=cancellation_manager))
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/eager/function.py", line 560, in call
ctx=ctx)
File "/home/vmware/anaconda3/envs/changelane2/lib/python3.7/site-packages/tensorflow/python/eager/execute.py", line 60, in quick_execute
inputs, attrs, num_outputs)
tensorflow.python.framework.errors_impl.InvalidArgumentError: Received a label value of 3 which is outside the valid range of [0, 3). Label values: 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
[[node logits_loss/sparse_categorical_crossentropy/SparseSoftmaxCrossEntropyWithLogits/SparseSoftmaxCrossEntropyWithLogits (defined at /桌面/SUMO-changing-lane-agent-master/a2c.py:199) ]] [Op:__inference_train_function_9631]

Function call stack:
train_function`**

Testing

Hello
Thank you very much
I run your model after building the env
pip install -e gym_sumo
pip install -r requirements.txt

And I have to change in sumo_env.py
image
And I had a minor error
image

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.