TraceLab Component Library
Main Page
Packages
Classes
Files
File List
All
Classes
Namespaces
Files
Functions
Variables
Enumerations
Enumerator
Properties
LDAConfig.cs
Go to the documentation of this file.
1
// TraceLab Component Library
2
// Copyright © 2012-2013 SEMERU
3
//
4
// This program is free software: you can redistribute it and/or modify
5
// it under the terms of the GNU General Public License as published by
6
// the Free Software Foundation, either version 3 of the License, or
7
// (at your option) any later version.
8
//
9
// This program is distributed in the hope that it will be useful,
10
// but WITHOUT ANY WARRANTY; without even the implied warranty of
11
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
// GNU General Public License for more details.
13
//
14
// You should have received a copy of the GNU General Public License
15
// along with this program. If not, see <http://www.gnu.org/licenses/>.
16
17
using
System;
18
using
TraceLabSDK;
19
20
namespace
TraceLab.Components.Types.Tracers.InformationRetrieval
21
{
22
[WorkspaceType]
23
[Serializable]
24
public
class
LDAConfig
:
RConfig
25
{
26
#region Private members
27
28
private
int
_NumTopics;
29
private
double
_Alpha;
30
private
double
_Eta;
31
private
double
_PredictionBeta;
32
private
int
_NumIterations;
33
private
int
_Seed;
34
35
#endregion
36
37
public
double
Alpha
38
{
39
get
40
{
41
return
_Alpha;
42
}
43
set
44
{
45
if
(value <= 0.0)
46
throw
new
ArgumentException(
"Alpha must be greater than 0."
);
47
else
48
_Alpha = value;
49
}
50
}
51
52
public
double
Eta
53
{
54
get
55
{
56
return
_Eta;
57
}
58
set
59
{
60
if
(value <= 0.0)
61
throw
new
ArgumentException(
"Eta must be greater than 0."
);
62
else
63
_Eta = value;
64
}
65
}
66
67
public
double
PredictionBeta
68
{
69
get
70
{
71
return
_PredictionBeta;
72
}
73
set
74
{
75
if
(value <= 0.0)
76
throw
new
ArgumentException(
"Beta1 must be greater than 0."
);
77
else
78
_PredictionBeta = value;
79
}
80
}
81
82
public
int
NumTopics
83
{
84
get
85
{
86
return
_NumTopics;
87
}
88
set
89
{
90
if
(value <= 0)
91
throw
new
ArgumentException(
"Number of topics must be greater than 0."
);
92
else
93
_NumTopics = value;
94
}
95
}
96
97
public
int
NumIterations
98
{
99
get
100
{
101
return
_NumIterations;
102
}
103
set
104
{
105
if
(value <= 0)
106
throw
new
ArgumentException(
"Number of iterations must be greater than 0."
);
107
else
108
_NumIterations = value;
109
}
110
}
111
112
public
int
Seed
113
{
114
get
115
{
116
return
_Seed;
117
}
118
set
119
{
120
if
(value <= 0)
121
throw
new
ArgumentException(
"Seed must be greater than 0."
);
122
else
123
_Seed = value;
124
}
125
}
126
}
127
}
TraceLab.Components.RPlugin
TraceLab.Components.RPlugin.Types
Tracers
InformationRetrieval
LDAConfig.cs
Generated on Mon May 20 2013 18:13:11 for TraceLab Component Library by
1.8.4