本文整理汇总了Java中pitt.search.semanticvectors.orthography.NumberRepresentation类的典型用法代码示例。如果您正苦于以下问题:Java NumberRepresentation类的具体用法?Java NumberRepresentation怎么用?Java NumberRepresentation使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
NumberRepresentation类属于pitt.search.semanticvectors.orthography包,在下文中一共展示了NumberRepresentation类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: VectorStoreOrthographical
import pitt.search.semanticvectors.orthography.NumberRepresentation; //导入依赖的package包/类
/**
* Constructs a new vector store with the given arguments, initializing other data structures
* including {@link NumberRepresentation} and {@link StringEdit}.
* @param flagConfig
* @param letterVectors
*/
public VectorStoreOrthographical(FlagConfig flagConfig, VectorStore letterVectors) {
this.flagConfig = flagConfig;
this.letterVectors = letterVectors;
this.objectVectors = new Hashtable<>();
this.theNumbers = new NumberRepresentation(flagConfig);
this.stringVectors = new StringEdit(flagConfig, theNumbers, letterVectors);
}
示例2: initializeNumberRepresentations
import pitt.search.semanticvectors.orthography.NumberRepresentation; //导入依赖的package包/类
/**
* Initialize all number vectors that might be used (i.e. one for each position in the sliding window)
* Used only with {@link PositionalMethod#PROXIMITY}.
*/
private void initializeNumberRepresentations() {
NumberRepresentation numberRepresentation = new NumberRepresentation(flagConfig);
positionalNumberVectors = numberRepresentation.getNumberVectors(1, 2 * flagConfig.windowradius() + 2);
try {
VectorStoreWriter.writeVectorsInLuceneFormat("numbervectors.bin", flagConfig, positionalNumberVectors);
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
示例3: initializeNumberRepresentations
import pitt.search.semanticvectors.orthography.NumberRepresentation; //导入依赖的package包/类
/**
* Initialize all number vectors that might be used (i.e. one for each position in the sliding window)
* Used only with {@link PositionalMethod#PROXIMITY}.
*/
private void initializeNumberRepresentations() {
NumberRepresentation numberRepresentation = new NumberRepresentation(flagConfig);
positionalNumberVectors = numberRepresentation.getNumberVectors(1, 2*flagConfig.windowradius() + 2);
this.initializeDirectionalPermutations();
Enumeration<ObjectVector> VEN = positionalNumberVectors.getAllVectors();
while (VEN.hasMoreElements())
VerbatimLogger.finest("Initialized number representation: " + VEN.nextElement().getObject());
}
示例4: VectorStoreOrthographical
import pitt.search.semanticvectors.orthography.NumberRepresentation; //导入依赖的package包/类
public VectorStoreOrthographical(FlagConfig flagConfig) {
this.flagConfig = flagConfig;
this.objectVectors = new Hashtable<Object, ObjectVector>();
this.theNumbers = new NumberRepresentation(flagConfig);
this.letterVectors = new VectorStoreRAM(flagConfig);
}