Skip to content

Commit fed79f1

Browse files
ATMxsp01ATMxsp01
and
ATMxsp01
authored
Update mddocs for DockerGuides (#11380)
* transfer files in DockerGuides from rst to md * add some dividing lines * adjust the title hierarchy in docker_cpp_xpu_quickstart.md * restore * switch to the correct branch * small change --------- Co-authored-by: ATMxsp01 <[email protected]>
1 parent 1a1a97c commit fed79f1

9 files changed

+134
-148
lines changed

docs/mddocs/DockerGuides/docker_cpp_xpu_quickstart.md

+29-26
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
## Run llama.cpp/Ollama/Open-WebUI on an Intel GPU via Docker
1+
# Run llama.cpp/Ollama/Open-WebUI on an Intel GPU via Docker
22

33
## Quick Start
44

55
### Install Docker
66

77
1. Linux Installation
88

9-
Follow the instructions in this [guide](https://ipex-llm.readthedocs.io/en/latest/doc/LLM/DockerGuides/docker_windows_gpu.html#linux) to install Docker on Linux.
9+
Follow the instructions in this [guide](./docker_windows_gpu.md#linux) to install Docker on Linux.
1010

1111
2. Windows Installation
1212

13-
For Windows installation, refer to this [guide](https://ipex-llm.readthedocs.io/en/latest/doc/LLM/DockerGuides/docker_windows_gpu.html#install-docker-desktop-for-windows).
13+
For Windows installation, refer to this [guide](./docker_windows_gpu.md#install-docker-desktop-for-windows).
1414

1515
#### Setting Docker on windows
1616

@@ -24,18 +24,18 @@ docker pull intelanalytics/ipex-llm-inference-cpp-xpu:latest
2424

2525
### Start Docker Container
2626

27-
```eval_rst
28-
.. tabs::
29-
.. tab:: Linux
27+
Choose one of the following methods to start the container:
3028

31-
To map the `xpu` into the container, you need to specify `--device=/dev/dri` when booting the container. Select the device you are running(device type:(Max, Flex, Arc, iGPU)). And change the `/path/to/models` to mount the models. `bench_model` is used to benchmark quickly. If want to benchmark, make sure it on the `/path/to/models`
29+
<details>
30+
<Summary>For <strong>Linux</strong>:</summary>
3231

33-
.. code-block:: bash
32+
To map the `xpu` into the container, you need to specify `--device=/dev/dri` when booting the container. Select the device you are running(device type:(Max, Flex, Arc, iGPU)). And change the `/path/to/models` to mount the models. `bench_model` is used to benchmark quickly. If want to benchmark, make sure it on the `/path/to/models`
3433

35-
#/bin/bash
36-
export DOCKER_IMAGE=intelanalytics/ipex-llm-inference-cpp-xpu:latest
37-
export CONTAINER_NAME=ipex-llm-inference-cpp-xpu-container
38-
sudo docker run -itd \
34+
```bash
35+
#/bin/bash
36+
export DOCKER_IMAGE=intelanalytics/ipex-llm-inference-cpp-xpu:latest
37+
export CONTAINER_NAME=ipex-llm-inference-cpp-xpu-container
38+
sudo docker run -itd \
3939
--net=host \
4040
--device=/dev/dri \
4141
-v /path/to/models:/models \
@@ -46,17 +46,19 @@ docker pull intelanalytics/ipex-llm-inference-cpp-xpu:latest
4646
-e DEVICE=Arc \
4747
--shm-size="16g" \
4848
$DOCKER_IMAGE
49-
50-
.. tab:: Windows
49+
```
50+
</details>
5151

52-
To map the `xpu` into the container, you need to specify `--device=/dev/dri` when booting the container. And change the `/path/to/models` to mount the models. Then add `--privileged` and map the `/usr/lib/wsl` to the docker.
52+
<details>
53+
<summary>For <strong>Windows</strong>:</summary>
5354

54-
.. code-block:: bash
55+
To map the `xpu` into the container, you need to specify `--device=/dev/dri` when booting the container. And change the `/path/to/models` to mount the models. Then add `--privileged` and map the `/usr/lib/wsl` to the docker.
5556

56-
#/bin/bash
57-
export DOCKER_IMAGE=intelanalytics/ipex-llm-inference-cpp-xpu:latest
58-
export CONTAINER_NAME=ipex-llm-inference-cpp-xpu-container
59-
sudo docker run -itd \
57+
```bash
58+
#/bin/bash
59+
export DOCKER_IMAGE=intelanalytics/ipex-llm-inference-cpp-xpu:latest
60+
export CONTAINER_NAME=ipex-llm-inference-cpp-xpu-container
61+
sudo docker run -itd \
6062
--net=host \
6163
--device=/dev/dri \
6264
--privileged \
@@ -69,9 +71,10 @@ docker pull intelanalytics/ipex-llm-inference-cpp-xpu:latest
6971
-e DEVICE=Arc \
7072
--shm-size="16g" \
7173
$DOCKER_IMAGE
74+
```
75+
</details>
7276

73-
```
74-
77+
---
7578

7679
After the container is booted, you could get into the container through `docker exec`.
7780

@@ -126,7 +129,7 @@ llama_print_timings: eval time = xxx ms / 31 runs ( xxx ms per
126129
llama_print_timings: total time = xxx ms / xxx tokens
127130
```
128131

129-
Please refer to this [documentation](https://ipex-llm.readthedocs.io/en/latest/doc/LLM/Quickstart/llama_cpp_quickstart.html) for more details.
132+
Please refer to this [documentation](../Quickstart/llama_cpp_quickstart.md) for more details.
130133

131134

132135
### Running Ollama serving with IPEX-LLM on Intel GPU
@@ -194,13 +197,13 @@ Sample output:
194197
```
195198

196199

197-
Please refer to this [documentation](https://ipex-llm.readthedocs.io/en/latest/doc/LLM/Quickstart/ollama_quickstart.html#pull-model) for more details.
200+
Please refer to this [documentation](../Quickstart/ollama_quickstart.md#4-pull-model) for more details.
198201

199202

200203
### Running Open WebUI with Intel GPU
201204

202205
Start the ollama and load the model first, then use the open-webui to chat.
203-
If you have difficulty accessing the huggingface repositories, you may use a mirror, e.g. add export HF_ENDPOINT=https://hf-mirror.com before running bash start.sh.
206+
If you have difficulty accessing the huggingface repositories, you may use a mirror, e.g. add `export HF_ENDPOINT=https://hf-mirror.com`before running bash start.sh.
204207
```bash
205208
cd /llm/scripts/
206209
bash start-open-webui.sh
@@ -218,4 +221,4 @@ INFO: Uvicorn running on http://0.0.0.0:8080 (Press CTRL+C to quit)
218221
<img src="https://llm-assets.readthedocs.io/en/latest/_images/open_webui_signup.png" width="100%" />
219222
</a>
220223

221-
For how to log-in or other guide, Please refer to this [documentation](https://ipex-llm.readthedocs.io/en/latest/doc/LLM/Quickstart/open_webui_with_ollama_quickstart.html) for more details.
224+
For how to log-in or other guide, Please refer to this [documentation](../Quickstart/open_webui_with_ollama_quickstart.md) for more details.

docs/mddocs/DockerGuides/docker_pytorch_inference_gpu.md

+31-38
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,12 @@
22

33
We can run PyTorch Inference Benchmark, Chat Service and PyTorch Examples on Intel GPUs within Docker (on Linux or WSL).
44

5-
```eval_rst
6-
.. note::
7-
8-
The current Windows + WSL + Docker solution only supports Arc series dGPU. For Windows users with MTL iGPU, it is recommended to install directly via pip install in Miniforge Prompt. Refer to `this guide <https://ipex-llm.readthedocs.io/en/latest/doc/LLM/Quickstart/install_windows_gpu.html>`_.
9-
10-
```
5+
> [!NOTE]
6+
> The current Windows + WSL + Docker solution only supports Arc series dGPU. For Windows users with MTL iGPU, it is recommended to install directly via pip install in Miniforge Prompt. Refer to [this guide](../Quickstart/install_windows_gpu.md).
117
128
## Install Docker
139

14-
Follow the [Docker installation Guide](./docker_windows_gpu.html#install-docker) to install docker on either Linux or Windows.
10+
Follow the [Docker installation Guide](./docker_windows_gpu.md#install-docker) to install docker on either Linux or Windows.
1511

1612
## Launch Docker
1713

@@ -20,37 +16,37 @@ Prepare ipex-llm-xpu Docker Image:
2016
docker pull intelanalytics/ipex-llm-xpu:latest
2117
```
2218

23-
Start ipex-llm-xpu Docker Container:
24-
25-
```eval_rst
26-
.. tabs::
27-
.. tab:: Linux
19+
Start ipex-llm-xpu Docker Container. Choose one of the following commands to start the container:
2820

29-
.. code-block:: bash
21+
<details>
22+
<summary>For <strong>Linux</strong>:</summary>
3023

31-
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
32-
export CONTAINER_NAME=my_container
33-
export MODEL_PATH=/llm/models[change to your model path]
24+
```bash
25+
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
26+
export CONTAINER_NAME=my_container
27+
export MODEL_PATH=/llm/models[change to your model path]
3428

35-
docker run -itd \
29+
docker run -itd \
3630
--net=host \
3731
--device=/dev/dri \
3832
--memory="32G" \
3933
--name=$CONTAINER_NAME \
4034
--shm-size="16g" \
4135
-v $MODEL_PATH:/llm/models \
4236
$DOCKER_IMAGE
37+
```
38+
</details>
4339

44-
.. tab:: Windows WSL
45-
46-
.. code-block:: bash
40+
<details>
41+
<summary>For <strong>Windows WSL</strong>:</summary>
4742

48-
#/bin/bash
49-
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
50-
export CONTAINER_NAME=my_container
51-
export MODEL_PATH=/llm/models[change to your model path]
43+
```bash
44+
#/bin/bash
45+
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
46+
export CONTAINER_NAME=my_container
47+
export MODEL_PATH=/llm/models[change to your model path]
5248

53-
sudo docker run -itd \
49+
sudo docker run -itd \
5450
--net=host \
5551
--privileged \
5652
--device /dev/dri \
@@ -60,8 +56,10 @@ Start ipex-llm-xpu Docker Container:
6056
-v $MODEL_PATH:/llm/llm-models \
6157
-v /usr/lib/wsl:/usr/lib/wsl \
6258
$DOCKER_IMAGE
63-
```
59+
```
60+
</details>
6461

62+
---
6563

6664
Access the container:
6765
```
@@ -77,18 +75,13 @@ root@arda-arc12:/# sycl-ls
7775
[ext_oneapi_level_zero:gpu:0] Intel(R) Level-Zero, Intel(R) Arc(TM) A770 Graphics 1.3 [1.3.26241]
7876
```
7977

80-
```eval_rst
81-
.. tip::
82-
83-
You can run the Env-Check script to verify your ipex-llm installation and runtime environment.
84-
85-
.. code-block:: bash
86-
87-
cd /ipex-llm/python/llm/scripts
88-
bash env-check.sh
89-
90-
91-
```
78+
> [!TIP]
79+
> You can run the Env-Check script to verify your ipex-llm installation and runtime environment.
80+
>
81+
> ```bash
82+
> cd /ipex-llm/python/llm/scripts
83+
> bash env-check.sh
84+
> ```
9285
9386
## Run Inference Benchmark
9487

docs/mddocs/DockerGuides/docker_run_pytorch_inference_in_vscode.md

+28-28
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,18 @@ An IPEX-LLM container is a pre-configured environment that includes all necessar
44

55
This guide provides steps to run/develop PyTorch examples in VSCode with Docker on Intel GPUs.
66

7-
```eval_rst
8-
.. note::
97

10-
This guide assumes you have already installed VSCode in your environment.
11-
12-
To run/develop on Windows, install VSCode and then follow the steps below.
13-
14-
To run/develop on Linux, you might open VSCode first and SSH to a remote Linux machine, then proceed with the following steps.
15-
16-
```
8+
> [!note]
9+
> This guide assumes you have already installed VSCode in your environment.
10+
>
11+
> To run/develop on Windows, install VSCode and then follow the steps below.
12+
>
13+
> To run/develop on Linux, you might open VSCode first and SSH to a remote Linux machine, then proceed with the following steps.
1714
1815

1916
## Install Docker
2017

21-
Follow the [Docker installation Guide](./docker_windows_gpu.html#install-docker) to install docker on either Linux or Windows.
18+
Follow the [Docker installation Guide](./docker_windows_gpu.md#install-docker) to install docker on either Linux or Windows.
2219

2320
## Install Extensions for VSCcode
2421

@@ -52,37 +49,38 @@ Open the Terminal in VSCode (you can use the shortcut `` Ctrl+Shift+` ``), then
5249
docker pull intelanalytics/ipex-llm-xpu:latest
5350
```
5451

55-
Start ipex-llm-xpu Docker Container:
52+
Start ipex-llm-xpu Docker Container. Choose one of the following commands to start the container:
5653

57-
```eval_rst
58-
.. tabs::
59-
.. tab:: Linux
54+
<details>
55+
<summary>For <strong>Linux</strong>:</summary>
6056

61-
.. code-block:: bash
57+
```bash
6258

63-
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
64-
export CONTAINER_NAME=my_container
65-
export MODEL_PATH=/llm/models[change to your model path]
59+
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
60+
export CONTAINER_NAME=my_container
61+
export MODEL_PATH=/llm/models[change to your model path]
6662

67-
docker run -itd \
63+
docker run -itd \
6864
--net=host \
6965
--device=/dev/dri \
7066
--memory="32G" \
7167
--name=$CONTAINER_NAME \
7268
--shm-size="16g" \
7369
-v $MODEL_PATH:/llm/models \
7470
$DOCKER_IMAGE
71+
```
72+
</details>
7573

76-
.. tab:: Windows WSL
77-
78-
.. code-block:: bash
74+
<details>
75+
<summary>For <strong>Windows WSL</strong>:</summary>
7976

80-
#/bin/bash
81-
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
82-
export CONTAINER_NAME=my_container
83-
export MODEL_PATH=/llm/models[change to your model path]
77+
```bash
78+
#/bin/bash
79+
export DOCKER_IMAGE=intelanalytics/ipex-llm-xpu:latest
80+
export CONTAINER_NAME=my_container
81+
export MODEL_PATH=/llm/models[change to your model path]
8482

85-
sudo docker run -itd \
83+
sudo docker run -itd \
8684
--net=host \
8785
--privileged \
8886
--device /dev/dri \
@@ -92,8 +90,10 @@ Start ipex-llm-xpu Docker Container:
9290
-v $MODEL_PATH:/llm/llm-models \
9391
-v /usr/lib/wsl:/usr/lib/wsl \
9492
$DOCKER_IMAGE
95-
```
93+
```
94+
</details>
9695

96+
---
9797

9898
## Run/Develop Pytorch Examples
9999

0 commit comments

Comments
 (0)