Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
c4014e73
"src/diffusers/pipelines/shap_e/renderer.py" did not exist on "746215670a61af1034c470d0b6555be9c60cb7b6"
Commit
c4014e73
authored
May 10, 2024
by
Daniel Hiltgen
Browse files
Fall back to CPU runner with zero layers
parent
86f9b582
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
llm/server.go
llm/server.go
+4
-0
No files found.
llm/server.go
View file @
c4014e73
...
...
@@ -105,6 +105,10 @@ func NewLlamaServer(gpus gpu.GpuInfoList, model string, ggml *GGML, adapters, pr
// disable partial offloading when model is greater than total system memory as this
// can lead to locking up the system
opts
.
NumGPU
=
0
}
else
if
gpus
[
0
]
.
Library
!=
"metal"
&&
layers
==
0
{
// Don't bother loading into the GPU if no layers can fit
cpuRunner
=
serverForCpu
()
gpuCount
=
0
}
else
if
opts
.
NumGPU
<
0
&&
layers
>
0
&&
gpus
[
0
]
.
Library
!=
"cpu"
{
opts
.
NumGPU
=
layers
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment