def mse_nlms(x, d, h, mu): import numpy as np from adaptive_filters import NLMS from filter_sim_routines import run_filter nlms = NLMS(h.shape[0], mu=mu) w = run_filter(x, d, nlms) e = np.linalg.norm(h - w, axis=1)**2 return e
def mse_srls(x, d, h, lmbd, delta, N, pr): import numpy as np from sketch_rls import SketchRLS from filter_sim_routines import run_filter srls = SketchRLS(h.shape[0], lmbd=lmbd, delta=delta, N=N, p=pr) w = run_filter(x, d, srls) e = np.linalg.norm(h - w, axis=1)**2 return e
def mse_brls(x, d, h, lmbd, delta, L): import numpy as np from adaptive_filters import BlockRLS from filter_sim_routines import run_filter brls = BlockRLS(h.shape[0], lmbd=lmbd, delta=delta, L=L) w = run_filter(x, d, brls) e = np.linalg.norm(h - w, axis=1)**2 return e