Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- cd /llm/scripts/
- # set the recommended Env
- echo "START.SH: START IPEX LLM INIT"
- source ipex-llm-init --gpu --device $DEVICE
- chmod +x start-ollama.sh
- echo "START.SH: START OLLAMA"
- # init ollama first
- mkdir -p /llm/ollama
- cd /llm/ollama
- init-ollama
- export OLLAMA_NUM_GPU=999
- export ZES_ENABLE_SYSMAN=1
- export SYCL_CACHE_PERSISTENT=1
- # [optional] under most circumstances, the following environment variable may improve performance, but sometimes this may also cause performance degradation
- export SYCL_PI_LEVEL_ZERO_USE_IMMEDIATE_COMMANDLISTS=1
- # [optional] if you want to run on single GPU, use below command to limit GPU may improve performance
- export ONEAPI_DEVICE_SELECTOR=level_zero:0
- # start ollama service
- ./ollama serve
- echo "START.SH: OLLAMA STOPPED"
Advertisement
Add Comment
Please, Sign In to add comment