cc.mallet.fst.tests
Class TestCRF

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by cc.mallet.fst.tests.TestCRF
All Implemented Interfaces:
junit.framework.Test

public class TestCRF
extends junit.framework.TestCase

Tests for CRF training.


Nested Class Summary
 class TestCRF.TestCRF2String
           
static class TestCRF.TestCRFTokenSequenceRemoveSpaces
           
 
Field Summary
static java.lang.String[] data
           
 
Constructor Summary
TestCRF(java.lang.String name)
           
 
Method Summary
 void doTestCost(boolean useSave)
           
 void doTestSpacePrediction(boolean testValueAndGradient)
           
 void doTestSpacePrediction(boolean testValueAndGradient, boolean useSaved, boolean useSparseWeights)
           
static void main(java.lang.String[] args)
           
 void skiptestOldCrf()
           
static junit.framework.Test suite()
           
 void testAddOrderNStates()
           
 void testCopyStatesAndWeights()
           
 void testCost()
           
 void testCostSerialized()
           
 void testDenseFeatureSelection()
           
 void testDenseSerialization()
           
 void testDenseTrain()
           
 void testFrozenWeights()
           
 void testGetSetParameters()
           
 void testIncrement()
           
 void testMaxLattice()
           
 void testPrint()
           
 void testSerialization()
           
 void testStartState()
           
 void testStateAddWeights()
           
 void testSumLattice()
           
 void testSumLatticeImplementations()
           
 void testSumLogProb()
           
 void testTokenAccuracy()
           
 void testTrain()
           
 void testTrainStochasticGradient()
           
 void testValueGradient()
           
 void testXis()
           
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, tearDown, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

data

public static final java.lang.String[] data
Constructor Detail

TestCRF

public TestCRF(java.lang.String name)
Method Detail

testGetSetParameters

public void testGetSetParameters()

testSumLogProb

public void testSumLogProb()

testSumLattice

public void testSumLattice()

testMaxLattice

public void testMaxLattice()

doTestCost

public void doTestCost(boolean useSave)

testCost

public void testCost()

testCostSerialized

public void testCostSerialized()

testIncrement

public void testIncrement()

testValueGradient

public void testValueGradient()

testTrain

public void testTrain()

doTestSpacePrediction

public void doTestSpacePrediction(boolean testValueAndGradient)

doTestSpacePrediction

public void doTestSpacePrediction(boolean testValueAndGradient,
                                  boolean useSaved,
                                  boolean useSparseWeights)

testAddOrderNStates

public void testAddOrderNStates()

testFrozenWeights

public void testFrozenWeights()

testDenseTrain

public void testDenseTrain()

testTrainStochasticGradient

public void testTrainStochasticGradient()

testSumLatticeImplementations

public void testSumLatticeImplementations()

testSerialization

public void testSerialization()

testDenseSerialization

public void testDenseSerialization()

testTokenAccuracy

public void testTokenAccuracy()

testPrint

public void testPrint()

testCopyStatesAndWeights

public void testCopyStatesAndWeights()

testStartState

public void testStartState()

testDenseFeatureSelection

public void testDenseFeatureSelection()

testXis

public void testXis()

suite

public static junit.framework.Test suite()

testStateAddWeights

public void testStateAddWeights()

skiptestOldCrf

public void skiptestOldCrf()

main

public static void main(java.lang.String[] args)