public static class SparseFloatVector.Factory extends AbstractNumberVector.Factory<SparseFloatVector,Float> implements SparseNumberVector.Factory<SparseFloatVector,Float>
Modifier and Type | Class and Description |
---|---|
static class |
SparseFloatVector.Factory.Parameterizer
Parameterization class.
|
Constructor and Description |
---|
SparseFloatVector.Factory() |
Modifier and Type | Method and Description |
---|---|
ByteBufferSerializer<SparseFloatVector> |
getDefaultSerializer()
Get the default serializer for this type.
|
Class<? super SparseFloatVector> |
getRestrictionClass()
Get the objects type restriction.
|
<A> SparseFloatVector |
newFeatureVector(A array,
ArrayAdapter<Float,A> adapter)
Returns a new FeatureVector of V for the given values.
|
<A> SparseFloatVector |
newNumberVector(A array,
NumberArrayAdapter<?,? super A> adapter)
Instantiate from any number-array like object.
|
SparseFloatVector |
newNumberVector(gnu.trove.map.TIntDoubleMap dvalues,
int maxdim)
Returns a new NumberVector of N for the given values.
|
newNumberVector
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
newNumberVector
public <A> SparseFloatVector newFeatureVector(A array, ArrayAdapter<Float,A> adapter)
FeatureVector.Factory
newFeatureVector
in interface FeatureVector.Factory<SparseFloatVector,Float>
A
- Array typearray
- the values of the featureVectoradapter
- adapter classpublic <A> SparseFloatVector newNumberVector(A array, NumberArrayAdapter<?,? super A> adapter)
NumberVector.Factory
newNumberVector
in interface NumberVector.Factory<SparseFloatVector,Float>
A
- Array typearray
- Arrayadapter
- Adapterpublic SparseFloatVector newNumberVector(gnu.trove.map.TIntDoubleMap dvalues, int maxdim)
SparseNumberVector.Factory
newNumberVector
in interface SparseNumberVector.Factory<SparseFloatVector,Float>
dvalues
- the values of the NumberVectormaxdim
- Maximum dimensionality.public ByteBufferSerializer<SparseFloatVector> getDefaultSerializer()
FeatureVector.Factory
null
when no serializer is available.getDefaultSerializer
in interface FeatureVector.Factory<SparseFloatVector,Float>
public Class<? super SparseFloatVector> getRestrictionClass()
FeatureVector.Factory
getRestrictionClass
in interface FeatureVector.Factory<SparseFloatVector,Float>