最新版gym-0.26.2中Atari环境下各游戏在不同模式和困难度下的遍历
相关内容参看前文:
最新版gym-0.26.2下Atari环境的安装以及环境版本v0,v4,v5的说明
===========================================
gym中Atari游戏共收录62个游戏,具体见:
https://www.gymlibrary.dev/environments/atari/complete_list/

以SpaceInvaders游戏为例,我们可以通过该游戏在gym上的主页说明获得该游戏的具体设置:
https://www.gymlibrary.dev/environments/atari/space_invaders/

=====================================================
关于游戏mode的设置,见官网文档:
https://www.gymlibrary.dev/environments/atari/#flavors

关于游戏在不同mode下的difficulties见官方文档:
https://github.com/mgbellemare/Arcade-Learning-Environment/blob/master/docs/games.md

=====================================================
根据gym中Atari游戏的官方文档,给出各游戏在不同模式和困难度下的遍历的代码:
flavors={
    "ALE/Adventure-v5":{"modes":[0, 1, 2], "difficulties":list(range(4)), "default_mode":0},
    "ALE/AirRaid-v5":{"modes":[1,2,3,4,5,6,7,8], "difficulties":[0], "default_mode":1},
    "ALE/Alien-v5":{"modes":[0,1,2,3], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Amidar-v5":{"modes":[0], "difficulties":[0,3], "default_mode":0},
    "ALE/Assault-v5":{"modes":[0], "difficulties":[0], "default_mode":0},
    "ALE/Asterix-v5":{"modes":[0], "difficulties":[0], "default_mode":0},
    "ALE/Asteroids-v5":{"modes":list(range(32))+[128,], "difficulties":[0,3], "default_mode":0},
    "ALE/Atlantis-v5":{"modes":[0,1,2,3], "difficulties":[0], "default_mode":0},
    "ALE/BankHeist-v5":{"modes":[0, 4, 8, 12, 16, 20, 24, 28], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/BattleZone-v5":{"modes":[1,2,3], "difficulties":[0], "default_mode":1},
    "ALE/BeamRider-v5":{"modes":[0,], "difficulties":[0,1], "default_mode":0},
    "ALE/Berzerk-v5":{"modes":[1, 2, 3, 4, 5, 6, 7, 8, 9, 16, 17, 18], "difficulties":[0], "default_mode":1},
    "ALE/Bowling-v5":{"modes":[0, 2, 4], "difficulties":[0,1], "default_mode":0},
    "ALE/Boxing-v5":{"modes":[0,], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Breakout-v5":{"modes":[0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44], "difficulties":[0,1], "default_mode":0},
    "ALE/Carnival-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/Centipede-v5":{"modes":[22,86], "difficulties":[0,], "default_mode":22},
    "ALE/ChopperCommand-v5":{"modes":[0,2], "difficulties":[0,1], "default_mode":0},
    "ALE/CrazyClimber-v5":{"modes":[0,1,2,3], "difficulties":[0,1], "default_mode":0},
    "ALE/Defender-v5":{"modes":list(range(1,10))+[16,], "difficulties":[0,1], "default_mode":1},
    "ALE/DemonAttack-v5":{"modes":[1, 3, 5, 7], "difficulties":[0,1], "default_mode":1},
    "ALE/DoubleDunk-v5":{"modes":list(range(16)), "difficulties":[0], "default_mode":0},
    "ALE/ElevatorAction-v5":{"modes":[0], "difficulties":[0,], "default_mode":0},
    "ALE/Enduro-v5":{"modes":[0], "difficulties":[0,], "default_mode":0},
    "ALE/FishingDerby-v5":{"modes":[0], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Freeway-v5":{"modes":list(range(8)), "difficulties":[0,1], "default_mode":0},
    "ALE/Frostbite-v5":{"modes":[0, 2], "difficulties":[0,], "default_mode":0},
    "ALE/Gopher-v5":{"modes":[0, 2], "difficulties":[0,1], "default_mode":0},
    "ALE/Gravitar-v5":{"modes":[0,1,2,3,4], "difficulties":[0,], "default_mode":0},
    "ALE/Hero-v5":{"modes":[0,1,2,3,4], "difficulties":[0,], "default_mode":0},
    "ALE/IceHockey-v5":{"modes":[0,2], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Jamesbond-v5":{"modes":[0,1], "difficulties":[0,], "default_mode":0},
    "ALE/JourneyEscape-v5":{"modes":[0,], "difficulties":[0,1], "default_mode":0},
    "ALE/Kangaroo-v5":{"modes":[0,1], "difficulties":[0,], "default_mode":0},
    "ALE/Krull-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/KungFuMaster-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/MontezumaRevenge-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/MsPacman-v5":{"modes":[0,1,2,3], "difficulties":[0,], "default_mode":0},
    "ALE/NameThisGame-v5":{"modes":[8,24,40], "difficulties":[0,1], "default_mode":8},
    "ALE/Phoenix-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/Pitfall-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/Pong-v5":{"modes":[0,1], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Pooyan-v5":{"modes":[10, 30, 50, 70], "difficulties":[0,], "default_mode":10},
    "ALE/PrivateEye-v5":{"modes":[0,1,2,3,4], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Qbert-v5":{"modes":[0,], "difficulties":[0,1], "default_mode":0},
    "ALE/Riverraid-v5":{"modes":[0,], "difficulties":[0,1], "default_mode":0},
    "ALE/RoadRunner-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/Robotank-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/Seaquest-v5":{"modes":[0,], "difficulties":[0,1], "default_mode":0},
    "ALE/Skiing-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/Solaris-v5":{"modes":[0,], "difficulties":[0,], "default_mode":0},
    "ALE/SpaceInvaders-v5":{"modes":list(range(16)), "difficulties":[0,1], "default_mode":0},
    "ALE/StarGunner-v5":{"modes":[0,1,2,3], "difficulties":[0,], "default_mode":0},
    "ALE/Tennis-v5":{"modes":[0,2], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/TimePilot-v5":{"modes":[0,], "difficulties":[0,1,2], "default_mode":0},
    "ALE/Tutankham-v5":{"modes":[0, 4, 8, 12], "difficulties":[0,], "default_mode":0},
    "ALE/UpNDown-v5":{"modes":[0,], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/Venture-v5":{"modes":[0,], "difficulties":[0,1,2,3], "default_mode":0},
    "ALE/VideoPinball-v5":{"modes":[0,2], "difficulties":[0,1], "default_mode":0},
    "ALE/WizardOfWor-v5":{"modes":[0,], "difficulties":[0,1], "default_mode":0},
    "ALE/YarsRevenge-v5":{"modes":[0, 32, 64, 96], "difficulties":[0,1], "default_mode":0},
    "ALE/Zaxxon-v5":{"modes":[0,8,16,24], "difficulties":[0,], "default_mode":0},
}
import gym
num = 0
for game_name, game_profile in flavors.items():
    for mode in game_profile['modes']:
        for difficulty in game_profile['difficulties']:
            try:
                env = gym.make(game_name, mode=mode, difficulty=difficulty)
                obs = env.reset()
                for i in range(10):
                    action = env.action_space.sample()
                    obs, reward, done, _, _ = env.step(action)
                env.close()
            except Exception as e:
                num += 1
                print(e, game_name, mode, difficulty)
                # print(env)
print("error game number: ", num)
运行结果:

================================================
最新版gym-0.26.2中Atari环境下各游戏在不同模式和困难度下的遍历的更多相关文章
- Mockito 中文文档 ( 2.0.26 beta )
		
Mockito 中文文档 ( 2.0.26 beta ) 由于缺乏校对,难免有谬误之处,如果发现任何语句不通顺.翻译错误,都可以在github中的项目提出issue.谢谢~ Mockito框架官方地址 ...
 - 2021MySQL 8.0.26安装教程,目前最新版(详细全面)
		
MySQL 8 要比 MySQL 5.7 快 2 倍,还带来了大量的改进和更快的性能!所以为什么不用MySQL8呢!下面是MySQL 8.0.26的安装教程. 安装网址: https://dev.my ...
 - linux驱动程序之电源管理之新版linux系统设备架构中关于电源管理方式的变更
		
新版linux系统设备架构中关于电源管理方式的变更 based on linux-2.6.32 一.设备模型各数据结构中电源管理的部分 linux的设备模型通过诸多结构体来联合描述,如struct d ...
 - iKcamp出品|微信小程序|工具安装+目录说明|基于最新版1.0开发者工具初中级教程分享
		
iKcamp官网:http://www.ikcamp.com 访问官网更快阅读全部免费分享课程:<iKcamp出品|全网最新|微信小程序|基于最新版1.0开发者工具之初中级培训教程分享>. ...
 - 微信小程序教学第二章:小程序中级实战教程之预备篇 - 项目结构设计 |基于最新版1.0开发者工具
		
iKcamp官网:http://www.ikcamp.com 访问官网更快阅读全部免费分享课程:<iKcamp出品|全网最新|微信小程序|基于最新版1.0开发者工具之初中级培训教程分享>. ...
 - 【译】.NET Core 3.0 Preview 3中关于ASP.NET Core的更新内容
		
.NET Core 3.0 Preview 3已经推出,它包含了一系列关于ASP.NET Core的新的更新. 下面是该预览版的更新列表: Razor组件改进: 单项目模板 新的Razer扩展 E ...
 - linux-2.6.26内核中ARM中断实现详解(转)
		
转载:http://www.cnblogs.com/leaven/archive/2010/08/06/1794293.html 更多文档参见:http://pan.baidu.com/s/1dDvJ ...
 - eclipse 编译tomcat8.0.26的源码
		
第一次写东西, 如果有不对的地方,请大神指正,我会尽快修正…… 参考:http://www.cnblogs.com/lanxuezaipiao/p/3640923.html 1.从tomcat官网(h ...
 - Linux 安装 MySQL 8.0.26 超详细图文步骤
		
1.MySQL 8.0.26 下载 官方网站下载 MySQL 8.0.26 安装包,下载地址: https://downloads.mysql.com/archives/community/ 需要注意 ...
 - 技术分享 | 简单测试MySQL 8.0.26 vs GreatSQL 8.0.25的MGR稳定性表现
		
欢迎来到 GreatSQL社区分享的MySQL技术文章,如有疑问或想学习的内容,可以在下方评论区留言,看到后会进行解答 GreatSQL社区原创内容未经授权不得随意使用,转载请联系小编并注明来源. M ...
 
随机推荐
- Vue学习:2.V标签综合2
			
接上一篇... V标签综合使用:书架案例 功能: 实现列表的渲染和删除 思路: 使用 v-for 渲染数据列表,并在每个列表项内放置一个绑定了 del方法的"删除"按钮,点击按钮时 ...
 - JVM性能分析与故障排查
			
引言 JVM调优 程序在上线前的测试或运行中有时会出现一些大大小小的JVM问题,比如cpu load过高.请求延迟.tps降低等,甚至出现内存泄漏(每次垃圾收集使用的时间越来越长,垃圾收集频率越来越高 ...
 - CNN --Inception Module
			
Smiling & Weeping ---- 祝你想我 在平静的湖面 不止在失控的雪山之前 说明:Inception Module 1. 卷积核超参数选择困难,自动找到卷积的最佳组合 2. 1 ...
 - 中国电信登录RSA算法+分析图文
			
Tips:当你看到这个提示的时候,说明当前的文章是由原emlog博客系统搬迁至此的,文章发布时间已过于久远,编排和内容不一定完整,还请谅解` 中国电信登录RSA算法+分析图文 日期:2016-9-30 ...
 - shell中各个括号的用法区别
			
在 shell 脚本中,[ ].[[ ]].( ).(( )).{ } 和 {{ }} 都有各自特定的用法和区别.下面是对这些结构的详细解释: 1. [ ] (test 命令) [ ] 是 shell ...
 - mac brew install Error: No available formula with the name “*“的解决办法
			
背景 在mac上使用brew安装软件发生错误 解决办法 执行以下命令即可 rm -rf /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core ...
 - hive第二课:Hive3.1.2分区与排序以及分桶(内置函数)
			
Hive3.1.2分区与排序(内置函数) 1.Hive分区(十分重要!!) 分区的目的:避免全表扫描,加快查询速度! 在大数据中,最常见的一种思想就是分治,我们可以把大的文件切割划分成一个个的小的文件 ...
 - Android在init.rc中自定义开机启动进程(service)
			
Android在init.rc中自定义开机启动进程(service) 原文链接:Android如何配置init.rc中的开机启动进程(service)(有删改) 前言 首先我先来解释一下本文到底讲什么 ...
 - bash shell基础命令
			
bash shell基础命令 很多Linux发行版的默认shell是GNU bash shell. 1. 启动shell GNU bash shell是一个程序,提供了对Linux系统的交互式访问.它 ...
 - 【论文阅读】Learning to drive from a world on rails
			
引用与参考 代码地址:https://github.com/dotchen/WorldOnRails 论文地址:https://arxiv.org/abs/2105.00636 论文部分 已看完 写在 ...