Skip to content

Commit 6ac8b2b

Browse files
committed
tweak ratios
1 parent 4ae06b4 commit 6ac8b2b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

koboldcpp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -717,7 +717,7 @@ def autoset_gpu_layers(ctxsize,sdquanted,bbs): #shitty algo to determine how man
717717
layers = ggufmeta[0]
718718
headcount = ggufmeta[1]
719719
headkvlen = (ggufmeta[2] if ggufmeta[2] > 0 else 128)
720-
ratio = (mem-usedmem)/(fsize*csmul*1.55)
720+
ratio = (mem-usedmem)/(fsize*csmul*1.6*(1.0 if bbs <= 512 else 1.2))
721721
computemem = layers*(4 if bbs <= 512 else (bbs/128))*headkvlen*cs*4*1.5 # apply blasbatchsize calculations if over 512
722722
contextmem = layers*headcount*headkvlen*cs*4*1.1
723723
if headcount > 0:

0 commit comments

Comments
 (0)