-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathUpdater.h
32 lines (27 loc) · 944 Bytes
/
Updater.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
//
// Created by squall on 18-6-11.
//
#ifndef MTREE_OBJECTIVE_H
#define MTREE_OBJECTIVE_H
#include <vector>
#include "utils.h"
using namespace std;
using namespace common;
class Updater {
public:
Updater() {}
// virtual float get_gradient() = 0;
virtual ~Updater() {}
virtual float get_score(const vector<float> &feature,
const Matrix &gradients,
const vector<int> &sample_index,
float cut_point,
float lambda) = 0;
virtual vector<float> get_scores(const vector<float> &feature,
const Matrix &gradients,
const vector<int> &task,
const int &task_num,
const vector<int> &sample_index,
float cut_point, float lambda) = 0;
};
#endif //MTREE_OBJECTIVE_H