37 #include <OpenMS/config.h> 73 void getDefaultParameters(
Param& params);
111 template <
typename PeakContainerT>
112 void fitEMGPeakModel(
113 const PeakContainerT& input_peak,
114 PeakContainerT& output_peak,
115 const double left_pos = 0.0,
116 const double right_pos = 0.0
120 void updateMembers_();
144 void extractTrainingSet(
145 const std::vector<double>& xs,
146 const std::vector<double>& ys,
147 std::vector<double>& TrX,
148 std::vector<double>& TrY
163 double computeMuMaxDistance(
const std::vector<double>& xs)
const;
178 double computeInitialMean(
179 const std::vector<double>& xs,
180 const std::vector<double>& ys
196 UInt emg_gradient_descent(
197 const std::vector<double>& xs,
198 const std::vector<double>& ys,
223 const double prev_diff_E_param,
224 double& diff_E_param,
226 double& param_update,
228 const double current_E,
229 const double previous_E
247 double Loss_function(
248 const std::vector<double>& xs,
249 const std::vector<double>& ys,
272 const std::vector<double>& xs,
273 const std::vector<double>& ys,
296 const std::vector<double>& xs,
297 const std::vector<double>& ys,
320 const std::vector<double>& xs,
321 const std::vector<double>& ys,
344 const std::vector<double>& xs,
345 const std::vector<double>& ys,
394 const std::vector<double>& xs,
399 std::vector<double>& out_xs,
400 std::vector<double>& out_ys
449 const std::vector<double>& xs,
450 const std::vector<double>& ys,
466 const std::vector<double>& xs,
467 const std::vector<double>& ys,
468 std::vector<double>& TrX,
469 std::vector<double>& TrY
476 const std::vector<double>& xs,
477 const std::vector<double>& ys
484 const double prev_diff_E_param,
485 double& diff_E_param,
487 double& param_update,
489 const double current_E,
490 const double previous_E
494 prev_diff_E_param, diff_E_param, param_lr,
495 param_update, param, current_E, previous_E
510 const std::vector<double>& xs,
515 std::vector<double>& out_xs,
516 std::vector<double>& out_ys
void extractTrainingSet(const std::vector< double > &xs, const std::vector< double > &ys, std::vector< double > &TrX, std::vector< double > &TrY) const
Given a peak, extract a training set to be used with the gradient descent algorithm.
void emg_vector(const std::vector< double > &xs, const double h, const double mu, const double sigma, const double tau, std::vector< double > &out_xs, std::vector< double > &out_ys) const
Definition: EmgGradientDescent.h:509
double emg_point(const double x, const double h, const double mu, const double sigma, const double tau) const
Definition: EmgGradientDescent.h:522
double emg_point(const double x, const double h, const double mu, const double sigma, const double tau) const
Compute the EMG function on a single point.
Compute the area, background and shape metrics of a peak.
Definition: EmgGradientDescent.h:64
double compute_z(const double x, const double mu, const double sigma, const double tau) const
Compute EMG's z parameter.
void iRpropPlus(const double prev_diff_E_param, double &diff_E_param, double ¶m_lr, double ¶m_update, double ¶m, const double current_E, const double previous_E) const
Apply the iRprop+ algorithm for gradient descent.
double computeInitialMean(const std::vector< double > &xs, const std::vector< double > &ys) const
Definition: EmgGradientDescent.h:475
unsigned int UInt
Unsigned integer type.
Definition: Types.h:94
double Loss_function(const std::vector< double > &xs, const std::vector< double > &ys, const double h, const double mu, const double sigma, const double tau) const
Definition: EmgGradientDescent.h:448
double Loss_function(const std::vector< double > &xs, const std::vector< double > &ys, const double h, const double mu, const double sigma, const double tau) const
Compute the cost given by loss function E.
void iRpropPlus(const double prev_diff_E_param, double &diff_E_param, double ¶m_lr, double ¶m_update, double ¶m, const double current_E, const double previous_E) const
Definition: EmgGradientDescent.h:483
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:46
double computeInitialMean(const std::vector< double > &xs, const std::vector< double > &ys) const
Compute an estimation of the mean of a peak.
void extractTrainingSet(const std::vector< double > &xs, const std::vector< double > &ys, std::vector< double > &TrX, std::vector< double > &TrY) const
Definition: EmgGradientDescent.h:465
~EmgGradientDescent_friend()=default
Definition: EmgGradientDescent.h:442
EmgGradientDescent_friend()=default
Management and storage of parameters / INI files.
Definition: Param.h:74
void emg_vector(const std::vector< double > &xs, const double h, const double mu, const double sigma, const double tau, std::vector< double > &out_xs, std::vector< double > &out_ys) const
Compute the EMG function on a set of points.
double computeMuMaxDistance(const std::vector< double > &xs) const
Compute the boundary for the mean (`mu`) parameter in gradient descent.
EmgGradientDescent emg_gd_
Definition: EmgGradientDescent.h:533
A base class for all classes handling default parameters.
Definition: DefaultParamHandler.h:91
double compute_z(const double x, const double mu, const double sigma, const double tau) const
Definition: EmgGradientDescent.h:499
double computeMuMaxDistance(const std::vector< double > &xs) const
Definition: EmgGradientDescent.h:460
bool compute_additional_points_
Definition: EmgGradientDescent.h:439
UInt print_debug_
Definition: EmgGradientDescent.h:430
UInt max_gd_iter_
Maximum number of gradient descent iterations in `fitEMGPeakModel()`.
Definition: EmgGradientDescent.h:433