whisper : fix possible uninitialized variables (#291)

This commit is contained in:
Georgi Gerganov 2023-01-16 21:44:40 +02:00
parent c9aeb33676
commit 8088a977af
No known key found for this signature in database
GPG Key ID: 449E073F9DC10735

View File

@ -3091,10 +3091,10 @@ static std::vector<whisper_token_data> whisper_sample_token_topk(
std::vector<whisper_token_data> result; std::vector<whisper_token_data> result;
result.reserve(k); result.reserve(k);
whisper_token tid; whisper_token tid = vocab.token_beg;
float pt; float pt = 0.0;
float ptsum; float ptsum = 0.0;
{ {
double sum_ts = 0.0; double sum_ts = 0.0;