MCPcopy Create free account
hub / github.com/modelscope/FunASR / parse_mvn

Function parse_mvn

runtime/llama.cpp/export_vad_gguf.py:6–9  ·  view source on GitHub ↗
(path)

Source from the content-addressed store, hash-verified

4import numpy as np, torch, gguf
5
6def parse_mvn(path):
7 with open(path) as f: txt=f.read()
8 b=[np.array([float(x) for x in m.split()],np.float32) for m in re.findall(r"\[([^\]]*)\]",txt)]
9 v=[x for x in b if x.size>1]; return v[0], v[1] # shift, scale (both 400-dim)
10
11def main():
12 ap=argparse.ArgumentParser()

Callers 1

mainFunction · 0.70

Calls 1

readMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…