poet70's picture
Upload folder using huggingface_hub
ac29381 verified
Raw
History Blame Contribute Delete
2.09 kB
# DreamZero 训练 Docker 镜像
#
# 构建:
# docker build -t dreamzero:latest -f docker/Dockerfile .
#
# 运行 (单节点 8 GPU):
# docker run --gpus all --shm-size=64g \
# -v /path/to/checkpoints:/workspace/dreamzero/checkpoints \
# -v /path/to/data:/workspace/dreamzero/data \
# -v /path/to/output:/workspace/dreamzero/output \
# dreamzero:latest \
# data=dreamzero/libero \
# train_architecture=full \
# max_steps=200000 \
# output_dir=./output/libero_full
FROM nvidia/cuda:12.4.1-devel-ubuntu22.04
LABEL description="DreamZero: Video Diffusion Model for Scalable Robot Learning"
LABEL maintainer="DreamZero Team"
# ============ 系统依赖 ============
RUN apt-get update && apt-get install -y --no-install-recommends \
python3.11 \
python3.11-dev \
python3.11-distutils \
python3-pip \
git \
ffmpeg \
libsm6 \
libxext6 \
libglib2.0-0 \
libxrender-dev \
libgl1-mesa-glx \
wget \
curl \
&& rm -rf /var/lib/apt/lists/*
# 设置 python3.11 为默认
RUN update-alternatives --install /usr/bin/python python /usr/bin/python3.11 1
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1
# ============ 安装 PyTorch ============
RUN pip install --no-cache-dir \
torch==2.4.0 \
torchvision==0.19.0 \
--index-url https://download.pytorch.org/whl/cu124
# ============ 复制代码 ============
WORKDIR /workspace/dreamzero
COPY groot/ ./groot/
COPY scripts/ ./scripts/
COPY pyproject.toml requirements.txt ./
# ============ 安装依赖 ============
RUN pip install --no-cache-dir -e ".[train]"
# ============ NCCL 配置(多节点优化) ============
ENV NCCL_DEBUG=WARN
ENV NCCL_IB_DISABLE=0
ENV NCCL_SOCKET_IFNAME=^docker0,lo
ENV NCCL_IB_TIMEOUT=22
ENV NCCL_IB_RETRY_CNT=4
# ============ 中国用户镜像 ============
ENV HF_ENDPOINT=https://hf-mirror.com
# ============ 默认入口 ============
ENTRYPOINT ["torchrun", "--standalone", "--nproc_per_node", "8", \
"/workspace/dreamzero/groot/vla/experiment/experiment.py"]
CMD ["--help"]