LLM: check user env (#10580)
* LLM: check user env * small fix * small fix * small fix
This commit is contained in:
parent
c4b533f0e1
commit
9a83f21b86
2 changed files with 94 additions and 40 deletions
|
|
@ -13,7 +13,7 @@ The **Env-Check** scripts ([env-check.sh](./env-chec.sh), [env-check.bat](./env
|
||||||
```
|
```
|
||||||
sudo apt install xpu-smi
|
sudo apt install xpu-smi
|
||||||
```
|
```
|
||||||
* On Windows, you can ignore the sections in `xpu-smi.exe` if you didn't install it. You can always use **Windows Task Manager** to monitor the status of GPUs on Windows.
|
* On Windows, you can ignore the sections in `xpu-smi.exe` if you didn't install it. You can always use **Windows Task Manager** to monitor the status of GPUs on Windows.
|
||||||
|
|
||||||
### Usage
|
### Usage
|
||||||
|
|
||||||
|
|
@ -34,17 +34,17 @@ sudo apt install xpu-smi
|
||||||
|
|
||||||
### Sample outputs
|
### Sample outputs
|
||||||
|
|
||||||
* An example output on a Linux Desktop equipped with i9 13-Gen Intel Core CPU and Intel(R) Arc(TM) A770 GPU looks like below.
|
* An example output on a Linux Desktop equipped with i9 13900K Intel Core CPU and Intel(R) Arc(TM) A770 GPU looks like below.
|
||||||
|
|
||||||
```
|
```
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
PYTHON_VERSION=3.9.18
|
PYTHON_VERSION=3.9.19
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
transformers=4.37.0
|
transformers=4.31.0
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
torch=2.1.0a0+cxx11.abi
|
torch=2.1.0a0+cxx11.abi
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
IPEX Version: 2.5.0b20240219
|
ipex-llm Version: 2.1.0b20240327
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
ipex=2.1.10+xpu
|
ipex=2.1.10+xpu
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
|
|
@ -57,43 +57,49 @@ CPU(s): 32
|
||||||
On-line CPU(s) list: 0-31
|
On-line CPU(s) list: 0-31
|
||||||
Vendor ID: GenuineIntel
|
Vendor ID: GenuineIntel
|
||||||
Model name: 13th Gen Intel(R) Core(TM) i9-13900K
|
Model name: 13th Gen Intel(R) Core(TM) i9-13900K
|
||||||
|
CPU family: 6
|
||||||
|
Model: 183
|
||||||
|
Thread(s) per core: 2
|
||||||
|
Core(s) per socket: 24
|
||||||
|
Socket(s): 1
|
||||||
|
Stepping: 1
|
||||||
|
CPU max MHz: 5800.0000
|
||||||
|
CPU min MHz: 800.0000
|
||||||
|
BogoMIPS: 5990.40
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
MemTotal: 65585208 kB
|
Total Memory: 62.5479 GB
|
||||||
-----------------------------------------------------------------
|
|
||||||
ulimit:
|
|
||||||
real-time non-blocking time (microseconds, -R) unlimited
|
|
||||||
core file size (blocks, -c) 0
|
|
||||||
data seg size (kbytes, -d) unlimited
|
|
||||||
scheduling priority (-e) 0
|
|
||||||
file size (blocks, -f) unlimited
|
|
||||||
pending signals (-i) 255907
|
|
||||||
max locked memory (kbytes, -l) 8198148
|
|
||||||
max memory size (kbytes, -m) unlimited
|
|
||||||
open files (-n) 1048576
|
|
||||||
pipe size (512 bytes, -p) 8
|
|
||||||
POSIX message queues (bytes, -q) 819200
|
|
||||||
real-time priority (-r) 0
|
|
||||||
stack size (kbytes, -s) 8192
|
|
||||||
cpu time (seconds, -t) unlimited
|
|
||||||
max user processes (-u) 255907
|
|
||||||
virtual memory (kbytes, -v) unlimited
|
|
||||||
file locks (-x) unlimited
|
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
Operating System:
|
Operating System:
|
||||||
Ubuntu 22.04.3 LTS \n \l
|
Ubuntu 22.04.3 LTS \n \l
|
||||||
|
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
Environment Variable:
|
03:00.0 VGA compatible controller: Intel Corporation Device 56a0 (rev 08) (prog-if 00 [VGA controller])
|
||||||
SHELL=/usr/bin/zsh
|
Subsystem: Device 1ef7:1307
|
||||||
LSCOLORS=Gxfxcxdxbxegedabagacad
|
Flags: bus master, fast devsel, latency 0, IRQ 201
|
||||||
TBBROOT=/opt/intel/oneapi/tbb/2021.11/env/..
|
Memory at 84000000 (64-bit, non-prefetchable) [size=16M]
|
||||||
USER_ZDOTDIR=/home/user
|
Memory at 4000000000 (64-bit, prefetchable) [size=16G]
|
||||||
COLORTERM=truecolor
|
Expansion ROM at 85000000 [disabled] [size=2M]
|
||||||
LESS=-R
|
Capabilities: <access denied>
|
||||||
TERM_PROGRAM_VERSION=1.86.2
|
Kernel driver in use: i915
|
||||||
ONEAPI_ROOT=/opt/intel/oneapi
|
Kernel modules: i915
|
||||||
CONDA_EXE=/home/user/anaconda3/bin/conda
|
-----------------------------------------------------------------
|
||||||
_CE_M=
|
Linux arda-arc11 5.19.0-41-generic #42~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Apr 18 17:40:00 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
|
||||||
|
-----------------------------------------------------------------
|
||||||
|
CLI:
|
||||||
|
Version: 1.2.13.20230704
|
||||||
|
Build ID: 00000000
|
||||||
|
|
||||||
|
Service:
|
||||||
|
Version: 1.2.13.20230704
|
||||||
|
Build ID: 00000000
|
||||||
|
Level Zero Version: 1.14.0
|
||||||
|
-----------------------------------------------------------------
|
||||||
|
Driver Version 2023.16.11.0.22_160000
|
||||||
|
Driver Version 2023.16.11.0.22_160000
|
||||||
|
Driver UUID 32332e31-372e-3236-3234-312e33330000
|
||||||
|
Driver Version 23.17.26241.33
|
||||||
|
-----------------------------------------------------------------
|
||||||
|
igpu not detected
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
xpu-smi is properly installed.
|
xpu-smi is properly installed.
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
|
|
|
||||||
|
|
@ -63,13 +63,20 @@ check_cpu_info()
|
||||||
echo "-----------------------------------------------------------------"
|
echo "-----------------------------------------------------------------"
|
||||||
echo "CPU Information: "
|
echo "CPU Information: "
|
||||||
lscpu | head -n 17
|
lscpu | head -n 17
|
||||||
|
}
|
||||||
|
|
||||||
|
check_memory_type()
|
||||||
|
{
|
||||||
|
echo "-----------------------------------------------------------------"
|
||||||
|
echo "CPU type: "
|
||||||
|
sudo dmidecode -t 17 | grep DDR
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
check_mem_info()
|
check_mem_info()
|
||||||
{
|
{
|
||||||
echo "-----------------------------------------------------------------"
|
echo "-----------------------------------------------------------------"
|
||||||
cat /proc/meminfo | grep MemTotal
|
cat /proc/meminfo | grep "MemTotal" | awk '{print "Total Memory: " $2/1024/1024 " GB"}'
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -125,6 +132,41 @@ check_ipex()
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
check_xpu_info()
|
||||||
|
{
|
||||||
|
echo "-----------------------------------------------------------------"
|
||||||
|
lspci -v | grep -i vga -A 8
|
||||||
|
}
|
||||||
|
|
||||||
|
check_linux_kernel_version()
|
||||||
|
{
|
||||||
|
echo "-----------------------------------------------------------------"
|
||||||
|
uname -a
|
||||||
|
}
|
||||||
|
|
||||||
|
check_xpu_driver()
|
||||||
|
{
|
||||||
|
echo "-----------------------------------------------------------------"
|
||||||
|
xpu-smi -v
|
||||||
|
}
|
||||||
|
|
||||||
|
check_OpenCL_driver()
|
||||||
|
{
|
||||||
|
echo "-----------------------------------------------------------------"
|
||||||
|
clinfo | fgrep Driver
|
||||||
|
}
|
||||||
|
|
||||||
|
check_igpu()
|
||||||
|
{
|
||||||
|
echo "-----------------------------------------------------------------"
|
||||||
|
if sycl-ls | grep -q "Intel(R) UHD Graphics\|Intel(R) Arc(TM) Graphics"; then
|
||||||
|
echo "igpu detected"
|
||||||
|
sycl-ls | grep -E "Intel\(R\) UHD Graphics|Intel\(R\) Arc\(TM\) Graphics"
|
||||||
|
else
|
||||||
|
echo "igpu not detected"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
main()
|
main()
|
||||||
{
|
{
|
||||||
# first guarantee correct python is installed.
|
# first guarantee correct python is installed.
|
||||||
|
|
@ -144,9 +186,15 @@ main()
|
||||||
# verify hardware (how many gpu availables, gpu status, cpu info, memory info, etc.)
|
# verify hardware (how many gpu availables, gpu status, cpu info, memory info, etc.)
|
||||||
check_cpu_info
|
check_cpu_info
|
||||||
check_mem_info
|
check_mem_info
|
||||||
check_ulimit
|
# check_memory_type
|
||||||
|
# check_ulimit
|
||||||
check_os
|
check_os
|
||||||
check_env
|
# check_env
|
||||||
|
check_xpu_info
|
||||||
|
check_linux_kernel_version
|
||||||
|
check_xpu_driver
|
||||||
|
check_OpenCL_driver
|
||||||
|
check_igpu
|
||||||
|
|
||||||
# check if xpu-smi and GPU is available.
|
# check if xpu-smi and GPU is available.
|
||||||
check_xpu_smi_install
|
check_xpu_smi_install
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue