Free cookie consent management tool by TermsFeed Policy Generator

source: branches/3027-NormalDistribution/HeuristicLab.ExtLibs/HeuristicLab.NativeInterpreter/0.1/NativeInterpreter-0.1/src/instruction.h @ 17243

Last change on this file since 17243 was 16701, checked in by bburlacu, 6 years ago

#2866: Support hyperbolic tangent in native interpreter.

File size: 1.0 KB
Line 
1#ifndef INSTRUCTION_H
2#define INSTRUCTION_H
3
4#include <cstdint>
5
6#include "vector_operations.h"
7
8enum OpCodes : uint8_t
9{
10    // same values as in OpCodes.cs
11    Add                = 1,
12    Sub                = 2,
13    Mul                = 3,
14    Div                = 4,
15    Sin                = 5,
16    Cos                = 6,
17    Tan                = 7,
18    Log                = 8,
19    Exp                = 9,
20    Var                = 18,
21    Const              = 20,
22    Power              = 22,
23    Root               = 23,
24    Square             = 28,
25    Sqrt               = 29,
26    Absolute           = 48,
27    AnalyticalQuotient = 49,
28    Cube               = 50,
29    CubeRoot           = 51,
30    Tanh               = 52
31};
32
33struct instruction
34{
35    // from Instruction.cs
36    uint8_t opcode;
37    uint16_t narg;
38
39    int childIndex;
40
41    // from LinearInstruction.cs
42    double value;
43    double weight; // necessary for variables
44
45    // pointer to data
46    double *buf;
47    double *data;
48};
49
50#endif
Note: See TracBrowser for help on using the repository browser.