public static class BagOfWordsVectorizer.Builder
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
isParallel |
protected LabelAwareIterator |
iterator |
protected LabelsSource |
labelsSource |
protected int |
minWordFrequency |
protected java.util.Collection<java.lang.String> |
stopWords |
protected TokenizerFactory |
tokenizerFactory |
protected VocabCache<VocabWord> |
vocabCache |
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
BagOfWordsVectorizer.Builder |
allowParallelTokenization(boolean reallyAllow) |
BagOfWordsVectorizer |
build() |
BagOfWordsVectorizer.Builder |
setIterator(DocumentIterator iterator) |
BagOfWordsVectorizer.Builder |
setIterator(LabelAwareIterator iterator) |
BagOfWordsVectorizer.Builder |
setIterator(SentenceIterator iterator) |
BagOfWordsVectorizer.Builder |
setMinWordFrequency(int minWordFrequency) |
BagOfWordsVectorizer.Builder |
setStopWords(java.util.Collection<java.lang.String> stopWords) |
BagOfWordsVectorizer.Builder |
setTokenizerFactory(TokenizerFactory tokenizerFactory) |
BagOfWordsVectorizer.Builder |
setVocab(VocabCache<VocabWord> vocab) |
protected TokenizerFactory tokenizerFactory
protected LabelAwareIterator iterator
protected int minWordFrequency
protected VocabCache<VocabWord> vocabCache
protected LabelsSource labelsSource
protected java.util.Collection<java.lang.String> stopWords
protected boolean isParallel
public BagOfWordsVectorizer.Builder allowParallelTokenization(boolean reallyAllow)
public BagOfWordsVectorizer.Builder setTokenizerFactory(@NonNull TokenizerFactory tokenizerFactory)
public BagOfWordsVectorizer.Builder setIterator(@NonNull LabelAwareIterator iterator)
public BagOfWordsVectorizer.Builder setIterator(@NonNull DocumentIterator iterator)
public BagOfWordsVectorizer.Builder setIterator(@NonNull SentenceIterator iterator)
public BagOfWordsVectorizer.Builder setVocab(@NonNull VocabCache<VocabWord> vocab)
public BagOfWordsVectorizer.Builder setMinWordFrequency(int minWordFrequency)
public BagOfWordsVectorizer.Builder setStopWords(java.util.Collection<java.lang.String> stopWords)
public BagOfWordsVectorizer build()