Skip to content

Commit d952100

Browse files
authored
rework PR 310 for review (#314)
Signed-off-by: Srikanth Ramakrishna <srikanth.ramakrishna@intel.com>
1 parent 7b8b19b commit d952100

File tree

5 files changed

+45
-25
lines changed

5 files changed

+45
-25
lines changed

tensorflow/Dockerfile

+3-4
Original file line numberDiff line numberDiff line change
@@ -254,11 +254,10 @@ RUN no_proxy="" NO_PROXY="" apt-get update && \
254254
apt-get clean && \
255255
rm -rf /var/lib/apt/lists/*
256256

257-
ARG TF_VER="2.15.0"
257+
ARG ITEX_VER="2.15.0.1"
258258

259-
RUN conda install intel-extension-for-tensorflow=${TF_VER}=*xpu* \
260-
-c https://software.repos.intel.com/python/conda \
261-
-c conda-forge
259+
RUN conda install -n idp -y intel-extension-for-tensorflow=${ITEX_VER}=*xpu* \
260+
-c https://software.repos.intel.com/python/conda
262261

263262
ENV LD_LIBRARY_PATH=/opt/conda/envs/idp/lib:$LD_LIBRARY_PATH
264263

tensorflow/README.md

+19-2
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ The images below additionally include [Jupyter Notebook](https://jupyter.org/) s
3737

3838
| Tag(s) | TensorFlow | IPEX | Driver | Dockerfile |
3939
| ------------- | ----------- | ------------- | ------ | --------------- |
40+
| `2.15.0.1-xpu-jupyter` | [v2.15.1] | [v2.15.0.1] | [803.63]| [v0.4.0-Beta] |
4041
| `xpu-jupyter` | [v2.14.1] | [v2.14.0.1] | [736] | [v0.3.4] |
4142

4243
### Run the XPU Jupyter Container
@@ -48,7 +49,7 @@ docker run -it --rm \
4849
--device /dev/dri \
4950
-v /dev/dri/by-path:/dev/dri/by-path \
5051
--ipc=host \
51-
intel/intel-extension-for-tensorflow:xpu-jupyter
52+
intel/intel-extension-for-tensorflow:2.15.0.1-xpu-jupyter
5253
```
5354

5455
After running the command above, copy the URL (something like `http://127.0.0.1:$PORT/?token=***`) into your browser to access the notebook server.
@@ -104,7 +105,7 @@ docker run -it --rm \
104105
--net=host \
105106
-v $PWD/workspace:/workspace \
106107
-w /workspace \
107-
intel/intel-extension-for-tensorflow:xpu-jupyter
108+
intel/intel-extension-for-tensorflow:2.15.0-pip-jupyter
108109
```
109110

110111
After running the command above, copy the URL (something like `http://127.0.0.1:$PORT/?token=***`) into your browser to access the notebook server.
@@ -170,6 +171,22 @@ The images below additionally include [Horovod]:
170171
| `2.14.0-idp-openmpi-multinode` | [v2.14.1] | [v2.14.0.1] | [v0.28.1] | [v0.3.4] |
171172
| `2.13-idp-openmpi-mulitnode` | [v2.13.0] | [v2.13.0.0] | [v0.28.0] | [v0.2.3] |
172173

174+
## XPU images with Intel® Distribution for Python*
175+
176+
The images below are built only with CPU and GPU optimizations and include [Intel® Distribution for Python*]:
177+
178+
| Tag(s) | Pytorch | ITEX | Driver | Dockerfile |
179+
| ---------------- | -------- | ------------ | -------- | ------ |
180+
| `2.15.0.1-xpu-idp-base` | [v2.15.1] | [v2.15.0.1] | [803] | [v0.4.0-Beta] |
181+
| `2.15.0-xpu-idp-base` | [v2.15.0] | [v2.15.0.0] | [803] | [v0.4.0-Beta] |
182+
183+
The images below additionally include [Jupyter Notebook](https://jupyter.org/) server:
184+
185+
| Tag(s) | Pytorch | IPEX | Driver | Jupyter Port | Dockerfile |
186+
| --------------------- | -------- | ------------- | ------ | ------------ | --------------- |
187+
| `2.15.0.1-xpu-idp-jupyter` | [v2.15.1] | [v2.15.0.1] | [803] | `8888` | [v0.4.0-Beta] |
188+
| `2.15.0-xpu-idp-jupyter` | [v2.1.0] | [v2.15.0.0] | [803] | `8888` | [v0.4.0-Beta] |
189+
173190
## Build from Source
174191

175192
To build the images from source, clone the [Intel® AI Containers](https://github.com/intel/ai-containers) repository, follow the main `README.md` file to setup your environment, and run the following command:

tensorflow/docker-compose.yaml

+13-13
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,10 @@ services:
9595
LEVEL_ZERO_GPU_VER: ${LEVEL_ZERO_GPU_VER:-1.3.27642.40-803~22.04}
9696
LEVEL_ZERO_VER: ${LEVEL_ZERO_VER:-1.14.0-744~22.04}
9797
LEVEL_ZERO_DEV_VER: ${LEVEL_ZERO_DEV_VER:-1.14.0-744~22.04}
98-
DPCPP_VER: ${DPCPP_VER:-2024.1.0-963}
99-
MKL_VER: ${MKL_VER:-2024.1.0-691}
100-
CCL_VER: ${CCL_VER:-2021.12.0-309}
101-
TF_VER: ${TF_VER:-2.15.0}
98+
DPCPP_VER: ${DPCPP_VER:-2024.2.1-1079}
99+
MKL_VER: ${MKL_VER:-2024.2.1-103}
100+
CCL_VER: ${CCL_VER:-2021.13.1-31}
101+
TF_VER: ${TF_VER:-2.15.1}
102102
no_proxy: ''
103103
NO_PROXY: ''
104104
labels:
@@ -108,9 +108,9 @@ services:
108108
dependency.apt.gnupg2: true
109109
dependency.apt.gpg-agent: true
110110
dependency.apt.intel-level-zero-gpu: ${LEVEL_ZERO_GPU_VER:-1.3.27642.40-803~22.04}
111-
dependency.apt.intel-oneapi-runtime-ccl: ${CCL_VER:-2021.12.0-309}
112-
dependency.apt.intel-oneapi-runtime-dpcpp-cpp: ${DPCPP_VER:-2024.1.0-963}
113-
dependency.apt.intel-oneapi-runtime-mkl: ${MKL_VER:-2024.1.0-691}
111+
dependency.apt.intel-oneapi-runtime-ccl: ${CCL_VER:-2021.13.1-31}
112+
dependency.apt.intel-oneapi-runtime-dpcpp-cpp: ${DPCPP_VER:-2024.2.1-1079}
113+
dependency.apt.intel-oneapi-runtime-mkl: ${MKL_VER:-2024.2.1-103}
114114
dependency.apt.intel-opencl-icd: ${ICD_VER:-23.43.27642.40-803~22.04}
115115
dependency.apt.level-zero: ${LEVEL_ZERO_VER:-1.14.0-744~22.04}
116116
dependency.apt.level-zero-dev: ${LEVEL_ZERO_DEV_VER:-1.14.0-744~22.04}
@@ -124,18 +124,18 @@ services:
124124
command: >
125125
sh -c "python -c 'import tensorflow as tf;print(tf.__version__);from tensorflow.python.client import device_lib;print(device_lib.list_local_devices())'"
126126
extends: tf-base
127-
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.0}-itex-xpu-base
127+
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.1}-itex-xpu-base
128128
xpu-jupyter:
129129
build:
130130
args:
131131
ICD_VER: ${ICD_VER:-23.43.27642.40-803~22.04}
132132
LEVEL_ZERO_GPU_VER: ${LEVEL_ZERO_GPU_VER:-1.3.27642.40-803~22.04}
133133
LEVEL_ZERO_VER: ${LEVEL_ZERO_VER:-1.14.0-744~22.04}
134134
LEVEL_ZERO_DEV_VER: ${LEVEL_ZERO_DEV_VER:-1.14.0-744~22.04}
135-
DPCPP_VER: ${DPCPP_VER:-2024.1.0-963}
136-
MKL_VER: ${MKL_VER:-2024.1.0-691}
137-
CCL_VER: ${CCL_VER:-2021.12.0-309}
138-
TF_VER: ${TF_VER:-2.15.0}
135+
DPCPP_VER: ${DPCPP_VER:-2024.2.1-1079}
136+
MKL_VER: ${MKL_VER:-2024.2.1-103}
137+
CCL_VER: ${CCL_VER:-2021.13.1-31}
138+
ITEX_VER: ${ITEX_VER:-2.15.0.1}
139139
no_proxy: ''
140140
NO_PROXY: ''
141141
labels:
@@ -147,4 +147,4 @@ services:
147147
extends: tf-base
148148
command: >
149149
bash -c "python -m jupyter --version"
150-
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.0}-itex-xpu-jupyter
150+
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.1}-itex-xpu-jupyter

tensorflow/tests/tests.yaml

+8-4
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,19 @@ import-itex-cpu-${PACKAGE_OPTION:-pip}:
1717
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-${TF_VERSION:-2.15.0}-base
1818
cmd: python -c "from tensorflow.python.client import device_lib; print(device_lib.list_local_devices())"
1919
import-itex-xpu-${PACKAGE_OPTION:-pip}:
20-
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.0}-itex-xpu-base
20+
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.1}-itex-xpu-base
2121
cmd: python /tests/xpu_import_test.py
22+
device: ["/dev/dri"]
2223
volumes:
2324
- src: ${PWD}/tensorflow/tests
2425
dst: /tests
2526
import-cpu-jupyter-${PACKAGE_OPTION:-pip}:
2627
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-${TF_VERSION:-2.15.0}-jupyter
2728
cmd: python -m jupyter --version
2829
import-xpu-jupyter-${PACKAGE_OPTION:-pip}:
29-
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.0}-itex-xpu-jupyter
30+
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.1}-itex-xpu-jupyter
3031
cmd: python -m jupyter --version
32+
device: ["/dev/dri"]
3133
import-multinode-${PACKAGE_OPTION:-pip}:
3234
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-${TF_VERSION:-2.15.0}-horovod-${HOROVOD_VERSION:-0.28.1}-inc-${INC_VERSION:-2.6}
3335
cmd: horovodrun --check-build && mpirun --version && python -c 'import horovod.tensorflow as hvd;hvd.init();import horovod.tensorflow'
@@ -41,15 +43,17 @@ itex-cpu-${PACKAGE_OPTION:-pip}:
4143
- src: ${PWD}/tensorflow/tests
4244
dst: /tests
4345
itex-xpu-${PACKAGE_OPTION:-pip}:
44-
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.0}-itex-xpu-base
46+
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.1}-itex-xpu-base
4547
cmd: python /tests/tf_base_test.py
48+
device: ["/dev/dri"]
4649
volumes:
4750
- dst: /tests
4851
src: $PWD/tensorflow/tests
4952
itex-xpu-jupyter-${PACKAGE_OPTION:-pip}:
50-
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.0}-itex-xpu-jupyter
53+
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-itex-${TF_VERSION:-2.15.1}-itex-xpu-jupyter
5154
cmd: papermill --log-output /jupyter/xpu.ipynb -k python3 -
5255
notebook: True
56+
device: ["/dev/dri"]
5357
multinode-${PACKAGE_OPTION:-pip}:
5458
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-${BASE_IMAGE_NAME:-ubuntu}-${BASE_IMAGE_TAG:-22.04}-${PACKAGE_OPTION:-pip}-py${PYTHON_VERSION:-3.10}-${TF_VERSION:-2.15.0}-horovod-${HOROVOD_VERSION:-0.28.1}-inc-${INC_VERSION:-2.6}
5559
cmd: horovodrun -np 2 -H localhost:2 --binding-args="-bind-to socket -map-by socket" python /tests/tf_base_test.py

tensorflow/xpu-requirements.txt

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
tensorflow==2.15.0
2-
intel-extension-for-tensorflow[xpu]==2.15.0.0
1+
tensorflow==2.15.1
2+
intel-extension-for-tensorflow[xpu]==2.15.0.1

0 commit comments

Comments
 (0)