MCPcopy Create free account
hub / github.com/diffusionstudio/vits-web / randomByte

Function randomByte

src/piper.js:2884–2889  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2882 var randomBuffer = new Uint8Array(1024),
2883 randomLeft = 0;
2884 var randomByte = () => {
2885 if (randomLeft === 0) {
2886 randomLeft = randomFill(randomBuffer).byteLength;
2887 }
2888 return randomBuffer[--randomLeft];
2889 };
2890 FS.createDevice('/dev', 'random', randomByte);
2891 FS.createDevice('/dev', 'urandom', randomByte);
2892 FS.mkdir('/dev/shm');

Callers

nothing calls this directly

Calls 1

randomFillFunction · 0.85

Tested by

no test coverage detected