-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMlpNetwork.h
40 lines (32 loc) · 874 Bytes
/
MlpNetwork.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
33
34
35
36
37
38
39
40
//MlpNetwork.h
#ifndef MLPNETWORK_H
#define MLPNETWORK_H
#include <iostream>
#include "Matrix.h"
#include "Dense.h"
#include "Digit.h"
#define MLP_SIZE 4
//
const matrix_dims img_dims = {28, 28};
const matrix_dims weights_dims[] = {{128, 784},
{64, 128},
{20, 64},
{10, 20}};
const matrix_dims bias_dims[] = {{128, 1},
{64, 1},
{20, 1},
{10, 1}};
// Insert MlpNetwork class here...
class MlpNetwork{
private:
Dense _r1;
Dense _r2;
Dense _r3;
Dense _r4;
public:
//constructor
MlpNetwork(const Matrix weights[], const Matrix biases[]);
//() operator
Digit operator()(const Matrix& x) const;
};
#endif // MLPNETWORK_H