|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.meapsoft.MEAPFile com.meapsoft.FeatFile
Representation of a MEAPsoft segment/feature file.
Field Summary | |
java.util.Vector |
chunks
|
protected static java.util.regex.Pattern |
commentPattern
|
protected static java.util.regex.Pattern |
featDescPattern
|
java.util.Vector |
featureDescriptions
|
protected static java.util.regex.Pattern |
linePattern
|
Fields inherited from class com.meapsoft.MEAPFile |
filename, haveReadFile, haveWrittenFile |
Constructor Summary | |
protected |
FeatFile()
|
|
FeatFile(java.lang.String fn)
|
Method Summary | |
void |
applyFeatureWeights()
Apply weights (as listed in the "# Features: x.x*FeatureExtractor(ndim)" line ) to the features contained in this file. |
void |
clearChunks()
Remove any chunks in this file |
void |
clearFeatures()
Remove the features of all chunks in this file |
java.lang.Object |
clone()
Clone this FeatFile |
int[] |
getFeatureLengths()
Return the number of elements in each feature i.e. |
double[][] |
getFeatures()
Get a matrix (2D double array) of all of the features in all of the chunks contained in this file. |
double[][] |
getFeatures(int[] featdim)
Get a matrix (2D double array) of all of the features in all of the chunks contained in this file. |
boolean |
isCompatibleWith(FeatFile f)
Check if another FeatFile is compatible with this one. |
void |
normalizeFeatures()
Normalize the features contained in this file such that the feature dimensions corresponding to the outputs of each FeatureExtractor are normalized independently to lie between 0 and 1. |
void |
readFile()
Read in a feature file |
protected void |
write(java.io.Writer w)
Write the contents of this FeatFile |
Methods inherited from class com.meapsoft.MEAPFile |
toString, writeFile, writeFile, writeFile |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public java.util.Vector featureDescriptions
public java.util.Vector chunks
protected static final java.util.regex.Pattern commentPattern
protected static final java.util.regex.Pattern linePattern
protected static final java.util.regex.Pattern featDescPattern
Constructor Detail |
public FeatFile(java.lang.String fn)
protected FeatFile()
Method Detail |
public double[][] getFeatures()
public double[][] getFeatures(int[] featdim)
public int[] getFeatureLengths()
public void normalizeFeatures()
public void applyFeatureWeights()
public void readFile() throws java.io.IOException, ParserException
readFile
in class MEAPFile
java.io.IOException
ParserException
public void clearChunks()
public void clearFeatures()
protected void write(java.io.Writer w) throws java.io.IOException
write
in class MEAPFile
java.io.IOException
public java.lang.Object clone()
public boolean isCompatibleWith(FeatFile f)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |