INGOR
Loading...
Searching...
No Matches
score
Score.h
1
/*
2
Score.{h,c} : Score abstraction
3
Copyright (C) 2018, Yoshinori Tamada <tamada A T ytlab.jp>
4
All rights reserved.
5
6
See LICENSE.txt for details of the licensing agreement.
7
*/
8
9
#ifndef __SCORE_H
10
#define __SCORE_H
11
12
#include "util/ytData.h"
13
#include "net/ytNode.h"
14
#include "net/ytEdge.h"
15
#include "net/ytNetwork.h"
16
17
typedef
struct
{
19
char
*
name
;
20
22
void
* (*init)(
ytData
* data,
ytKeyValues
* args);
23
25
double (*score)(
void
* buff,
const
int
j,
const
int
* parents,
const
int
q);
26
28
void (*reinit)(
void
* buff,
ytData
* data);
29
31
void (*cache)(
void
* buff,
int
on);
32
33
void (*edgeProp)(
void
* buff,
const
int
j,
const
int
* parents,
const
int
q,
34
const
int
k,
ytEdge
* edge);
35
36
void (*nodeProp)(
void
* buff,
int
i,
ytNode
* node);
37
38
void (*finalize)(
void
* buff);
39
40
void (*partialResidual)(
void
* buff,
const
int
j,
const
int
* parents,
const
int
q,
41
FILE ** fp,
double
* ll);
42
43
void (*edgeContribution)(
void
* buff,
ytNetwork
* network,
int
j,
44
const
int
* parents,
int
q,
45
int
mode,
double
* ar);
46
47
void (*setEdgeProp)(
void
* buff,
const
int
j,
const
int
* parents,
const
int
q,
48
const
int
k,
const
ytEdge
* edge);
49
50
void (*setNodeProp)(
void
* buff,
const
int
j,
const
ytNode
* node);
51
52
void (*status)(
void
* buff);
53
54
void (*setParam)(
void
* buff,
const
char
* key,
ytObject
* value);
55
57
void
*
buff
;
58
}
Score
;
59
60
Score
* Score_get(
const
char
* name);
61
62
#endif
/* __SCORE_H */
ytEdge
Network edge.
ytKeyValues
key-value pairs.
ytNetwork
Network abstraction.
ytObject
The basis class.
Score
Definition
Score.h:17
Score::buff
void * buff
Pointer to the score buffer that is used by the score functions.
Definition
Score.h:57
Score::name
char * name
Score name.
Definition
Score.h:19
ytData
General data container.
Definition
ytData.h:46
ytNode
Network node.
Definition
ytNode.h:15
Generated by
1.9.8