marf.FeatureExtraction.RandomFeatureExtraction
Class RandomFeatureExtraction

java.lang.Object
  extended by marf.Storage.StorageManager
      extended by marf.FeatureExtraction.FeatureExtraction
          extended by marf.FeatureExtraction.RandomFeatureExtraction.RandomFeatureExtraction
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, IFeatureExtraction, IStorageManager

public class RandomFeatureExtraction
extends FeatureExtraction

Implementation of random feature extraction for testing as a baseline.

$Id: RandomFeatureExtraction.java,v 1.18 2007/12/18 03:45:42 mokhov Exp $

Since:
0.2.0
Version:
$Revision: 1.18 $
Author:
Serguei Mokhov
See Also:
Serialized Form

Field Summary
static int DEFAULT_CHUNK_SIZE
          Default number (256) of doubles per chunk in a feature vector.
 
Fields inherited from class marf.FeatureExtraction.FeatureExtraction
adFeatures, oFeatureSet, oPreprocessing
 
Fields inherited from class marf.Storage.StorageManager
bDumpOnNotFound, iCurrentDumpMode, oObjectToSerialize, strFilename
 
Fields inherited from interface marf.FeatureExtraction.IFeatureExtraction
MARF_INTERFACE_CODE_REVISION
 
Fields inherited from interface marf.Storage.IStorageManager
DUMP_BINARY, DUMP_CSV_TEXT, DUMP_GZIP_BINARY, DUMP_HTML, DUMP_SQL, DUMP_XML, MARF_INTERFACE_CODE_REVISION, STORAGE_FILE_EXTENSIONS
 
Constructor Summary
RandomFeatureExtraction(IPreprocessing poPreprocessing)
          RandomFeatureExtraction Constructor.
 
Method Summary
 boolean extractFeatures()
          Random Gaussian-based feature extraction.
 boolean extractFeatures(double[] padSampleData)
          Extracts features from the provided sample array.
protected  boolean extractFeaturesImplementation(Sample poSample)
          Does the actual business logic of the random Gaussian feature extraction.
static java.lang.String getMARFSourceCodeRevision()
          Returns source code revision information.
 
Methods inherited from class marf.FeatureExtraction.FeatureExtraction
backSynchronizeObject, clone, getFeaturesArray, getPreprocessing, setPreprocessing
 
Methods inherited from class marf.Storage.StorageManager
dump, dumpBinary, dumpCSV, dumpGzipBinary, dumpHTML, dumpSQL, dumpXML, enableDumpOnNotFound, equals, getDefaultExtension, getDefaultExtension, getDumpMode, getFilename, getObjectToSerialize, hashCode, restore, restoreBinary, restoreCSV, restoreGzipBinary, restoreHTML, restoreSQL, restoreXML, setDumpMode, setFilename, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_CHUNK_SIZE

public static final int DEFAULT_CHUNK_SIZE
Default number (256) of doubles per chunk in a feature vector.

See Also:
Constant Field Values
Constructor Detail

RandomFeatureExtraction

public RandomFeatureExtraction(IPreprocessing poPreprocessing)
RandomFeatureExtraction Constructor.

Parameters:
poPreprocessing - Preprocessing object reference
Method Detail

extractFeatures

public final boolean extractFeatures()
                              throws FeatureExtractionException
Random Gaussian-based feature extraction. Sample is taken from an IPreprocessing module from the pipeline.

Specified by:
extractFeatures in interface IFeatureExtraction
Overrides:
extractFeatures in class FeatureExtraction
Returns:
true if successful
Throws:
FeatureExtractionException - in case of any error
See Also:
IFeatureExtraction.extractFeatures()

extractFeatures

public final boolean extractFeatures(double[] padSampleData)
                              throws FeatureExtractionException
Extracts features from the provided sample array.

Parameters:
padSampleData - the sample to extract features from
Returns:
boolean true if there were features extracted, false otherwise
Throws:
FeatureExtractionException - if there was an error while extracting features
Since:
0.3.0.6
See Also:
IFeatureExtraction.extractFeatures(double[])

extractFeaturesImplementation

protected final boolean extractFeaturesImplementation(Sample poSample)
                                               throws FeatureExtractionException
Does the actual business logic of the random Gaussian feature extraction.

Parameters:
poSample - sample to extract features from
Returns:
true if there were features extracted, false otherwise
Throws:
FeatureExtractionException - in case of any errors while doing stuff
Since:
0.3.0.6

getMARFSourceCodeRevision

public static java.lang.String getMARFSourceCodeRevision()
Returns source code revision information.

Returns:
revision string
Since:
0.3.0.2


SourceForge Logo