# Windows原生运行LeRobot LIBERO仿真报错及四步绕过方案

> 原文链接：https://robotics.hellobike.com/pitfalls/2026-11-08-lerobot-4857
> 频道：pitfalls | 更新日期：2026-11-08 | 标签：auto, github-issue, lerobot
> 核心摘要：针对Windows下LIBERO安装失败、DLL缺失、EGL强制及日志路径错误，提供跳过依赖与手动配置环境的绕过步骤。

# Windows原生运行LeRobot LIBERO仿真报错及四步绕过方案

::: v-pre
> 本文由 AI 根据公开内容整理，可能有误，请以原文为准：[LIBERO doesn't work on native Windows: 4 small blockers, with a tested fix (happy to send a PR)](https://github.com/huggingface/lerobot/issues/4857)（GitHub huggingface/lerobot #4857）

**状态**：有绕过办法

## 问题

在Windows 11原生环境运行LeRobot LIBERO时遭遇四个阻断：1. `hf-libero`依赖`egl-probe`需CMake编译导致安装失败；2. `robosuite` 1.4.0缺失`mujoco.dll`致import崩溃；3. `MUJOCO_GL`被强制设为`egl`且在Windows无效；4. 日志硬编码写入`/tmp/robosuite.log`致路径不存在报错。

## 环境

LeRobot 0.6.1, Windows 11, Python 3.12.13, PyTorch 2.11.0+cu128, RTX 3060 Laptop GPU, hf-libero 0.1.4, robosuite 1.4.0, mujoco 3.8.1

## 解决办法

1. 使用 `uv pip install --no-deps hf-libero==0.1.4 robomimic==0.2.0` 跳过 `egl-probe` 等Linux专用依赖的自动构建。
2. 手动安装运行时必需组件：`uv pip install robosuite==1.4.0 mujoco==3.8.1 bddl==1.0.1 easydict einops "hydra-core<1.4" h5py glfw future termcolor gymnasium matplotlib cloudpickle opencv-python thop`。
3. 在代码中 `import robosuite` 之前，通过环境变量将 `MUJOCO_GL` 显式设置为 `glfw` 以覆盖默认的 `egl` 后端。
4. 确保当前驱动器根目录存在 `\tmp` 文件夹，或在导入前修改日志路径配置，解决 `/tmp/robosuite.log` 写入失败问题。
5. 验证环境：执行…

讨论原作者：@ahmedsleem109 等，版权归原作者所有。
:::

## 原始参考来源 (Sources)

- [GitHub huggingface/lerobot #4857：LIBERO doesn't work on native Windows: 4 small blockers, with a tested fix (happy to send a PR)](https://github.com/huggingface/lerobot/issues/4857)