mirror of
				https://github.com/ggml-org/llama.cpp.git
				synced 2025-10-31 08:51:55 +00:00 
			
		
		
		
	Strided perplexity (#2714)
* Implementing strided computation of perplexity * Alternative way to output PPL results --------- Co-authored-by: Iwan Kawrakow <iwan.kawrakow@gmail.com>
This commit is contained in:
		| @@ -64,6 +64,10 @@ struct gpt_params { | ||||
|     std::string lora_adapter = "";  // lora adapter path | ||||
|     std::string lora_base    = "";  // base model path for the lora adapter | ||||
|  | ||||
|     int  ppl_stride        = 0;     // stride for perplexity calculations. If left at 0, the pre-existing approach will be used. | ||||
|     int  ppl_output_type   = 0;     // = 0 -> ppl output is as usual, = 1 -> ppl output is num_tokens, ppl, one per line | ||||
|                                     //                                       (which is more convenient to use for plotting) | ||||
|                                     // | ||||
|     bool hellaswag         = false; // compute HellaSwag score over random tasks from datafile supplied in prompt | ||||
|     size_t hellaswag_tasks = 400;   // number of tasks to use when computing the HellaSwag score | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Kawrakow
					Kawrakow