"...text-generation-inference.git" did not exist on "c7e570e59de7dc47c35acb1b14d5fe31b123b234"
Commit a3fcecf9 authored by Jeffrey Morgan's avatar Jeffrey Morgan
Browse files

only set `main_gpu` if value > 0 is provided

parent df07e4a0
......@@ -339,11 +339,14 @@ func newLlama(model string, adapters []string, runners []ModelRunner, numLayers
"--model", model,
"--ctx-size", fmt.Sprintf("%d", opts.NumCtx),
"--batch-size", fmt.Sprintf("%d", opts.NumBatch),
"--main-gpu", fmt.Sprintf("%d", opts.MainGPU),
"--n-gpu-layers", fmt.Sprintf("%d", numGPU),
"--embedding",
}
if opts.MainGPU > 0 {
params = append(params, "--main-gpu", fmt.Sprintf("%d", opts.MainGPU))
}
if opts.RopeFrequencyBase > 0 {
params = append(params, "--rope-freq-base", fmt.Sprintf("%f", opts.RopeFrequencyBase))
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment