diff options
author | Georgi Gerganov <ggerganov@gmail.com> | 2023-03-19 19:46:32 +0200 |
---|---|---|
committer | Georgi Gerganov <ggerganov@gmail.com> | 2023-03-19 19:46:32 +0200 |
commit | c494ed5b94b429d3d73721235e78c9f5fa6e5652 (patch) | |
tree | b9e06136606d1ee1fa74cc1dd2977d83e14e1fba | |
parent | c1c7026b470ced0b8a6c67e968c04bb47864def1 (diff) |
Fix off-by-one bug (#115)
-rw-r--r-- | main.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -977,7 +977,7 @@ int main(int argc, char ** argv) { last_n_tokens.erase(last_n_tokens.begin()); last_n_tokens.push_back(embd_inp[input_consumed]); ++input_consumed; - if ((int) embd.size() > params.n_batch) { + if ((int) embd.size() >= params.n_batch) { break; } } |