public class LocalityPreservingSemanticAnalysis extends GenericTermDocumentVectorSpace
LSA, but uses a different
reduction of the VSM for the final word representations. This implementation
is based on the following paper. This class offers configurable preprocessing and dimensionality reduction. through two parameters.
"edu.ucla.sspace.lpsa.LocalityPreservingSemanticAnalysis.transform"
Transform. The class should be public, not abstract,
and should provide a public no-arg constructor.
"edu.ucla.sspace.lpsa.LocalityPreservingSemanticAnalysis.dimensions"
300
This class is thread-safe for concurrent calls of processDocument. Once processSpace has been called, no further calls to
processDocument should be made. This implementation does not support
access to the semantic vectors until after processSpace has been
called.
Transform,
LocalityPreservingProjection,
GenericTermDocumentVectorSpace,
LSA| Modifier and Type | Field and Description |
|---|---|
static String |
LPSA_DIMENSIONS_PROPERTY
The property to set the number of dimension to which the space should be
reduced using the SVD
|
static String |
MATRIX_TRANSFORM_PROPERTY
The property to define the
Transform class to be used
when processing the space after all the documents have been seen. |
documentCounter, LOG, wordSpace| Constructor and Description |
|---|
LocalityPreservingSemanticAnalysis(AffinityMatrixCreator creator)
Constructs the
LocalityPreservingSemanticAnalysis using the
system properties for configuration. |
| Modifier and Type | Method and Description |
|---|---|
String |
getSpaceName()
Returns a unique string describing the name and configuration of this
algorithm.
|
void |
processSpace(Properties properties)
Once all the documents have been processed, performs any post-processing
steps on the data.
|
getVector, getVectorLength, getWords, handleDocumentHeader, processDocument, processSpacepublic static final String MATRIX_TRANSFORM_PROPERTY
Transform class to be used
when processing the space after all the documents have been seen.public static final String LPSA_DIMENSIONS_PROPERTY
public LocalityPreservingSemanticAnalysis(AffinityMatrixCreator creator) throws IOException
LocalityPreservingSemanticAnalysis using the
system properties for configuration.IOException - if this instance encounters any errors when creatng
the backing array files required for processingpublic String getSpaceName()
public void processSpace(Properties properties)
properties argument.
By general contract, once this method has been called, processDocument will not be called again.
properties - a set of properties and values that may be used to
configure any exposed parameters of the algorithm. See this class's javadoc for the full list of
supported properties.Copyright © 2012. All Rights Reserved.