@Test
public void testTokenLevelStats2_realCase() throws Exception {

    String result = IOUtils.toString(this.getClass().getResourceAsStream("/sample.wapiti.output.2.txt"), StandardCharsets.UTF_8);
    Stats stats = EvaluationUtilities.tokenLevelStats(result);
    LabelStat conceptualLabelStats = stats.getLabelStat("CONCEPTUAL");
    assertThat(conceptualLabelStats.getObserved(), is(2));
    assertThat(conceptualLabelStats.getExpected(), is(3));
    assertThat(conceptualLabelStats.getFalseNegative(), is(1));
    assertThat(conceptualLabelStats.getFalsePositive(), is(1));
    LabelStat periodLabelStats = stats.getLabelStat("PERIOD");
    assertThat(periodLabelStats.getObserved(), is(8));
    assertThat(periodLabelStats.getExpected(), is(8));
    assertThat(periodLabelStats.getFalseNegative(), is(0));
    assertThat(periodLabelStats.getFalsePositive(), is(0));
    LabelStat mediaLabelStats = stats.getLabelStat("MEDIA");
    assertThat(mediaLabelStats.getObserved(), is(7));
    assertThat(mediaLabelStats.getExpected(), is(7));
    assertThat(mediaLabelStats.getFalseNegative(), is(0));
    assertThat(mediaLabelStats.getFalsePositive(), is(0));
    LabelStat personTypeLabelStats = stats.getLabelStat("PERSON_TYPE");
    assertThat(personTypeLabelStats.getObserved(), is(0));
    assertThat(personTypeLabelStats.getExpected(), is(1));
    assertThat(personTypeLabelStats.getFalseNegative(), is(1));
    assertThat(personTypeLabelStats.getFalsePositive(), is(0));
    LabelStat locationTypeLabelStats = stats.getLabelStat("LOCATION");
    assertThat(locationTypeLabelStats.getObserved(), is(2));
    assertThat(locationTypeLabelStats.getExpected(), is(2));
    assertThat(locationTypeLabelStats.getFalseNegative(), is(0));
    assertThat(locationTypeLabelStats.getFalsePositive(), is(0));
    LabelStat organisationTypeLabelStats = stats.getLabelStat("ORGANISATION");
    assertThat(organisationTypeLabelStats.getObserved(), is(2));
    assertThat(organisationTypeLabelStats.getExpected(), is(2));
    assertThat(organisationTypeLabelStats.getFalseNegative(), is(0));
    assertThat(organisationTypeLabelStats.getFalsePositive(), is(0));
    LabelStat otherLabelStats = stats.getLabelStat("O");
    assertThat(otherLabelStats.getObserved(), is(33));
    assertThat(otherLabelStats.getExpected(), is(34));
    assertThat(otherLabelStats.getFalseNegative(), is(1));
    assertThat(otherLabelStats.getFalsePositive(), is(0));
    LabelStat personLabelStats = stats.getLabelStat("PERSON");
    assertThat(personLabelStats.getObserved(), is(0));
    assertThat(personLabelStats.getExpected(), is(0));
    assertThat(personLabelStats.getFalseNegative(), is(0));
    assertThat(personLabelStats.getFalsePositive(), is(1));
}