ValueError: too many values to unpack (expected 2)
See original GitHub issueI’m trying to run the pretrained AI. I have follow the installation guide and the get started guide however when I try to run it I get this issue. I can see the program resizing my window from quarter of my screen to a 8th. I have tried running the game in the lowest possible resolution with a fps cap on 30 and I’m running on a 2060 super.
Here is the command log, do you have any idea what might cause this?
Running on: Windows 11 Python 3.9.12
(base) C:\Windows\system32>python -m tmrl --test
DEBUG:root: PATH_DATA:C:\Users\jakob\TmrlData
INFO:numexpr.utils:Note: NumExpr detected 16 cores but "NUMEXPR_MAX_THREADS" not set, so enforcing safe limit of 8.
INFO:numexpr.utils:NumExpr defaulting to 8 threads.
INFO:root:Namespace(server=False, trainer=False, worker=False, test=True, benchmark=False, record_reward=False, check_env=False, no_wandb=False, config={})
DEBUG:root:Loading model from C:\Users\jakob\TmrlData\weights\SAC_4_LIDAR_pretrained.pth
DEBUG:urllib3.connectionpool:Starting new HTTP connection (1): api.ipify.org:80
DEBUG:urllib3.connectionpool:http://api.ipify.org:80 "GET / HTTP/1.1" 200 14
INFO:root:09/14/22 11:09:44 local IP: 192.168.1.127
INFO:root:09/14/22 11:09:44 public IP: 213.66.199.113
INFO:root:09/14/22 11:09:44 server IP: 127.0.0.1
DEBUG:root: virtual joystick in use
Traceback (most recent call last):
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,C:\ProgramData\Anaconda3\lib\site-packages\rtgym\envs\real_time_env.py:357: UserWarning: Time-step timed out. Elapsed since last time-step: 1.5917513370513916
warnings.warn(f"Time-step timed out. Elapsed since last time-step: {now - self.__t_end}")
File "C:\ProgramData\Anaconda3\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\ProgramData\Anaconda3\lib\site-packages\tmrl\__main__.py", line 81, in <module>
main(arguments)
File "C:\ProgramData\Anaconda3\lib\site-packages\tmrl\__main__.py", line 42, in main
rw.run_episodes(10000)
File "C:\ProgramData\Anaconda3\lib\site-packages\tmrl\networking.py", line 956, in run_episodes
self.run_episode(max_samples_per_episode, train=train)
File "C:\ProgramData\Anaconda3\lib\site-packages\tmrl\networking.py", line 972, in run_episode
obs = self.reset(collect_samples=False)
File "C:\ProgramData\Anaconda3\lib\site-packages\tmrl\networking.py", line 867, in reset
new_obs = self.env.reset()
File "C:\ProgramData\Anaconda3\lib\site-packages\gym\core.py", line 323, in reset
return self.env.reset(**kwargs)
File "C:\ProgramData\Anaconda3\lib\site-packages\gym\core.py", line 379, in reset
obs, info = self.env.reset(**kwargs)
ValueError: too many values to unpack (expected 2)
(base) C:\Windows\system32>
Issue Analytics
- State:
- Created a year ago
- Comments:6 (5 by maintainers)
Top Results From Across the Web
ValueError: too many values to unpack (expected 2)
This error occurs when the number of variables doesn't match the number of values. As a result of the inequality, Python doesn't know...
Read more >Python valueerror: too many values to unpack (expected 2)
The “valueerror: too many values to unpack (expected 2)” error occurs when you do not unpack all the items in a list. This...
Read more >ValueError: too many values to unpack (expected 2) in Python
The Python "ValueError: too many values to unpack (expected 2) in Python" occurs when the number of variables in the assignment is not...
Read more >ValueError: too many values to unpack (expected 2)
Python ValueError: too many values to unpack, occurs during a multiple-assignment where you either don't have enough objects to assign to the variables...
Read more >ValueError: too many values to unpack (expected 2) - ItsMyCode
ValueError : too many values to unpack (expected 2) occurs when there is a mismatch between the returned values and the number of...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
You’re welcome, FYI,
tmrl
version0.3.0
has been updated to the new gym (>= 0.26) APIIt also introduces support for the raw screenshot environment 😄
@yannbouteiller Thank you so much for the quick reply!
pip install gym==0.25
did the trick! 🎉