Skip to content

Commit 6567c7a

Browse files
authored
update compilation instructions of 2.0.0 (#1457)
1 parent 642ad12 commit 6567c7a

File tree

3 files changed

+28
-25
lines changed

3 files changed

+28
-25
lines changed

docker/Dockerfile.compile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ RUN curl -fsSL -v -o ~/miniconda.sh -O https://repo.anaconda.com/miniconda/Mini
4040
FROM dev-base AS build
4141
COPY --from=conda /opt/conda /opt/conda
4242
RUN --mount=type=cache,target=/opt/ccache \
43-
curl -fsSL -v -o compile_bundle.sh -O https://github.com/intel/intel-extension-for-pytorch/blob/master/scripts/compile_bundle.sh && \
43+
curl -fsSL -v -o compile_bundle.sh -O https://github.com/intel/intel-extension-for-pytorch/blob/v2.0.0+cpu/scripts/compile_bundle.sh && \
4444
bash compile_bundle.sh && \
4545
python -m pip install --no-cache-dir intel-extension-for-pytorch/dist/*.whl && \
4646
rm -rf intel-extension-for-pytorch llvm-project compile_bundle.sh

docs/tutorials/installation.md

Lines changed: 25 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ Make sure PyTorch is installed so that the extension will work properly. For eac
1717

1818
|PyTorch Version|Extension Version|
1919
|--|--|
20+
|[v2.0.\*](https://github.com/pytorch/pytorch/tree/v2.0.0 "v2.0.0")|[v2.0.\*](https://github.com/intel/intel-extension-for-pytorch/tree/v2.0.0+cpu)|
2021
|[v1.13.\*](https://github.com/pytorch/pytorch/tree/v1.13.0 "v1.13.0")|[v1.13.\*](https://github.com/intel/intel-extension-for-pytorch/tree/v1.13.100+cpu)|
2122
|[v1.12.\*](https://github.com/pytorch/pytorch/tree/v1.12.0 "v1.12.0")|[v1.12.\*](https://github.com/intel/intel-extension-for-pytorch/tree/v1.12.300)|
2223
|[v1.11.\*](https://github.com/pytorch/pytorch/tree/v1.11.0 "v1.11.0")|[v1.11.\*](https://github.com/intel/intel-extension-for-pytorch/tree/v1.11.200)|
@@ -45,19 +46,20 @@ From 1.8.0, compiling PyTorch from source is not required. If you still want to
4546

4647
Prebuilt wheel files availability matrix for Python versions
4748

48-
| Extension Version | Python 3.6 | Python 3.7 | Python 3.8 | Python 3.9 | Python 3.10 |
49-
| :--: | :--: | :--: | :--: | :--: | :--: |
50-
| 1.13.100 | | ✔️ | ✔️ | ✔️ | ✔️ |
51-
| 1.13.0 | | ✔️ | ✔️ | ✔️ | ✔️ |
52-
| 1.12.300 | | ✔️ | ✔️ | ✔️ | ✔️ |
53-
| 1.12.100 | | ✔️ | ✔️ | ✔️ | ✔️ |
54-
| 1.12.0 | | ✔️ | ✔️ | ✔️ | ✔️ |
55-
| 1.11.200 | | ✔️ | ✔️ | ✔️ | ✔️ |
56-
| 1.11.0 | | ✔️ | ✔️ | ✔️ | ✔️ |
57-
| 1.10.100 | ✔️ | ✔️ | ✔️ | ✔️ | |
58-
| 1.10.0 | ✔️ | ✔️ | ✔️ | ✔️ | |
59-
| 1.9.0 | ✔️ | ✔️ | ✔️ | ✔️ | |
60-
| 1.8.0 | | ✔️ | | | |
49+
| Extension Version | Python 3.6 | Python 3.7 | Python 3.8 | Python 3.9 | Python 3.10 | Python 3.11 |
50+
| :--: | :--: | :--: | :--: | :--: | :--: | :--: |
51+
| 2.0.0 | | | ✔️ | ✔️ | ✔️ | ✔️ |
52+
| 1.13.100 | | ✔️ | ✔️ | ✔️ | ✔️ | |
53+
| 1.13.0 | | ✔️ | ✔️ | ✔️ | ✔️ | |
54+
| 1.12.300 | | ✔️ | ✔️ | ✔️ | ✔️ | |
55+
| 1.12.100 | | ✔️ | ✔️ | ✔️ | ✔️ | |
56+
| 1.12.0 | | ✔️ | ✔️ | ✔️ | ✔️ | |
57+
| 1.11.200 | | ✔️ | ✔️ | ✔️ | ✔️ | |
58+
| 1.11.0 | | ✔️ | ✔️ | ✔️ | ✔️ | |
59+
| 1.10.100 | ✔️ | ✔️ | ✔️ | ✔️ | | |
60+
| 1.10.0 | ✔️ | ✔️ | ✔️ | ✔️ | | |
61+
| 1.9.0 | ✔️ | ✔️ | ✔️ | ✔️ | | |
62+
| 1.8.0 | | ✔️ | | | | |
6163

6264
**Note:** Intel® Extension for PyTorch\* has PyTorch version requirement. Check the mapping table above.
6365

@@ -86,7 +88,7 @@ python -m pip install <package_name>==<version_name> -f https://developer.intel.
8688
To ensure a smooth compilation, a script is provided in the Github repo. If you would like to compile the binaries from source, it is highly recommended to utilize this script.
8789

8890
```bash
89-
$ wget https://github.com/intel/intel-extension-for-pytorch/blob/master/scripts/compile_bundle.sh
91+
$ wget https://github.com/intel/intel-extension-for-pytorch/blob/v2.0.0+cpu/scripts/compile_bundle.sh
9092
$ bash compile_bundle.sh
9193
```
9294

@@ -120,20 +122,20 @@ $ tree -L 3 .
120122

121123
### Build Docker container from Dockerfile
122124

123-
Run the following commands to build the `pip` based deployment container:
125+
Run the following commands to build a `pip` based container with the latest stable version prebuilt wheel files:
124126

125127
```console
126-
$ cd docker
127-
$ DOCKER_BUILDKIT=1 docker build -f Dockerfile.pip -t intel-extension-for-pytorch:pip .
128-
$ docker run --rm intel-extension-for-pytorch:pip python -c "import torch; import intel_extension_for_pytorch as ipex; print('torch:', torch.__version__,' ipex:',ipex.__version__)"
128+
$ cd $DOCKERFILE_DIR
129+
$ DOCKER_BUILDKIT=1 docker build -f Dockerfile.prebuilt -t intel-extension-for-pytorch:prebuilt .
130+
$ docker run --rm intel-extension-for-pytorch:prebuilt python -c "import torch; import intel_extension_for_pytorch as ipex; print('torch:', torch.__version__,' ipex:',ipex.__version__)"
129131
```
130132

131-
Run the following commands to build the `conda` based development container:
133+
Run the following commands to build a `conda` based container with Intel® Extension for PyTorch\* compiled from source:
132134

133135
```console
134-
$ cd docker
135-
$ DOCKER_BUILDKIT=1 docker build -f Dockerfile.conda -t intel-extension-for-pytorch:conda .
136-
$ docker run --rm intel-extension-for-pytorch:conda python -c "import torch; import intel_extension_for_pytorch as ipex; print('torch:', torch.__version__,' ipex:',ipex.__version__)"
136+
$ cd $DOCKERFILE_DIR
137+
$ DOCKER_BUILDKIT=1 docker build -f Dockerfile.compile -t intel-extension-for-pytorch:compile .
138+
$ docker run --rm intel-extension-for-pytorch:compile python -c "import torch; import intel_extension_for_pytorch as ipex; print('torch:', torch.__version__,' ipex:',ipex.__version__)"
137139
```
138140

139141
### Get docker container from dockerhub
@@ -150,6 +152,7 @@ docker pull intel/intel-optimized-pytorch:latest
150152

151153
|Version|Pre-cxx11 ABI|cxx11 ABI|
152154
|--|--|--|
155+
| 2.0.0 | [libintel-ext-pt-2.0.0+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-2.0.0%2Bcpu.run) | [libintel-ext-pt-cxx11-abi-2.0.0+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-cxx11-abi-2.0.0%2Bcpu.run) |
153156
| 1.13.100 | [libintel-ext-pt-1.13.100+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-1.13.100%2Bcpu.run) | [libintel-ext-pt-cxx11-abi-1.13.100+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-cxx11-abi-1.13.100%2Bcpu.run) |
154157
| 1.13.0 | [libintel-ext-pt-1.13.0+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-1.13.0%2Bcpu.run) | [libintel-ext-pt-cxx11-abi-1.13.0+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-cxx11-abi-1.13.0%2Bcpu.run) |
155158
| 1.12.300 | [libintel-ext-pt-1.12.300+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-1.12.300%2Bcpu.run) | [libintel-ext-pt-cxx11-abi-1.12.300+cpu.run](http://intel-optimized-pytorch.s3.cn-north-1.amazonaws.com.cn/libipex/cpu/libintel-ext-pt-cxx11-abi-1.12.300%2Bcpu.run) |

scripts/compile_bundle.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ VER_LLVM="llvmorg-13.0.0"
55
VER_PYTORCH=""
66
VER_TORCHVISION=""
77
VER_TORCHAUDIO=""
8-
VER_IPEX="master"
8+
VER_IPEX="v2.0.0+cpu"
99

1010
# Check existance of required Linux commands
1111
which python > /dev/null 2>&1
@@ -44,7 +44,7 @@ git submodule update --init --recursive
4444

4545
# Install dependencies
4646
python -m pip install cmake
47-
python -m pip install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cpu
47+
python -m pip install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cpu
4848
ABI=$(python -c "import torch; print(int(torch._C._GLIBCXX_USE_CXX11_ABI))")
4949

5050
# Compile individual component

0 commit comments

Comments
 (0)