d-ser-t-service
Advanced tools
Comparing version 1.2.1 to 1.2.2
@@ -15,4 +15,6 @@ "use strict"; | ||
} | ||
const copyArray = new Uint8Array(dataBuffer); | ||
if (this.currentOffset >= this.currentFile.byteLength) { | ||
// The file has been fully read. Send silence back. | ||
copyArray.fill(0); | ||
return dataBuffer.byteLength; | ||
@@ -23,3 +25,2 @@ } | ||
const bytesToSend = Math.min(bytesLeftInFile, dataBuffer.byteLength); | ||
const copyArray = new Uint8Array(dataBuffer); | ||
copyArray.set(new Uint8Array(this.currentFile.slice(this.currentOffset, bytesToSend + this.currentOffset))); | ||
@@ -26,0 +27,0 @@ this.currentOffset += bytesToSend; |
@@ -158,5 +158,6 @@ "use strict"; | ||
console.info(`New file into stream, ${currentFileIndex}/${dataArray.length}, recognizer: ${recognizerID}`); | ||
stream.setFile(dataArray[currentFileIndex++] | ||
stream.setFile(dataArray[currentFileIndex] | ||
.recording || | ||
dataArray[currentFileIndex++].toString()); | ||
dataArray[currentFileIndex].toString()); | ||
currentFileIndex++; | ||
} | ||
@@ -163,0 +164,0 @@ } |
{ | ||
"name": "d-ser-t-service", | ||
"version": "1.2.1", | ||
"version": "1.2.2", | ||
"description": "Dynamic Sentence Error Rate Testing: A Package for testing the CRIS speech-to-text model, quantifying the quality of the model with respect to its Word Error Rate", | ||
@@ -60,3 +60,3 @@ "license": "MIT", | ||
}, | ||
"gitHead": "a942cbf536b56b9ea0ad546ee0fb8059cb177731" | ||
"gitHead": "a24f047377f3c017304db612131779c5af1f8807" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
101491
1250