Uses of Class
cc.mallet.util.Randoms
-
Packages that use Randoms Package Description cc.mallet.cluster.iterator cc.mallet.cluster.neighbor_evaluator cc.mallet.cluster.util cc.mallet.pipe.iterator Classes that generate instances from different kinds of input or data structures.cc.mallet.topics cc.mallet.types Fundamental MALLET types, including FeatureVector, Instance, Label etc.cc.mallet.util Miscellaneous utilities including command line processing, math functions, lexing, logging. -
-
Uses of Randoms in cc.mallet.cluster.iterator
Fields in cc.mallet.cluster.iterator declared as Randoms Modifier and Type Field Description protected Randoms
PairSampleIterator. random
Methods in cc.mallet.cluster.iterator with parameters of type Randoms Modifier and Type Method Description protected int[]
ClusterSampleIterator. sampleFromArray(int[] a, Randoms random, int minSize)
Samples a subset of elements from this array.protected int[][]
ClusterSampleIterator. sampleSplitFromArray(int[] a, Randoms random, int minSize)
Samples a two disjoint subset of elements from this array.Constructors in cc.mallet.cluster.iterator with parameters of type Randoms Constructor Description ClusterSampleIterator(Clustering clustering, Randoms random, double positiveProportion, int numberSamples)
NodeClusterSampleIterator(Clustering clustering, Randoms random, double positiveProportion, int numberSamples)
PairSampleIterator(Clustering clustering, Randoms random, double positiveProportion, int numberSamples)
-
Uses of Randoms in cc.mallet.cluster.neighbor_evaluator
Constructors in cc.mallet.cluster.neighbor_evaluator with parameters of type Randoms Constructor Description RandomEvaluator(Randoms random)
-
Uses of Randoms in cc.mallet.cluster.util
Methods in cc.mallet.cluster.util with parameters of type Randoms Modifier and Type Method Description static Clustering
ClusterUtils. createRandomClustering(InstanceList instances, Randoms random)
-
Uses of Randoms in cc.mallet.pipe.iterator
Constructors in cc.mallet.pipe.iterator with parameters of type Randoms Constructor Description RandomFeatureVectorIterator(Randoms r, int vocabSize, int numClasses)
RandomFeatureVectorIterator(Randoms r, Alphabet vocab, java.lang.String[] classnames)
RandomFeatureVectorIterator(Randoms r, Dirichlet classCentroidDistribution, double classCentroidAvergeAlphaMean, double classCentroidAvergeAlphaVariance, double featureVectorSizePoissonLambda, double classInstanceCountPoissonLamba, java.lang.String[] classNames)
RandomTokenSequenceIterator(Randoms r, int vocabSize, int numClasses)
RandomTokenSequenceIterator(Randoms r, Alphabet vocab, java.lang.String[] classnames)
RandomTokenSequenceIterator(Randoms r, Dirichlet classCentroidDistribution, double classCentroidAvergeAlphaMean, double classCentroidAvergeAlphaVariance, double featureVectorSizePoissonLambda, double classInstanceCountPoissonLamba, java.lang.String[] classNames)
-
Uses of Randoms in cc.mallet.topics
Fields in cc.mallet.topics declared as Randoms Modifier and Type Field Description protected Randoms
LabeledLDA. random
protected Randoms
LDAHyper. random
Deprecated.protected Randoms
MarginalProbEstimator. random
protected Randoms
NPTopicModel. random
protected Randoms
PolylingualTopicModel. random
protected Randoms
SimpleLDA. random
protected Randoms
TopicInferencer. random
protected Randoms
WeightedTopicModel. random
protected Randoms
WorkerCallable. random
protected Randoms
WorkerRunnable. random
Methods in cc.mallet.topics with parameters of type Randoms Modifier and Type Method Description void
LDA. addDocuments(InstanceList additionalDocuments, int numIterations, int showTopicsInterval, int outputModelInterval, java.lang.String outputModelFilename, Randoms r)
Deprecated.void
HierarchicalPAM. estimate(InstanceList documents, InstanceList testing, int numIterations, int showTopicsInterval, int outputModelInterval, int optimizeInterval, java.lang.String outputModelFilename, Randoms r)
void
LDA. estimate(int docIndexStart, int docIndexLength, int numIterations, int showTopicsInterval, int outputModelInterval, java.lang.String outputModelFilename, Randoms r)
Deprecated.void
LDA. estimate(InstanceList documents, int numIterations, int showTopicsInterval, int outputModelInterval, java.lang.String outputModelFilename, Randoms r)
Deprecated.void
PAM4L. estimate(InstanceList documents, int numIterations, int optimizeInterval, int showTopicsInterval, int outputModelInterval, java.lang.String outputModelFilename, Randoms r)
void
TopicalNGrams. estimate(InstanceList documents, int numIterations, int showTopicsInterval, int outputModelInterval, java.lang.String outputModelFilename, Randoms r)
void
HierarchicalLDA. initialize(InstanceList instances, InstanceList testing, int numLevels, Randoms random)
void
LDA. sampleTopicsForAllDocs(Randoms r)
Deprecated.void
LDA. sampleTopicsForDocs(int start, int length, Randoms r)
Deprecated.void
MarginalProbEstimator. setRandom(Randoms r)
Constructors in cc.mallet.topics with parameters of type Randoms Constructor Description DMRCallable(int numTopics, DMRTopicModel model, double beta, Randoms random, java.util.ArrayList<TopicAssignment> data, int[][] typeTopicCounts, int[] tokensPerTopic, int startDoc, int numDocs)
LDAHyper(int numberOfTopics, double alphaSum, double beta, Randoms random)
Deprecated.LDAHyper(LabelAlphabet topicAlphabet, double alphaSum, double beta, Randoms random)
Deprecated.LDAStream(int numberOfTopics, double alphaSum, double beta, Randoms random)
LDAStream(LabelAlphabet topicAlphabet, double alphaSum, double beta, Randoms random)
NonNegativeMatrixFactorization(InstanceList instances, int numFactors, boolean idfWeighting, Randoms random)
PolylingualTopicModel(int numberOfTopics, double alphaSum, Randoms random)
PolylingualTopicModel(LabelAlphabet topicAlphabet, double alphaSum, Randoms random)
SimpleLDA(int numberOfTopics, double alphaSum, double beta, Randoms random)
SimpleLDA(LabelAlphabet topicAlphabet, double alphaSum, double beta, Randoms random)
WeightedTopicModel(int numberOfTopics, double alphaSum, double beta, Randoms random)
WorkerCallable(int numTopics, double[] alpha, double alphaSum, double beta, Randoms random, java.util.ArrayList<TopicAssignment> data, int[][] typeTopicCounts, int[] tokensPerTopic, int startDoc, int numDocs)
WorkerRunnable(int numTopics, double[] alpha, double alphaSum, double beta, Randoms random, java.util.ArrayList<TopicAssignment> data, int[][] typeTopicCounts, int[] tokensPerTopic, int startDoc, int numDocs)
-
Uses of Randoms in cc.mallet.types
Methods in cc.mallet.types with parameters of type Randoms Modifier and Type Method Description void
InstanceList. hideSomeLabels(double proportionToHide, Randoms r)
Dirichlet
Dirichlet. randomDirichlet(Randoms r, double averageAlpha)
FeatureSequence
Dirichlet. randomFeatureSequence(Randoms r, int length)
FeatureSequence
Multinomial. randomFeatureSequence(Randoms r, int length)
FeatureVector
Dirichlet. randomFeatureVector(Randoms r, int size)
FeatureVector
Multinomial. randomFeatureVector(Randoms r, int size)
int
Multinomial. randomIndex(Randoms r)
Multinomial
Dirichlet. randomMultinomial(Randoms r)
java.lang.Object
Multinomial. randomObject(Randoms r)
protected double[]
Dirichlet. randomRawMultinomial(Randoms r)
TokenSequence
Dirichlet. randomTokenSequence(Randoms r, int length)
double[]
Dirichlet. randomVector(Randoms r)
Constructors in cc.mallet.types with parameters of type Randoms Constructor Description InstanceList(Randoms r, int vocabSize, int numClasses)
InstanceList(Randoms r, Alphabet vocab, java.lang.String[] classNames, int meanInstancesPerLabel)
InstanceList(Randoms r, Dirichlet classCentroidDistribution, double classCentroidAverageAlphaMean, double classCentroidAverageAlphaVariance, double featureVectorSizePoissonLambda, double classInstanceCountPoissonLambda, java.lang.String[] classNames)
Creates a list consisting of randomly-generatedFeatureVector
s. -
Uses of Randoms in cc.mallet.util
Methods in cc.mallet.util with parameters of type Randoms Modifier and Type Method Description static FeatureVector
MVNormal. nextFeatureVector(Alphabet alphabet, double[] mean, double[] precision, Randoms random)
static double[]
MVNormal. nextMVNormal(double[] mean, double[] precision, Randoms random)
Sample a multivariate normal from a precision matrix (ie inverse covariance matrix)static double[][]
MVNormal. nextMVNormal(int n, double[] mean, double[] precision, Randoms random)
static double[]
MVNormal. nextMVNormalPosterior(double[] priorMean, double[] priorPrecisionDiagonal, double[] precision, double[] observedMean, int observations, Randoms random)
static double[]
MVNormal. nextMVNormalWithCholesky(double[] mean, double[] precisionLowerTriangular, Randoms random)
static double[]
MVNormal. nextWishart(double[] sqrtScaleMatrix, int dimension, int degreesOfFreedom, Randoms random)
A Wishart random variate, based on R code by Bill Venables.static double[]
MVNormal. nextWishartPosterior(double[] scatterMatrix, int observations, double[] priorPrecisionDiagonal, int priorDF, int dimension, Randoms random)
static double[]
MVNormal. nextZeroSumMVNormalWithCholesky(double[] mean, double[] precisionLowerTriangular, Randoms random)
Sample a vector x from N(m, (LL')-1, such that sum_i x_i = 0.
-