File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 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) {
19911991 params.n_batch = std::min (params.n_batch , n_kv);
19921992 } else {
19931993 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+ }
19942000 }
19952001
19962002 if (params.ppl_stride > 0 ) {
@@ -2015,9 +2021,6 @@ int main(int argc, char ** argv) {
20152021 llama_model * model;
20162022 llama_context * ctx;
20172023
2018- // ensure there's at least enough seq_ids for HellaSwag
2019- params.n_parallel = std::max (4 , params.n_parallel );
2020-
20212024 // load the model and apply lora adapter, if any
20222025 std::tie (model, ctx) = llama_init_from_gpt_params (params);
20232026 if (model == NULL ) {
You can’t perform that action at this time.
0 commit comments