Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
cs598mp-fall2021-proj
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
chsieh16
cs598mp-fall2021-proj
Commits
e2c4d536
Commit
e2c4d536
authored
2 years ago
by
aastorg2
Browse files
Options
Downloads
Patches
Plain Diff
changing learner to choose halfway point bet negative and positive for threshold
parent
0f47f5c0
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
c50exact/c50.c
+3
-2
3 additions, 2 deletions
c50exact/c50.c
c50exact/construct.c
+1
-1
1 addition, 1 deletion
c50exact/construct.c
c50exact/contin.c
+7
-3
7 additions, 3 deletions
c50exact/contin.c
with
11 additions
and
6 deletions
c50exact/c50.c
+
3
−
2
View file @
e2c4d536
...
@@ -30,6 +30,7 @@
...
@@ -30,6 +30,7 @@
/* */
/* */
/*************************************************************************/
/*************************************************************************/
#define DEBUG true
#include
"defns.i"
#include
"defns.i"
#include
"extern.i"
#include
"extern.i"
...
@@ -92,7 +93,7 @@ int main(int Argc, char *Argv[])
...
@@ -92,7 +93,7 @@ int main(int Argc, char *Argv[])
FILE
*
F
;
FILE
*
F
;
CaseNo
SaveMaxCase
;
CaseNo
SaveMaxCase
;
Attribute
Att
;
Attribute
Att
;
// Pranav:
// Pranav:
// struct rlimit RL;
// struct rlimit RL;
...
@@ -112,7 +113,7 @@ int main(int Argc, char *Argv[])
...
@@ -112,7 +113,7 @@ int main(int Argc, char *Argv[])
*/
*/
/* Check for output to be saved to a file */
/* Check for output to be saved to a file */
if
(
Argc
>
2
&&
!
strcmp
(
Argv
[
Argc
-
2
],
"-o"
)
)
if
(
Argc
>
2
&&
!
strcmp
(
Argv
[
Argc
-
2
],
"-o"
)
)
{
{
Of
=
fopen
(
Argv
[
Argc
-
1
],
"w"
);
Of
=
fopen
(
Argv
[
Argc
-
1
],
"w"
);
...
...
This diff is collapsed.
Click to expand it.
c50exact/construct.c
+
1
−
1
View file @
e2c4d536
...
@@ -192,7 +192,7 @@ void ConstructClassifiers()
...
@@ -192,7 +192,7 @@ void ConstructClassifiers()
// Pranav: Turn off pruning
// Pranav: Turn off pruning
//Prune(Pruned[Trial]);
//Prune(Pruned[Trial]);
AdjustAllThresholds
(
Pruned
[
Trial
]);
//
AdjustAllThresholds(Pruned[Trial]);
/* Record tree parameters for later */
/* Record tree parameters for later */
...
...
This diff is collapsed.
Click to expand it.
c50exact/contin.c
+
7
−
3
View file @
e2c4d536
...
@@ -194,7 +194,7 @@ void EvalContinuousAtt(Attribute Att, CaseNo Fp, CaseNo Lp)
...
@@ -194,7 +194,7 @@ void EvalContinuousAtt(Attribute Att, CaseNo Fp, CaseNo Lp)
{
{
Bar
[
Att
]
=
GEnv
.
LowVal
;
Bar
[
Att
]
=
GEnv
.
LowVal
;
}
}
Verbosity
(
2
,
Verbosity
(
2
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f
\n
"
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f
\n
"
,
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
]))
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
]))
...
@@ -367,7 +367,7 @@ void EvalContinuousAttAlg1(Attribute Att, CaseNo Fp, CaseNo Lp)
...
@@ -367,7 +367,7 @@ void EvalContinuousAttAlg1(Attribute Att, CaseNo Fp, CaseNo Lp)
{
{
Bar
[
Att
]
=
GEnv
.
LowVal
;
Bar
[
Att
]
=
GEnv
.
LowVal
;
}
}
Verbosity
(
2
,
Verbosity
(
2
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f
\n
"
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f
\n
"
,
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
]))
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
]))
...
@@ -540,7 +540,7 @@ void EvalContinuousAttAlg2(Attribute Att, CaseNo Fp, CaseNo Lp)
...
@@ -540,7 +540,7 @@ void EvalContinuousAttAlg2(Attribute Att, CaseNo Fp, CaseNo Lp)
{
{
Bar
[
Att
]
=
GEnv
.
LowVal
;
Bar
[
Att
]
=
GEnv
.
LowVal
;
}
}
Verbosity
(
2
,
Verbosity
(
2
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f, penalty %.3f
\n
"
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f, penalty %.3f
\n
"
,
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
],
penalty
))
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
],
penalty
))
...
@@ -912,6 +912,10 @@ void EvalContinuousAttAlg3(Attribute Att, CaseNo Fp, CaseNo Lp)
...
@@ -912,6 +912,10 @@ void EvalContinuousAttAlg3(Attribute Att, CaseNo Fp, CaseNo Lp)
Bar
[
Att
]
=
GEnv
.
LowVal
;
Bar
[
Att
]
=
GEnv
.
LowVal
;
}
}
printf
(
"angello1
\n
"
);
printf
(
"angello Bar: %3f
\n
"
,
Bar
[
Att
]);
printf
(
"angello HighVal
\n
: %3f"
,
GEnv
.
HighVal
);
printf
(
"angello
\n
: %3f"
,
GEnv
.
LowVal
);
Verbosity
(
2
,
Verbosity
(
2
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f
\n
"
,
fprintf
(
Of
,
"
\t
Att %s
\t
cut=%.3f, inf %.3f, gain %.3f
\n
"
,
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
]))
AttName
[
Att
],
Bar
[
Att
],
Info
[
Att
],
Gain
[
Att
]))
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment