44#include "EST_Features.h"
45#include "array_smoother.h"
67 sm_fz.set_channel_name(
"F0", 0);
69 n = (int)(op.
F(
"window_length") /
fz.shift());
73 if (!op.
present(
"icda_no_smooth"))
74 smooth_portion(
sm_fz, op);
76 if (op.
present(
"icda_no_interp"))
82 int fill = op.
present(
"icda_fi") ? 1 : 0;
85 n = (int)(op.
F(
"second_length") /
fz.shift());
89 if (!op.
present(
"icda_no_smooth"))
90 smooth_portion(
smi_fz, op);
101 parse_ms_list(op,
ms);
103 if (op.
present(
"point_window_size"))
104 ms->window_length = op.
I(
"point_window_size");
146 interp.resize(
speech.num_frames(), interp.num_channels());
149 for (i = 1; i < interp.num_frames(); ++i)
151 if ((fill == 1) || (
speech.a(i) > 0.5))
153 if (!interp.track_break(i))
157 if ((n = interp.next_non_break(i)) == 0)
158 n = interp.num_frames() - 1;
164 m = (
n_val -
p_val) / ( interp.t(n) - interp.t(p));
166 interp.a(i) = (
m * f) +
p_val;
178 if (
al.present(
"smooth_double"))
179 ms->smooth_double =
al.I(
"smooth_double");
180 if (
al.present(
"hanning"))
181 ms->apply_hanning =
al.I(
"hanning");
182 if (
al.present(
"extrapolate"))
183 ms->extrapolate =
al.I(
"extrapolate");
184 if (
al.present(
"first_length"))
185 ms->first_median =
al.I(
"first_length");
186 if (
al.present(
"second_length"))
187 ms->second_median =
al.I(
"second_length");
188 if (
al.present(
"window_length"))
189 ms->window_length =
al.I(
"window_length");
void set(const EST_String &name, int ival)
const float F(const EST_String &path) const
int present(const EST_String &name) const
const int I(const EST_String &path) const
int track_break(int i) const
return true if frame i is a break
float & a(int i, int c=0)
void set_value(int i)
set frame i to be a value
int num_frames() const
return number of frames in track
void set_break(int i)
set frame i to be a break