|
Revision 1260, 1.1 kB
(checked in by leo, 5 years ago)
|
|
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Id Date Rev LastChangedBy URL Author
|
| Line | |
|---|
| 1 | |
|---|
| 2 | |
|---|
| 3 | |
|---|
| 4 | |
|---|
| 5 | |
|---|
| 6 | |
|---|
| 7 | |
|---|
| 8 | |
|---|
| 9 | |
|---|
| 10 | package org.xerial.mining.adaboost; |
|---|
| 11 | |
|---|
| 12 | import static org.junit.Assert.*; |
|---|
| 13 | |
|---|
| 14 | import java.io.IOException; |
|---|
| 15 | |
|---|
| 16 | import org.junit.After; |
|---|
| 17 | import org.junit.Before; |
|---|
| 18 | import org.junit.Test; |
|---|
| 19 | import org.xerial.util.FileResource; |
|---|
| 20 | |
|---|
| 21 | public class AdaBoostTest |
|---|
| 22 | { |
|---|
| 23 | |
|---|
| 24 | @Before |
|---|
| 25 | public void setUp() throws Exception |
|---|
| 26 | {} |
|---|
| 27 | |
|---|
| 28 | @After |
|---|
| 29 | public void tearDown() throws Exception |
|---|
| 30 | {} |
|---|
| 31 | |
|---|
| 32 | private String getFile(String fileNameInTestPackage) |
|---|
| 33 | { |
|---|
| 34 | return FileResource.find(AdaBoostTest.class, "sampledata.tab").getFile(); |
|---|
| 35 | } |
|---|
| 36 | |
|---|
| 37 | @Test |
|---|
| 38 | public void run() throws IOException |
|---|
| 39 | { |
|---|
| 40 | AdaBoost adaBoost = new AdaBoost(); |
|---|
| 41 | adaBoost.runPrediction(getFile("sampledata.tab"), getFile("sampledata.tab")); |
|---|
| 42 | } |
|---|
| 43 | |
|---|
| 44 | @Test |
|---|
| 45 | public void testdata() throws IOException |
|---|
| 46 | { |
|---|
| 47 | AdaBoost adaBoost = new AdaBoost(); |
|---|
| 48 | adaBoost.runPrediction(getFile("boolean-test8.txt"), getFile("boolean-test8.txt")); |
|---|
| 49 | } |
|---|
| 50 | |
|---|
| 51 | } |
|---|
| 52 | |
|---|
| 53 | |
|---|
| 54 | |
|---|