LabelSequence lbls = new LabelSequence (ld, new int [] { 0, 2, 0, 1});
FeatureVectorSequence fvs = new FeatureVectorSequence (vecs);
StringWriter sw = new StringWriter ();
PrintWriter w = new PrintWriter (sw);
Pipe p = new SequencePrintingPipe (w);
// pipe the instance
p.instanceFrom(new Instance (fvs, lbls, null, null));
// Do a second one
FeatureVectorSequence fvs2 = new FeatureVectorSequence (new FeatureVector[] {
new FeatureVector (dict, new int[] { 1 }),
new FeatureVector (dict, new int[] { 0 }),
});
LabelSequence lbls2 = new LabelSequence (ld, new int[] { 2, 1 });
p.instanceFrom(new Instance (fvs2, lbls2, null, null));
w.close();
assertEquals ("LABEL0 feature0 feature1\n" +
"LABEL2 feature0 feature2\n" +