We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 61f587a commit a2f4659Copy full SHA for a2f4659
src/denoise.c
@@ -295,6 +295,9 @@ int rnnoise_init(DenoiseState *st, RNNModel *model) {
295
st->rnn.model = model;
296
else
297
st->rnn.model = &rnnoise_model_orig;
298
+ st->rnn.vad_gru_state = calloc(sizeof(float), st->rnn.model->vad_gru_size);
299
+ st->rnn.noise_gru_state = calloc(sizeof(float), st->rnn.model->noise_gru_size);
300
+ st->rnn.denoise_gru_state = calloc(sizeof(float), st->rnn.model->denoise_gru_size);
301
return 0;
302
}
303
@@ -306,6 +309,9 @@ DenoiseState *rnnoise_create(RNNModel *model) {
306
309
307
310
308
311
void rnnoise_destroy(DenoiseState *st) {
312
+ free(st->rnn.vad_gru_state);
313
+ free(st->rnn.noise_gru_state);
314
+ free(st->rnn.denoise_gru_state);
315
free(st);
316
317
0 commit comments