Git Product home page Git Product logo

Comments (7)

AntonRaichuk avatar AntonRaichuk commented on September 22, 2024 2

Thanks for reporting the issue. We've noticed it shortly after the previous code push and already have a fix for it.
It should be released to github later today/tomorrow.

from football.

hyren avatar hyren commented on September 22, 2024 1

I have just cloned the latest repo and built from scratch, but I am still getting this error msg.

Traceback (most recent call last):
  File "football.py", line 17, in <module>
    e.reset()
  File "/home/hongyu/anaconda3/envs/pearl/lib/python3.5/site-packages/gym/core.py", line 327, in reset
    return self.env.reset()
  File "/home/hongyu/anaconda3/envs/pearl/lib/python3.5/site-packages/gym/core.py", line 317, in reset
    observation = self.env.reset(**kwargs)
  File "/home/hongyu/anaconda3/envs/pearl/lib/python3.5/site-packages/gym/core.py", line 318, in reset
    return self.observation(observation)
  File "/home/hongyu/anaconda3/envs/pearl/lib/python3.5/site-packages/gfootball/env/wrappers.py", line 135, in observation
    frame = obs['frame']
TypeError: list indices must be integers or slices, not str

My code is listed below:

import gfootball.env as football_env
import os
os.environ["MESA_GL_VERSION_OVERRIDE"]='3.2'   
os.environ["MESA_GLSL_VERSION_OVERRIDE"]='150'

e = football_env.create_environment(
	env_name='academy_empty_goal_close', 
	representation='pixels', 
	# rewards='scoring,checkpoints',
	render=True
)

for i in range(10000):
	e.reset()
	done = False
	while not done:
		_, _, done, _ = e.step(e.action_space.sample())
		# e.render()

I feel the error is caused by the incompatibility between different representations and render functions.

from football.

jorgeg96 avatar jorgeg96 commented on September 22, 2024

Thanks! I'll wait for the fix.

from football.

qstanczyk avatar qstanczyk commented on September 22, 2024

Fix was just pushed in v1.2 release.

from football.

jorgeg96 avatar jorgeg96 commented on September 22, 2024

Same as hyren. Still getting that error.

from football.

AntonRaichuk avatar AntonRaichuk commented on September 22, 2024

Originally reported bug happened for simple115 representation which was fixed with the push.
The bug reported by hyren is for pixels. We have a fix and hopefully will release it today.

from football.

qstanczyk avatar qstanczyk commented on September 22, 2024

v1.3 release (just pushed) has a fix to this problem.

from football.

Related Issues (20)

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.