当前位置:网站首页>【已解决】“The Unity environment took too long to respond. Make sure that :\n“
【已解决】“The Unity environment took too long to respond. Make sure that :\n“
2022-06-23 04:43:00 【Bungehurst】
运行环境
- Anaconda 4.12.0
- Python 3.6.13
- Pytorch 1.10.2
- Ray 1.10.0
- mlagents 0.28.0
- mpi4py 3.0.3
问题描述
在运行多进程并行训练时,Unity会有如下报错,此时程序卡死
"The Unity environment took too long to respond. Make sure that :\n"
mlagents_envs.exception.UnityTimeOutException: The Unity environment took too long to respond. Make sure that :
The environment does not need user interaction to launch
The Agents' Behavior Parameters > Behavior Type is set to "Default" The environment and the Python interface have compatible versions. If you're running on a headless server without graphics support, turn off display by either passing --no-graphics option or build your Unity executable as server build.
怀疑有可能是没有关闭图形造成的.
解决方案
修改unity3d_env.py文件,目录在:anaconda3/envs/<env_name>/lib/python3.6/site-packages/ray/rllib/env/wrappers/unity3d_env.py.
def __init__(self,
file_name: str = None,
port: Optional[int] = None,
seed: int = 0,
no_graphics: bool = True,
timeout_wait: int = 500,
episode_horizon: int = 1000):
- 修改
no_graphics为no_graphics: bool = True,关闭图形输出 - 修改
timeout_wait,适当增加超时等待时间
边栏推荐
- Day_11 传智健康项目-图形报表、POI报表
- Leetcode topic resolution remove nth node from end of list
- Pyinstaller packaging pyttsx3 error
- 去除防火墙和虚拟机对live555启动IP地址的影响
- Tencent security 2021 report white paper collection (download attached)
- Paper notes: multi label learning lsml
- Pyinstaller sklearn报错的问题
- (1) Basic learning - Common shortcut commands of vim editor
- 【Leetcode】431. Encode N-ary Tree to Binary Tree(困难)
- 程序员的真实想法 | 每日趣闻
猜你喜欢

Jour 04 projet de santé mentale - gestion des rendez - vous - gestion des forfaits

Day_11 传智健康项目-图形报表、POI报表
![[cocos2d-x] erasable layer:erasablelayer](/img/6e/1ee750854dfbe6a0260ca12a4a5680.png)
[cocos2d-x] erasable layer:erasablelayer

(1)基础学习——vim编辑器常用快捷操作命令

内存分析与内存泄漏检测

Detailed explanation of redis persistence, master-slave and sentry architecture

Day_12 传智健康项目-JasperReports

ant使用总结(一):使用ant自动打包apk

sklearn sklearn中classification_report&精确度/召回率/F1值

十一、纺织面料下架功能的实现
随机推荐
Redis sentry
Summary of ant usage (I): using ant to automatically package apk
Word pattern for leetcode topic analysis
ant使用总结(二):相关命令说明
JVM原理简介
jvm-02. Guarantee of orderliness
Newbeecoder. Page animation switching of UI control library
Ansible uses ordinary users to manage the controlled end
100-300 cases of single chip microcomputer program (detailed explanation of notes)
Dora's Google SEO tutorial (1) SEO novice guide: establishment of preliminary optimization thinking
ant使用总结(三):批量打包apk
Sorting out common problems after crawler deployment
Detailed explanation of redis persistence, master-slave and sentry architecture
Leetcode topic resolution single number II
[database backup] complete the backup of MySQL database through scheduled tasks
jvm-01. Instruction rearrangement
mysql以逗号分隔的字段作为查询条件怎么查——find_in_set()函数
Multiple strings for leetcode topic resolution
Radar canvas
Perfect squares for leetcode topic analysis