> ## Documentation Index
> Fetch the complete documentation index at: https://wb-21fd5541-codex-link-agent-evals-docs.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> Farama Gymnasium を W&B と統合し、強化学習の Experiments をトラッキングしてエピソード動画を記録します。

# Farama Gymnasium

[Farama Gymnasium](https://gymnasium.farama.org/#) を使用している場合、W\&B は `gymnasium.wrappers.Monitor` によって生成された環境の動画を自動的にログします。動画のログ記録を有効にするには、[`wandb.init()`](/ja/models/ref/python/functions/init) の `monitor_gym` キーワード引数を `True` に設定します。

Gymnasium のインテグレーションは軽量です。W\&B は `gymnasium` からログされた[動画 file 名を読み取り](https://github.com/wandb/wandb/blob/c5fe3d56b155655980611d32ef09df35cd336872/wandb/integration/gym/__init__.py#LL69C67-L69C67)、その名を使用します。一致するものが見つからない場合は、既定で `"videos"` を使用します。より細かく制御したい場合は、手動で[動画をログする](/ja/models/track/log/media/)こともできます。

CleanRL ライブラリで Gymnasium を使用する方法の詳細については、[Mario Bros, but with AI: Gymnasium and CleanRL](https://wandb.ai/raph-test/cleanrltest/reports/Mario-Bros-but-with-AI-Gymnasium-and-CleanRL---Vmlldzo0NTcxNTcw) report を参照してください。

<Frame>
  <img src="https://mintcdn.com/wb-21fd5541-codex-link-agent-evals-docs/dCnBB7xc0m6Fml3G/images/integrations/gymnasium.png?fit=max&auto=format&n=dCnBB7xc0m6Fml3G&q=85&s=37d83db81a20ab2599b217eca4170e57" alt="Gymnasium RL 環境" width="2132" height="1124" data-path="images/integrations/gymnasium.png" />
</Frame>
