#line 1 "/user/cvsspst/ees1cg/RAVL/RAVL-0.7/PatternRec/DataSet/SampleLabel.hh" // This file is part of RAVL, Recognition And Vision Library // Copyright (C) 2001, University of Surrey // This code may be redistributed under the terms of the GNU Lesser // General Public License (LGPL). See the lgpl.licence file for details or // see http://www.gnu.org/copyleft/lesser.html // file-header-ends-here #ifndef RAVL_SAMPLELABEL_HEADER #define RAVL_SAMPLELABEL_HEADER 1 //! rcsid="$Id: SampleLabel.hh,v 1.9 2002/06/13 18:25:15 craftit Exp $" //! author="Kieron Messer" //! docentry="Ravl.Pattern Recognition.Data Set" //! lib=RavlPatternRec //! file="Ravl/PatternRec/DataSet/SampleLabel.hh" #include "Ravl/PatternRec/SampleDiscrete.hh" namespace RavlN { class VectorC; //! userlevel=Normal //: Sample of labels. class SampleLabelC : public SampleDiscreteC { public: SampleLabelC(SizeT maxSize=10) : SampleDiscreteC(maxSize) {} //: Create a sample of data with a maximum size SampleLabelC(const SArray1dC & dat) : SampleDiscreteC(dat) {} //: Create a sample of data from an array SampleLabelC(const SampleC &sample) : SampleDiscreteC(sample) {} //: Construct from base class. UIntT MaxValue() const; //: Find the value of the largest label. SampleC SampleVector(RealT inClass = 1,RealT outClass = 0,IntT maxLabel = -1) const; //: Convert a sample of labels to vectors // Where the label index is set to 'inClass' and the rest to 'outClass'. }; } #endif