← 实验室

从第一人称画面做决策

CPU · Python 3.12.13 · 25.91 s · 2026-10-22 09:03:41 UTC+8

本次运行结果

score-300.0
steps2000
epochs2
checkpoints2
previewbasic-learned-policy.gif
Dependency cache ready: /Users/sanbu/Documents/Codex/2026-10-20/revie/work/chapter-lab-runs/studio-zh/workspaces/vizdoom/.cache/online-experiments/hands-on-modern-rl-experiment02-vizdoom-2c7d02f77f08.ready
代码仓库: /Users/sanbu/Documents/Codex/2026-10-20/revie/work/chapter-lab-runs/studio-zh/workspaces/vizdoom
实验运行目录: /Users/sanbu/Documents/Codex/2026-10-20/revie/work/chapter-lab-runs/studio-zh/workspaces/vizdoom/modelscope-space/hands-on-modern-rl-experiment02-vizdoom
可选任务:
  basic                Basic Aim & Shoot · VizdoomBasic-v1
  defend-center        Defend the Center · VizdoomDefendCenter-v1
  health-gathering     Health Gathering · VizdoomHealthGathering-v1
  my-way-home          My Way Home · VizdoomMyWayHome-v1
  deadly-corridor      Deadly Corridor · VizdoomDeadlyCorridor-v1
  deathmatch           CPU Deathmatch · VizdoomDeathmatch-v1

所选任务: Basic Aim & Shoot
算法: DQN
轮次安排:2 轮 × 1,000 步 = 2,000 总步数
每轮都会评估并保存一个可单独选择的模型。
Device: CPU
启动与在线 Studio 相同的训练流程…

objc[28345]: Class SDLApplication is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28890) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d2c8). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDLAppDelegate is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb288e0) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d318). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDLTranslatorResponder is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28958) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d390). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDLMessageBoxPresenter is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28980) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d3b8). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_cocoametalview is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb289d0) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d408). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDLOpenGLContext is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28a20) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d458). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_ShapeData is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28a98) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d4d0). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_CocoaClosure is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28ae8) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d520). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_VideoData is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28b38) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d570). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_WindowData is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28b88) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d5c0). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDLWindow is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28bb0) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d5e8). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class Cocoa_WindowListener is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28bd8) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d610). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDLView is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28c50) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d688). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class METAL_RenderData is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28cc8) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d700). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class METAL_TextureData is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28d18) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d750). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_RumbleMotor is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28d40) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d778). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
objc[28345]: Class SDL_RumbleContext is implemented in both /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/cv2/.dylibs/libSDL2-2.0.0.dylib (0x11bb28d90) and /Users/sanbu/Documents/Codex/2026-10-20/revie/work/studio-venv/lib/python3.12/site-packages/pygame/.dylibs/libSDL2-2.0.0.dylib (0x11d75d7c8). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
Initialized DQN with CnnPolicy on CPU
update · step 1,000
-----------------------------------------
| train/loss          |        0.815591 |
| train/learning_rate |          0.0003 |
| train/n_updates     |             199 |
-----------------------------------------
EVAL step=1,000 mean_reward=-300.00 std=0.00 mean_length=75.0
SAVE epoch=1/2 model=policy.zip replay=basic-learned-policy.gif
update · step 2,000
-----------------------------------------
| train/loss          |        0.573513 |
| train/learning_rate |          0.0003 |
| train/n_updates     |             449 |
-----------------------------------------
EVAL step=2,000 mean_reward=-300.00 std=0.00 mean_length=75.0
SAVE epoch=2/2 model=policy.zip replay=basic-learned-policy.gif
Saved 2 independently selectable epoch policies and learned-policy replays
最终阶段: complete
最终得分: -300.0
已保存 2 个本次运行可选择的轮次模型。
模型索引: /Users/sanbu/Documents/Codex/2026-10-20/revie/work/chapter-lab-runs/studio-zh/workspaces/vizdoom/modelscope-space/hands-on-modern-rl-experiment02-vizdoom/artifacts/notebook-models.json
Experiment output
运行下面的推理单元格,选择轮次模型并查看该策略的回放。
VBox(children=(Dropdown(description='训练轮次模型:', layout=Layout(width='95%'), options=(('轮次 2/2 · 2,000 步 · 得分 -3…
默认选择最新轮次;也可以选择其他已保存模型,然后点击 回放所选策略.
Experiment output
{
  "score": -300.0,
  "steps": 2000,
  "epochs": 2,
  "checkpoints": 2,
  "preview": "basic-learned-policy.gif"
}
metrics.json
{
  "score": -300.0,
  "steps": 2000,
  "epochs": 2,
  "checkpoints": 2,
  "preview": "basic-learned-policy.gif"
}