From 1146007610af1e8fc8f2e9e4c708cad85d13ff34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20du=20Hamel?= Date: Tue, 24 Sep 2024 23:52:00 +0200 Subject: [PATCH] compress: fix sampling problem introduced by b0f27361f3539a81d983a8b045f3c61e682d9fc0 --- examples/compress/compress.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/compress/compress.cpp b/examples/compress/compress.cpp index e27ab2b24..b800ab645 100644 --- a/examples/compress/compress.cpp +++ b/examples/compress/compress.cpp @@ -488,7 +488,8 @@ int main(int argc, char **argv) params.sparams.min_p = 0; params.sparams.top_p = 1; params.sparams.top_k = -1; - params.sparams.temp = 0; + // Avoid temp=0 because greedy sampling breaks stuff + params.sparams.temp = 1.; gpt_init();