-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bigmodel pipeline update cp38 to cp310 (#22793)
### Description <!-- Describe your changes. --> when updating from cp38 to cp310, there has some issues for bigmodel pipeine. there are two jobs failed: stable_diffusion and whisper. 1. for stable_diffusion, we are now using "nvcr.io/nvidia/pytorch:22.11-py3" from nvidia repo. it is for cuda11 and python3.8. and they are not providing python3.10 version for cuda 11. the latest version of this docker image is for cuda12 and python3.10. To solve this problem, i use a docker image of ubuntu22.04, and then install all need python package for this job. 2. for whisper. the original docker image is ubuntu20.04 which doesn't have python3.10, and has to update to ubuntu22.04.
- Loading branch information
Showing
6 changed files
with
89 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ git+https://github.com/openai/CLIP.git | |
open_clip_torch | ||
sentence_transformers | ||
pillow | ||
numpy==1.22.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
64 changes: 64 additions & 0 deletions
64
tools/ci_build/github/linux/docker/Dockerfile.package_ubuntu_2204_gpu_opencv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
# -------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. | ||
# -------------------------------------------------------------- | ||
# Dockerfile to run ONNXRuntime with TensorRT integration | ||
|
||
# Build base image with required system packages | ||
ARG BASEIMAGE=nvidia/cuda:11.8.0-cudnn8-devel-ubuntu22.04 | ||
ARG TRT_VERSION=10.6.0.26-1+cuda11.8 | ||
ARG LD_LIBRARY_PATH_ARG=/usr/local/lib64:/usr/local/cuda/lib64 | ||
FROM $BASEIMAGE AS base | ||
ARG TRT_VERSION | ||
ENV PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/src/tensorrt/bin:${PATH} | ||
ENV DEBIAN_FRONTEND=noninteractive | ||
|
||
ENV LD_LIBRARY_PATH=${LD_LIBRARY_PATH_ARG}:${LD_LIBRARY_PATH} | ||
|
||
RUN apt-get update &&\ | ||
apt-get install -y git bash wget diffutils | ||
|
||
RUN DEBIAN_FRONTEND="noninteractive" apt-get install --yes python3-opencv | ||
|
||
# Install python3 | ||
RUN apt-get install -y --no-install-recommends \ | ||
python3 \ | ||
python3-pip \ | ||
python3-dev \ | ||
python3-wheel | ||
|
||
RUN pip install --upgrade pip | ||
|
||
# Install TensorRT | ||
RUN apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/7fa2af80.pub &&\ | ||
apt-get update &&\ | ||
apt-get install -y \ | ||
libnvinfer-dev=${TRT_VERSION} \ | ||
libnvinfer-dispatch-dev=${TRT_VERSION} \ | ||
libnvinfer-dispatch10=${TRT_VERSION} \ | ||
libnvinfer-headers-dev=${TRT_VERSION} \ | ||
libnvinfer-headers-plugin-dev=${TRT_VERSION} \ | ||
libnvinfer-lean-dev=${TRT_VERSION} \ | ||
libnvinfer-lean10=${TRT_VERSION} \ | ||
libnvinfer-plugin-dev=${TRT_VERSION} \ | ||
libnvinfer-plugin10=${TRT_VERSION} \ | ||
libnvinfer-vc-plugin-dev=${TRT_VERSION} \ | ||
libnvinfer-vc-plugin10=${TRT_VERSION} \ | ||
libnvinfer10=${TRT_VERSION} \ | ||
libnvonnxparsers-dev=${TRT_VERSION} \ | ||
libnvonnxparsers10=${TRT_VERSION} \ | ||
tensorrt-dev=${TRT_VERSION} \ | ||
libnvinfer-bin=${TRT_VERSION} &&\ | ||
if [ $(echo $CUDA_VERSION | cut -d"." -f1) -ge 12 ]; then apt-get install -y cudnn9-cuda-12 ; fi | ||
# ^^^^^^^^^^^If cuda version is 12 or higher, install cudnn 9 for cuda 12 | ||
|
||
ADD scripts /tmp/scripts | ||
RUN cd /tmp/scripts && /tmp/scripts/install_dotnet.sh && rm -rf /tmp/scripts | ||
|
||
# Build final image from base. | ||
FROM base as final | ||
ARG BUILD_USER=onnxruntimedev | ||
ARG BUILD_UID=1000 | ||
RUN adduser --uid $BUILD_UID $BUILD_USER | ||
WORKDIR /home/$BUILD_USER | ||
USER $BUILD_USER |