Home
last modified time | relevance | path

Searched refs:lc3 (Results 1 – 10 of 10) sorted by relevance

/packages/modules/Bluetooth/system/embdrv/lc3/test/
Dmdct.py20 import build.lc3 as lc3 namespace
109 (y_c[0], d_c) = lc3.mdct_forward(dt, sr, x, np.zeros(nd))
110 y_c[1] = lc3.mdct_forward(dt, sr, x, d_c)[0]
125 (y, d) = lc3.mdct_forward(dt, sr, C.X_PCM[dt][0], np.zeros(nd))
128 (y, d) = lc3.mdct_forward(dt, sr, C.X_PCM[dt][1], d)
149 (y_c[0], d_c) = lc3.mdct_inverse(dt, sr, x, np.zeros(nd))
150 y_c[1] = lc3.mdct_inverse(dt, sr, x, d_c)[0]
165 (y, d0) = lc3.mdct_inverse(dt, sr, C.X_HAT_SNS[dt][0], np.zeros(nd))
172 (y, d1) = lc3.mdct_inverse(dt, sr, C.X_HAT_SNS[dt][1], d0)
Denergy.py19 import build.lc3 as lc3 namespace
53 (e_c, nn_c) = lc3.energy_compute(dt, sr, x)
59 (e_c, nn_c) = lc3.energy_compute(dt, sr, x)
69 e = lc3.energy_compute(dt, sr, C.X[dt][0])[0]
72 e = lc3.energy_compute(dt, sr, C.X[dt][1])[0]
Dtns.py19 import build.lc3 as lc3 namespace
317 (y_c, data_c) = lc3.tns_analyze(dt, bw, nn_flag, nbytes, x)
328 ok = ok and lc3.tns_get_nbits(data_c) == analysis.get_nbits()
347 y_c = lc3.tns_synthesize(dt, bw, synthesis.get_data(), x)
364 (_, a) = lc3.tns_compute_lpc_coeffs(dt, sr, C.X_S[dt][i])
367 rc = lc3.tns_lpc_reflection(a[0])
370 (rc_order, rc_i) = lc3.tns_quantize_rc(C.TNS_LEV_RC[dt][i])
374 rc_q = lc3.tns_unquantize_rc(rc_i, rc_order)
377 (x, side) = lc3.tns_analyze(dt, sr, False, C.NBYTES[dt], C.X_S[dt][i])
381 ok = ok and lc3.tns_get_nbits(side) == C.NBITS_TNS[dt][i]
[all …]
Ddecoder.py24 import build.lc3 as lc3 namespace
105 dec_c = lc3.setup_decoder(int(T.DT_MS[dt] * 1000), 16000)
109 pcm = lc3.decode(dec_c, bytes(C.BYTES_AC[dt][i]))
158 dec_c = lc3.setup_decoder(int(dt_ms * 1000), sr_hz)
186 x_c = lc3.decode(dec_c, data)
Dbwdet.py19 import build.lc3 as lc3 namespace
126 bw_c = lc3.bwdet_run(dt, sr, e)
140 bw = lc3.bwdet_run(dt, sr, E_B[0])
143 bw = lc3.bwdet_run(dt, sr, E_B[1])
Dattdet.py19 import build.lc3 as lc3 namespace
114 f_att = lc3.attdet_run(dt, sr, nbytes,
143 f_att_c = lc3.attdet_run(dt, sr, 100, state_c, x_c)
159 f_att = lc3.attdet_run(dt, sr, C.NBYTES_ATT[dt], state, x)
163 f_att = lc3.attdet_run(dt, sr, C.NBYTES_ATT[dt], state, x)
Dencoder.py24 import build.lc3 as lc3 namespace
113 enc_c = lc3.setup_encoder(int(T.DT_MS[dt] * 1000), 16000)
117 data = lc3.encode(enc_c, C.X_PCM[dt][i], C.NBYTES[dt])
169 enc_c = lc3.setup_encoder(int(args.dt * 1000), sr_hz)
197 data_c = lc3.encode(enc_c, frame_pcm, frame_nbytes)
Dspec.py19 import build.lc3 as lc3 namespace
586 (g_int_c, reset_off_c) = lc3.spec_estimate_gain(
607 (xg_c, xq_c, nq_c) = lc3.spec_quantize(dt, sr, g_int, x)
636 lc3.spec_compute_nbits(dt, sr, nbytes, xq, nq, 0)
639 lc3.spec_compute_nbits(dt, sr, nbytes, xq, nq, nbits_budget)
661 g_adj_c = lc3.spec_adjust_gain(sr, g_idx, nbits, nbits_budget)
696 (_, xq_c, side_c) = lc3.spec_analyze(
719 nf_c = lc3.spec_estimate_noise(dt, bw, xq, nq, x)
735 g_int = lc3.spec_estimate_gain(dt, sr, C.X_F[dt][i],
739 (_, xq, nq) = lc3.spec_quantize(dt, sr,
[all …]
Dsns.py20 import build.lc3 as lc3 namespace
474 (y_c, data_c) = lc3.sns_analyze(dt, sr, e, att, x)
479 ok = ok and lc3.sns_get_nbits() == analysis.get_nbits()
508 y_c = lc3.sns_synthesize(dt, sr, synthesis.get_data(), x)
520 scf = lc3.sns_compute_scale_factors(dt, sr, C.E_B[dt][i], False)
523 (lf, hf) = lc3.sns_resolve_codebooks(scf)
526 (y, yn, shape, gain) = lc3.sns_quantize(scf, lf, hf)
534 scf_q = lc3.sns_unquantize(lf, hf, yn[shape], shape, gain)
537 x = lc3.sns_spectral_shaping(dt, sr, C.SCF_Q[dt][i], False, C.X[dt][i])
540 (x, data) = lc3.sns_analyze(dt, sr, C.E_B[dt][i], False, C.X[dt][i])
[all …]
Dltpf.py20 import build.lc3 as lc3 namespace
461 y_c = lc3.ltpf_resample(dt, sr, hp50_c, x_c, y_c)
480 y = lc3.ltpf_resample(dt, sr, state, x, y)
487 y = lc3.ltpf_resample(dt, sr, state, x, y)
516 (pitch_present_c, data_c) = lc3.ltpf_analyse(dt, sr, state_c, x_c)
523 ok = ok and lc3.ltpf_get_nbits(pitch_present) == ltpf.get_nbits()
558 x_c = lc3.ltpf_synthesize(dt, sr, nbytes, state_c, data_c, x_c)
573 (pitch_present, data) = lc3.ltpf_analyse(dt, sr, state, x)
582 (pitch_present, data) = lc3.ltpf_analyse(dt, sr, state, x)
629 lc3.ltpf_synthesize(dt, sr, nbytes, state, data, x)
[all …]