logo
docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
linux/amd64 docker.io 已验证 · Pytorch

PyTorch是一个深度学习框架,旨在简化机器学习算法的实现和部署。该镜像提供了一个基于Python 3.x的环境,可以用于快速启动和测试PyTorch项目。

1123
浏览次数
7.70GB
镜像大小
国内镜像
swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
源镜像
docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
镜像ID
sha256:2d1dee23cc95bf01aad2a292c10f051b01ddc6e7fa7535620cc8a7457720794c
镜像 TAG
2.3.1-cuda12.1-cudnn8-runtime
镜像大小
7.70GB
平台架构
linux/amd64
镜像源
docker.io
CMD
/bin/bash
启动入口
工作目录
/workspace
OS/平台
linux/amd64
镜像创建
2024-06-05T19:27:53.567473886Z
同步时间
2025-07-24 01:22
浏览量
1123 次
贡献者
⚙️ 环境变量 5
KeyValue
PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:/opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin 0
NVIDIA_VISIBLE_DEVICES=all 1
NVIDIA_DRIVER_CAPABILITIES=compute,utility 2
LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64 3
PYTORCH_VERSION=2.3.1 4
🏷️ 镜像标签 3
KeyValue
nvidia_driver com.nvidia.volumes.needed
ubuntu org.opencontainers.image.ref.name
22.04 org.opencontainers.image.version

Docker拉取命令

docker pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
docker tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime  docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime

Containerd拉取命令

ctr images pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
ctr images tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime  docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime

Shell快速替换命令

sed -i 's#pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime#swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime#' deployment.yaml

Ansible快速分发-Docker

#ansible k8s -m shell -a 'docker pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime && docker tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime  docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime'

Ansible快速分发-Containerd

#ansible k8s -m shell -a 'ctr images pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime && ctr images tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime  docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime'

镜像构建历史


# 2024-06-06 03:27:53  0.00B 设置工作目录为/workspace
WORKDIR /workspace
                        
# 2024-06-06 03:27:53  0.00B 设置环境变量 PYTORCH_VERSION
ENV PYTORCH_VERSION=2.3.1
                        
# 2024-06-06 03:27:53  0.00B 设置环境变量 PATH
ENV PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:/opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
                        
# 2024-06-06 03:27:53  0.00B 设置环境变量 LD_LIBRARY_PATH
ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64
                        
# 2024-06-06 03:27:53  0.00B 设置环境变量 NVIDIA_DRIVER_CAPABILITIES
ENV NVIDIA_DRIVER_CAPABILITIES=compute,utility
                        
# 2024-06-06 03:27:53  0.00B 设置环境变量 NVIDIA_VISIBLE_DEVICES
ENV NVIDIA_VISIBLE_DEVICES=all
                        
# 2024-06-06 03:27:53  0.00B 设置环境变量 PATH
ENV PATH=/opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
                        
# 2024-06-06 03:27:53  0.00B 执行命令并创建新的镜像层
RUN |4 PYTORCH_VERSION=2.3.1 TRITON_VERSION= TARGETPLATFORM=linux/amd64 CUDA_VERSION=12.1.1 /bin/sh -c if test -n "${TRITON_VERSION}" -a "${TARGETPLATFORM}" != "linux/arm64"; then         DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends gcc;         rm -rf /var/lib/apt/lists/*;     fi # buildkit
                        
# 2024-06-06 03:27:52  7.59GB 复制新文件或目录到容器中
COPY /opt/conda /opt/conda # buildkit
                        
# 2024-06-06 03:19:46  25.97MB 执行命令并创建新的镜像层
RUN |4 PYTORCH_VERSION=2.3.1 TRITON_VERSION= TARGETPLATFORM=linux/amd64 CUDA_VERSION=12.1.1 /bin/sh -c apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends         ca-certificates         libjpeg-dev         libpng-dev         && rm -rf /var/lib/apt/lists/* # buildkit
                        
# 2024-06-06 03:19:46  0.00B 添加元数据标签
LABEL com.nvidia.volumes.needed=nvidia_driver
                        
# 2024-06-06 03:19:46  0.00B 定义构建参数
ARG CUDA_VERSION
                        
# 2024-06-06 03:19:46  0.00B 定义构建参数
ARG TARGETPLATFORM
                        
# 2024-06-06 03:19:46  0.00B 定义构建参数
ARG TRITON_VERSION
                        
# 2024-06-06 03:19:46  0.00B 定义构建参数
ARG PYTORCH_VERSION
                        
# 2024-06-03 18:32:26  0.00B 
/bin/sh -c #(nop)  CMD ["/bin/bash"]
                        
# 2024-06-03 18:32:25  77.86MB 
/bin/sh -c #(nop) ADD file:89847d76d242dea90ede05e9e1e13a1ff4400a65eafbe2d6e31e086c93893580 in / 
                        
# 2024-06-03 18:32:23  0.00B 
/bin/sh -c #(nop)  LABEL org.opencontainers.image.version=22.04
                        
# 2024-06-03 18:32:23  0.00B 
/bin/sh -c #(nop)  LABEL org.opencontainers.image.ref.name=ubuntu
                        
# 2024-06-03 18:32:23  0.00B 
/bin/sh -c #(nop)  ARG LAUNCHPAD_BUILD_ARCH
                        
# 2024-06-03 18:32:23  0.00B 
/bin/sh -c #(nop)  ARG RELEASE
                        
                    

镜像信息

{
    "Id": "sha256:2d1dee23cc95bf01aad2a292c10f051b01ddc6e7fa7535620cc8a7457720794c",
    "RepoTags": [
        "pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime",
        "swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime"
    ],
    "RepoDigests": [
        "pytorch/pytorch@sha256:fc47f8018254e6df30f48c48f2db1c758d44de21a8c553de1a1c451a65baa70a",
        "swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/pytorch/pytorch@sha256:fc47f8018254e6df30f48c48f2db1c758d44de21a8c553de1a1c451a65baa70a"
    ],
    "Parent": "",
    "Comment": "buildkit.dockerfile.v0",
    "Created": "2024-06-05T19:27:53.567473886Z",
    "Container": "",
    "ContainerConfig": null,
    "DockerVersion": "",
    "Author": "",
    "Config": {
        "Hostname": "",
        "Domainname": "",
        "User": "",
        "AttachStdin": false,
        "AttachStdout": false,
        "AttachStderr": false,
        "Tty": false,
        "OpenStdin": false,
        "StdinOnce": false,
        "Env": [
            "PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:/opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
            "NVIDIA_VISIBLE_DEVICES=all",
            "NVIDIA_DRIVER_CAPABILITIES=compute,utility",
            "LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64",
            "PYTORCH_VERSION=2.3.1"
        ],
        "Cmd": [
            "/bin/bash"
        ],
        "Image": "",
        "Volumes": null,
        "WorkingDir": "/workspace",
        "Entrypoint": null,
        "OnBuild": null,
        "Labels": {
            "com.nvidia.volumes.needed": "nvidia_driver",
            "org.opencontainers.image.ref.name": "ubuntu",
            "org.opencontainers.image.version": "22.04"
        }
    },
    "Architecture": "amd64",
    "Os": "linux",
    "Size": 7695067877,
    "GraphDriver": {
        "Data": {
            "LowerDir": "/var/lib/docker/overlay2/aaff70fac6507cc37ee680e1aca07870f2277769e63a6ee98b06676b0626f7e9/diff:/var/lib/docker/overlay2/5bc395e8a5b7646df07fc296cbe2f9c15a7ef2b4a734a90aa6777c63d2edcb93/diff:/var/lib/docker/overlay2/b53a5a8fa353b75bcf37c4723e9899802a73260789224b62efb2dbc08174ce55/diff:/var/lib/docker/overlay2/c31e1a6f0cf13d560299dad02f579c633faa6080be78d746a887569a0c8f540d/diff",
            "MergedDir": "/var/lib/docker/overlay2/e8625b41497f042282ca520ff3365902c612c129772f00fb07610e25299fdbae/merged",
            "UpperDir": "/var/lib/docker/overlay2/e8625b41497f042282ca520ff3365902c612c129772f00fb07610e25299fdbae/diff",
            "WorkDir": "/var/lib/docker/overlay2/e8625b41497f042282ca520ff3365902c612c129772f00fb07610e25299fdbae/work"
        },
        "Name": "overlay2"
    },
    "RootFS": {
        "Type": "layers",
        "Layers": [
            "sha256:0b9c994b0484c0bc61f9de7c28a58745a504704254c5e8ed12349ebee3393a66",
            "sha256:a63da41ef05f4679b2dddeda59bf80ac55b6b2ff7e6eb80de644ca8cf7c00c77",
            "sha256:e75c063b91c2f42b735547143333f2685bba0433eb7d98b25109754b39d19f05",
            "sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
            "sha256:0f646da89c67c223c2dfb90d8916df51d838157e502bc994c7ce576bf911514e"
        ]
    },
    "Metadata": {
        "LastTagTime": "2025-07-24T01:22:04.532729292+08:00"
    }
}

更多版本

docker.io/pytorch/pytorch:2.3.0-cuda12.1-cudnn8-runtime

linux/amd64 docker.io7.71GB2024-07-18 11:25
10973

docker.io/pytorch/pytorch:2.0.1-cuda11.7-cudnn8-runtime

linux/amd64 docker.io6.48GB2024-07-26 13:31
4623

docker.io/pytorch/pytorch:2.3.0-cuda12.1-cudnn8-devel

linux/amd64 docker.io17.08GB2024-08-06 11:11
2627

docker.io/pytorch/pytorch:2.4.1-cuda12.4-cudnn9-runtime

linux/amd64 docker.io5.99GB2024-09-21 01:42
4995

docker.io/pytorch/pytorch:2.2.1-cuda12.1-cudnn8-runtime

linux/amd64 docker.io7.60GB2024-09-25 04:29
2917

docker.io/pytorch/pytorch:2.4.1-cuda11.8-cudnn9-runtime

linux/amd64 docker.io6.36GB2024-09-28 00:59
2118

docker.io/pytorch/pytorch:2.1.0-cuda11.8-cudnn8-devel

linux/amd64 docker.io17.39GB2024-10-02 00:43
2754

docker.io/pytorch/pytorch:2.4.1-cuda11.8-cudnn9-devel

linux/amd64 docker.io13.63GB2024-10-23 00:32
1957

docker.io/pytorch/pytorch:2.0.1-cuda11.7-cudnn8-devel

linux/amd64 docker.io13.17GB2024-11-01 00:22
1869

docker.io/pytorch/pytorch:2.5.1-cuda12.4-cudnn9-devel

linux/amd64 docker.io13.31GB2024-11-06 01:09
3087

docker.io/pytorch/pytorch:2.5.1-cuda12.4-cudnn9-runtime

linux/amd64 docker.io6.14GB2024-11-06 01:24
5110

docker.io/pytorch/pytorch:2.5.0-cuda12.4-cudnn9-runtime

linux/amd64 docker.io6.13GB2024-11-06 01:38
1715

docker.io/pytorch/pytorch:2.5.0-cuda12.4-cudnn9-devel

linux/amd64 docker.io13.30GB2024-11-06 01:51
1613

docker.io/pytorch/pytorch:2.5.1-cuda12.1-cudnn9-runtime

linux/amd64 docker.io5.90GB2024-11-07 00:14
3544

docker.io/pytorch/pytorch:2.3.1-cuda11.8-cudnn8-runtime

linux/amd64 docker.io8.17GB2024-11-08 00:19
3053

docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-devel

linux/amd64 docker.io17.08GB2024-11-08 00:39
1671

docker.io/pytorch/pytorch:1.13.1-cuda11.6-cudnn8-devel

linux/amd64 docker.io17.52GB2024-11-08 01:12
2258

docker.io/pytorch/pytorch:2.1.2-cuda11.8-cudnn8-devel

linux/amd64 docker.io17.33GB2024-12-10 00:33
1085

docker.io/pytorch/pytorch:2.2.0-cuda12.1-cudnn8-devel

linux/amd64 docker.io16.99GB2024-12-15 00:21
1745

docker.io/pytorch/pytorch:2.1.2-cuda12.1-cudnn8-devel

linux/amd64 docker.io16.58GB2024-12-20 00:05
1690

docker.io/pytorch/pytorch:2.1.2-cuda12.1-cudnn8-runtime

linux/amd64 docker.io7.22GB2025-01-10 00:32
1546

docker.io/pytorch/pytorch:2.0.0-cuda11.7-cudnn8-devel

linux/amd64 docker.io13.10GB2025-01-11 00:22
1680

docker.io/pytorch/pytorch:2.2.2-cuda11.8-cudnn8-devel

linux/amd64 docker.io17.74GB2025-01-18 01:16
1644

docker.io/pytorch/pytorch:2.2.1-cuda11.8-cudnn8-devel

linux/amd64 docker.io17.70GB2025-02-18 00:39
772

docker.io/pytorch/pytorch:2.6.0-cuda12.6-cudnn9-devel

linux/amd64 docker.io13.16GB2025-02-18 01:17
2988

docker.io/pytorch/pytorch:2.6.0-cuda12.4-cudnn9-runtime

linux/amd64 docker.io6.06GB2025-02-27 00:51
3570

docker.io/pytorch/pytorch:2.5.1-cuda12.1-cudnn9-devel

linux/amd64 docker.io12.84GB2025-02-28 02:38
3126

docker.io/pytorch/pytorch:2.6.0-cuda12.4-cudnn9-devel

linux/amd64 docker.io13.23GB2025-03-08 01:36
3049

docker.io/pytorch/pytorch:1.11.0-cuda11.3-cudnn8-devel

linux/amd64 docker.io13.71GB2025-03-18 02:23
1347

docker.io/pytorch/pytorch:2.1.0-cuda12.1-cudnn8-devel

linux/amd64 docker.io16.56GB2025-04-15 01:43
878

docker.io/pytorch/pytorch:2.7.0-cuda12.8-cudnn9-runtime

linux/amd64 docker.io7.70GB2025-04-25 04:37
3402

docker.io/pytorch/pytorch:1.6.0-cuda10.1-cudnn7-devel

linux/amd64 docker.io7.04GB2025-04-28 16:22
1068

docker.io/pytorch/pytorch:2.5.1-cuda11.8-cudnn9-runtime

linux/amd64 docker.io6.32GB2025-05-07 02:16
1401

docker.io/pytorch/pytorch:latest

linux/amd64 docker.io7.60GB2025-05-14 01:17
2062

docker.io/pytorch/pytorch:2.7.0-cuda12.8-cudnn9-devel

linux/amd64 docker.io16.99GB2025-05-22 02:12
1466

docker.io/pytorch/pytorch:2.7.1-cuda12.8-cudnn9-runtime

linux/amd64 docker.io7.60GB2025-07-02 00:58
2825

docker.io/pytorch/pytorch:2.7.1-cuda12.8-cudnn9-devel

linux/amd64 docker.io16.89GB2025-07-18 04:22
1972

docker.io/pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime

linux/amd64 docker.io7.70GB2025-07-24 01:22
1122

docker.io/pytorch/pytorch:2.4.1-cuda12.1-cudnn9-runtime

linux/amd64 docker.io5.93GB2025-07-24 02:12
1256

docker.io/pytorch/pytorch:2.7.1-cuda11.8-cudnn9-runtime

linux/amd64 docker.io6.48GB2025-08-05 01:42
1006

docker.io/pytorch/pytorch:2.8.0-cuda12.9-cudnn9-devel

linux/amd64 docker.io18.46GB2025-08-28 02:21
2278

docker.io/pytorch/pytorch:2.8.0-cuda12.8-cudnn9-devel

linux/amd64 docker.io16.93GB2025-09-11 01:44
1423

docker.io/pytorch/pytorch:2.7.1-cuda11.8-cudnn9-devel

linux/amd64 docker.io13.76GB2025-10-12 02:59
739

docker.io/pytorch/pytorch:2.8.0-cuda12.8-cudnn9-runtime

linux/amd64 docker.io7.69GB2025-10-25 00:53
1748

docker.io/pytorch/pytorch:2.4.1-cuda12.1-cudnn9-devel

linux/amd64 docker.io12.86GB2025-11-01 00:22
822

docker.io/pytorch/pytorch:2.9.0-cuda13.0-cudnn9-runtime

linux/amd64 docker.io5.68GB2025-11-06 02:58
1563

docker.io/pytorch/pytorch:1.13.0-cuda11.6-cudnn8-devel

linux/amd64 docker.io18.57GB2025-11-10 00:45
462

docker.io/pytorch/pytorch:2.4.0-cuda12.1-cudnn9-runtime

linux/amd64 docker.io8.06GB2025-11-22 01:41
802

docker.io/pytorch/pytorch:2.1.0-cuda12.1-cudnn8-runtime

linux/amd64 docker.io7.20GB2025-12-04 00:11
707

docker.io/pytorch/pytorch:2.8.0-cuda12.9-cudnn9-runtime

linux/amd64 docker.io8.38GB2025-12-10 01:22
732

docker.io/pytorch/pytorch:2.9.1-cuda12.8-cudnn9-runtime

linux/amd64 docker.io7.97GB2025-12-12 00:37
1471

docker.io/pytorch/pytorch:2.9.1-cuda12.8-cudnn9-devel

linux/amd64 docker.io17.21GB2025-12-12 01:02
1684

docker.io/pytorch/pytorch:2.7.0-cuda12.6-cudnn9-runtime

linux/amd64 docker.io6.35GB2025-12-13 01:45
855

docker.io/pytorch/pytorch:1.7.1-cuda11.0-cudnn8-devel

linux/amd64 docker.io12.86GB2025-12-16 01:48
723

docker.io/pytorch/pytorch:1.7.0-cuda11.0-cudnn8-devel

linux/amd64 docker.io11.97GB2025-12-16 02:38
452

docker.io/pytorch/pytorch:2.9.1-cuda12.6-cudnn9-runtime

linux/amd64 docker.io7.12GB2026-01-11 00:39
667

docker.io/pytorch/pytorch:1.8.1-cuda11.1-cudnn8-devel

linux/amd64 docker.io16.47GB2026-01-21 01:16
520

docker.io/pytorch/pytorch:2.6.0-cuda11.8-cudnn9-devel

linux/amd64 docker.io13.52GB2026-02-28 02:06
333

docker.io/pytorch/pytorch:2.10.0-cuda12.8-cudnn9-devel

linux/amd64 docker.io17.09GB2026-03-11 02:39
554

docker.io/pytorch/pytorch:2.9.1-cuda13.0-cudnn9-devel

linux/amd64 docker.io12.94GB2026-03-20 02:29
617

docker.io/pytorch/pytorch:2.7.1-cuda12.6-cudnn9-devel

linux/amd64 docker.io13.44GB2026-04-21 02:09
334

docker.io/pytorch/pytorch:2.4.0-cuda12.4-cudnn9-devel

linux/amd64 docker.io14.96GB2026-04-21 02:15
329

docker.io/pytorch/pytorch:2.11.0-cuda12.6-cudnn9-devel

linux/amd64 docker.io21.29GB2026-04-30 03:39
432

docker.io/pytorch/pytorch:2.11.0-cuda12.6-cudnn9-runtime

linux/amd64 docker.io7.06GB2026-04-30 03:55
352

docker.io/pytorch/pytorch:1.12.1-cuda11.3-cudnn8-devel

linux/amd64 docker.io14.06GB2026-06-06 02:30
152

docker.io/pytorch/pytorch:2.11.0-cuda13.0-cudnn9-runtime

linux/amd64 docker.io5.59GB2026-06-11 04:30
218

docker.io/pytorch/pytorch:2.10.0-cuda13.0-cudnn9-devel

linux/amd64 docker.io12.85GB2026-07-04 02:22
110

docker.io/pytorch/pytorch:2.10.0-cuda12.8-cudnn9-runtime

linux/amd64 docker.io7.96GB2026-07-14 03:39
117

docker.io/pytorch/pytorch:2.12.1-cuda13.2-cudnn9-runtime

linux/amd64 docker.io5.60GB2026-07-29 02:11
61

docker.io/pytorch/pytorch:2.13.0-cuda13.0-cudnn9-devel

linux/amd64 docker.io20.68GB2026-08-09 05:22
25
检测到您正在使用广告拦截插件,本站为公益站点,依赖广告维持运转 🙏 查看如何关闭 ×