Home
last modified time | relevance | path

Searched refs:e (Results 1 – 22 of 22) sorted by relevance

/liblc3-3.5.0-3.4.0/test/neon/
Dneon.h32 typedef struct { int16_t e[4]; } int16x4_t; member
34 typedef struct { int16_t e[8]; } int16x8_t; member
35 typedef struct { int32_t e[4]; } int32x4_t; member
36 typedef struct { int64_t e[2]; } int64x2_t; member
57 return (int32x4_t){ { a.e[0] * b.e[0], a.e[1] * b.e[1], in vmull_s16()
58 a.e[2] * b.e[2], a.e[3] * b.e[3] } }; in vmull_s16()
65 r.e[0] + a.e[0] * b.e[0], r.e[1] + a.e[1] * b.e[1], in vmlal_s16()
66 r.e[2] + a.e[2] * b.e[2], r.e[3] + a.e[3] * b.e[3] } }; in vmlal_s16()
74 r.e[0] = a.e[0] + ((int64_t)b.e[0] + b.e[1]); in vpadalq_s32()
75 r.e[1] = a.e[1] + ((int64_t)b.e[2] + b.e[3]); in vpadalq_s32()
[all …]
/liblc3-3.5.0-3.4.0/test/
Denergy.py33 e = [ np.mean(np.square(x[self.I[i]:self.I[i+1]]))
36 e_lo = np.sum(e[:len(e) - [4, 2][self.dt]])
37 e_hi = np.sum(e[len(e) - [4, 2][self.dt]:])
39 return np.append(e, np.zeros(64-len(e))), (e_hi > 30*e_lo)
52 (e , nn ) = nrg.compute(x)
54 ok = ok and np.amax(np.abs(e_c - e)) < 1e-5 and nn_c == nn
58 (e , nn ) = nrg.compute(x)
60 ok = ok and np.amax(np.abs(e_c - e)) < 1e-3 and nn_c == nn
69 e = lc3.energy_compute(dt, sr, C.X[dt][0])[0]
70 ok = ok and np.amax(np.abs(1 - e/C.E_B[dt][0])) < 1e-6
[all …]
Dbwdet.py48 def run(self, e): argument
60 if np.mean(e[i0:i1+1]) >= TQ[bw]:
72 c = 10 * np.log10(1e-31 + e[i0-l+1:i1-l+2] / e[i0+1:i1+2])
106 e = 20 + 100 * rng.random(64)
112 e[i0:i1+1] /= (np.mean(e[i0:i1+1]) / TQ[i] + 1e-3)
122 e[i0-l+1:i1+2] /= np.power(10, np.arange(2*l+1) / (1 + drop))
126 bw_c = lc3.bwdet_run(dt, sr, e)
128 ok = ok and bw_c == bwdet.run(e)
Dbwdet_py.c29 float *e; in bwdet_run_py() local
36 CTYPES_CHECK("e", to_1d_ptr(e_obj, NPY_FLOAT, LC3_NUM_BANDS, &e)); in bwdet_run_py()
38 int bw = lc3_bwdet_run(dt, sr, e); in bwdet_run_py()
Denergy_py.c32 float *x, *e; in energy_compute_py() local
43 e_obj = new_1d_ptr(NPY_FLOAT, LC3_NUM_BANDS, &e); in energy_compute_py()
45 int nn_flag = lc3_energy_compute(dt, sr, x, e); in energy_compute_py()
Dsns.py92 def compute_scale_factors(self, e, att): argument
98 n2 = 64 - len(e)
100 e = np.append(np.empty(n2), e)
102 e[2*i+0] = e[2*i+1] = e[n2+i]
106 e_s = np.zeros(len(e))
107 e_s[0 ] = 0.75 * e[0 ] + 0.25 * e[1 ]
108 e_s[1:63] = 0.25 * e[0:62] + 0.5 * e[1:63] + 0.25 * e[2:64]
109 e_s[ 63] = 0.25 * e[ 62] + 0.75 * e[ 63]
119 e_p = np.fmax(e_p, noise_floor * np.ones(len(e)))
468 e = rng.random(min(len(x), 64)) * 1e10
[all …]
Dltpf.py69 e = (15 * i) // p
72 u[2+i] = p * np.dot( x[e:e+w+1], np.take(h, k) )
211 e = k0 + np.argmax(r[4:-4])
218 s = [ np.dot( np.take(r, e-k0+4 + m), np.take(h, 4*m-d) ) \
221 f = np.argmax(s[3:]) if e <= 32 else \
222 -3 + np.argmax(s) if e < 127 else \
223 -2 + 2*np.argmax(s[1:-1:2]) if e < 157 else 0
225 e -= (f < 0)
228 self.pitch_index = 4*e + f - 128 if e < 127 else \
229 2*e + f//2 + 126 if e < 157 else e + 283
[all …]
Dencoder.py62 (e, nn_flag) = self.energy.compute(x)
66 bw = self.bwdet.run(e)
68 x = self.sns.run(e, att, x)
Dtns.py110 e = [ sum(x[S[s]:S[s+1]] ** 2) for s in range(3) ]
112 for k in range(len(r) if sum(e) > 0 else 0):
116 r[k] = np.sum( np.array(c) / np.array(e) )
148 e = 1 - rc[k-1] ** 2
149 b[1:k] = (b[1:k] - rc[k-1] * b[k-1:0:-1]) / e
Dspec.py79 e = [ np.sum(x[4*k:4*(k+1)] ** 2) for k in range(len(x) // 4) ]
80 e = 10 * np.log10(2**-31 + np.array(e))
92 for ei in e[-1::-1]:
692 e = rng.random(min(len(x), 64)) * 1e10
694 bwdet.run(e)
697 sns.run(e, False, x)
/liblc3-3.5.0-3.4.0/src/
Dsns.c253 float e[LC3_NUM_BANDS]; in compute_scale_factors() local
261 e[2*i2 + 0] = e[2*i2 + 1] = eb[i2]; in compute_scale_factors()
263 memcpy(e + 2*n2, eb + n2, (nb - n2) * sizeof(float)); in compute_scale_factors()
269 float e0 = e[0], e1 = e[0], e2; in compute_scale_factors()
273 e[i] = (e0 * 0.25f + e1 * 0.5f + (e2 = e[i+1]) * 0.25f) * ge[i]; in compute_scale_factors()
274 e_sum += e[i++]; in compute_scale_factors()
276 e[i] = (e1 * 0.25f + e2 * 0.5f + (e0 = e[i+1]) * 0.25f) * ge[i]; in compute_scale_factors()
277 e_sum += e[i++]; in compute_scale_factors()
279 e[i] = (e2 * 0.25f + e0 * 0.5f + (e1 = e[i+1]) * 0.25f) * ge[i]; in compute_scale_factors()
280 e_sum += e[i++]; in compute_scale_factors()
[all …]
Denergy.c27 enum lc3_dt dt, enum lc3_srate sr, const float *x, float *e) in lc3_energy_compute() argument
41 *e = x[iband] * x[iband]; in lc3_energy_compute()
42 e_sum[0] += *(e++); in lc3_energy_compute()
60 *e = sx2 / n; in lc3_energy_compute()
61 e_sum[iband >= iband_h] += *(e++); in lc3_energy_compute()
65 *(e++) = 0; in lc3_energy_compute()
Dattdet.c43 int32_t e[4]; in lc3_attdet_run() local
46 e[i] = 0; in lc3_attdet_run()
56 e[i] += (xf * xf) >> 5; in lc3_attdet_run()
68 e[i] += (xf * xf) >> 5; in lc3_attdet_run()
82 attdet->en1 = e[i], attdet->an1 = a[i]; in lc3_attdet_run()
84 if ((e[i] >> 3) > a[i] + (a[i] >> 4)) in lc3_attdet_run()
Dbwdet.c26 enum lc3_dt dt, enum lc3_srate sr, const float *e) in lc3_bwdet_run() argument
70 float se = e[i]; in lc3_bwdet_run()
72 se += e[i]; in lc3_bwdet_run()
91 hold = e[i-l] > tc * e[i]; in lc3_bwdet_run()
Dfastmath.h69 int e; in fast_log2f() local
76 x = frexpf(x, &e); in fast_log2f()
86 return e + y; in fast_log2f()
Dltpf.c576 int e, f; in refine_pitch() local
583 e = r0 + argmax(r + 4, nr, &rm); in refine_pitch()
584 const float *re = r + (e - (r0 - 4)); in refine_pitch()
590 if (e >= 127 && ((i & 1) | (e >= 157))) in refine_pitch()
596 if (e > 32 && (d = interpolate_corr(re, -i)) > dm) in refine_pitch()
600 e -= (f < 0); in refine_pitch()
603 *pitch = 4*e + f; in refine_pitch()
604 return e < 127 ? 4*e + f - 128 : in refine_pitch()
605 e < 157 ? 2*e + (f >> 1) + 126 : e + 283; in refine_pitch()
Denergy.h40 enum lc3_dt dt, enum lc3_srate sr, const float *x, float *e);
Dbwdet.h40 enum lc3_dt dt, enum lc3_srate sr, const float *e);
Dtns.c168 float e, b[2][7], *b0, *b1; in lpc_reflection() local
171 e = 1 - rc[7] * rc[7]; in lpc_reflection()
175 b1[i] = (a[1+i] - rc[7] * a[7-i]) / e; in lpc_reflection()
181 e = 1 - rc[k] * rc[k]; in lpc_reflection()
184 b1[i] = (b0[i] - rc[k] * b0[k-1-i]) / e; in lpc_reflection()
Dlc3.c272 float e[LC3_NUM_BANDS]; in analyze() local
276 bool nn_flag = lc3_energy_compute(dt, sr, xf, e); in analyze()
280 side->bw = lc3_bwdet_run(dt, sr, e); in analyze()
282 lc3_sns_analyze(dt, sr, e, att, &side->sns, xf, xf); in analyze()
Dspec.c54 int e[ne]; in estimate_gain() local
71 e[i] = fast_db_q16(fmaxf(x0 + x1 + x2 + x3, 1e-10f)); in estimate_gain()
87 for (j = j0; j >= 0 && e[j] < gn; j--); in estimate_gain()
90 int e_diff = e[j] - gn; in estimate_gain()
/liblc3-3.5.0-3.4.0/tables/
Dfastmath.py37 e = np.abs(y - 2**x) / (2 ** x)
41 print('Max relative error: ', np.max(e))
42 print('Max RMS error: ', np.sqrt(np.mean(e ** 2)))
51 ax2.plot(x, e, label='Relative Error')
62 (x, e) = np.frexp(x)
66 return (e ) + y.astype(np.float32)
75 e = np.abs(y - np.log2(x))
79 print('Max absolute error: ', np.max(e))
80 print('Max RMS error: ', np.sqrt(np.mean(e ** 2)))
89 ax2.plot(x, e, label = 'Absolute error')