worker fix?
This commit is contained in:
@@ -84,6 +84,7 @@ function combineSpeakerTranscript(chunks: any[], speakers: any[]): string {
|
||||
|
||||
parentPort?.on('message', async ({ file, speaker, model, modelDir }) => {
|
||||
try {
|
||||
console.log('worker', file);
|
||||
if(!whisperPipeline) whisperPipeline = await pipeline('automatic-speech-recognition', `Xenova/${model}`, {cache_dir: modelDir, quantized: true});
|
||||
|
||||
// Prepare audio file (convert to mono channel wave)
|
||||
|
||||
Reference in New Issue
Block a user