mirror of
https://github.com/LostRuins/koboldcpp.git
synced 2025-09-10 17:14:36 +00:00
increased padding, it is still way too little but whatever
This commit is contained in:
parent
729eb1e552
commit
eaa702852d
1 changed files with 2 additions and 2 deletions
|
@ -611,8 +611,8 @@ def autoset_gpu_layers(filepath,ctxsize,gpumem): #shitty algo to determine how m
|
|||
headcount = ggufmeta[1]
|
||||
headkvlen = (ggufmeta[2] if ggufmeta[2] > 0 else 128)
|
||||
ratio = mem/(fsize*csmul*1.5)
|
||||
computemem = layers*4*headkvlen*cs*4*1.4 # For now the first 4 is the hardcoded result for a blasbatchsize of 512. Ideally we automatically calculate blasbatchsize / 4 but I couldn't easily grab the value yet - Henk
|
||||
contextmem = layers*headcount*headkvlen*cs*4
|
||||
computemem = layers*4*headkvlen*cs*4*1.5 # For now the first 4 is the hardcoded result for a blasbatchsize of 512. Ideally we automatically calculate blasbatchsize / 4 but I couldn't easily grab the value yet - Henk
|
||||
contextmem = layers*headcount*headkvlen*cs*4*1.1
|
||||
reservedmem = 1.5*1024*1024*1024 # Users often don't have their GPU's VRAM worth of memory, we assume 500MB to avoid driver swapping + 500MB for the OS + 500MB for background apps / browser - Henk
|
||||
if headcount > 0:
|
||||
ratio = max(ratio, (mem - reservedmem - computemem) / (fsize + contextmem))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue