File tree 1 file changed +6
-3
lines changed
1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -1991,6 +1991,12 @@ int main(int argc, char ** argv) {
1991
1991
params.n_batch = std::min (params.n_batch , n_kv);
1992
1992
} else {
1993
1993
params.n_batch = std::min (params.n_batch , params.n_ctx );
1994
+ if (params.kl_divergence ) {
1995
+ params.n_parallel = 1 ;
1996
+ } else {
1997
+ // ensure there's at least enough seq_ids for HellaSwag
1998
+ params.n_parallel = std::max (4 , params.n_parallel );
1999
+ }
1994
2000
}
1995
2001
1996
2002
if (params.ppl_stride > 0 ) {
@@ -2015,9 +2021,6 @@ int main(int argc, char ** argv) {
2015
2021
llama_model * model;
2016
2022
llama_context * ctx;
2017
2023
2018
- // ensure there's at least enough seq_ids for HellaSwag
2019
- params.n_parallel = std::max (4 , params.n_parallel );
2020
-
2021
2024
// load the model and apply lora adapter, if any
2022
2025
std::tie (model, ctx) = llama_init_from_gpt_params (params);
2023
2026
if (model == NULL ) {
You can’t perform that action at this time.
0 commit comments