Class CategoricalToIntegerTransform
- java.lang.Object
-
- org.datavec.api.transform.transform.BaseTransform
-
- org.datavec.api.transform.transform.categorical.CategoricalToIntegerTransform
-
public class CategoricalToIntegerTransform extends BaseTransform
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.datavec.api.transform.transform.BaseTransform
inputSchema
-
-
Constructor Summary
Constructors Constructor Description CategoricalToIntegerTransform(String columnName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
canEqual(Object other)
String
columnName()
Returns a singular column name this op is meant to run onString[]
columnNames()
Returns column names this op is meant to run onboolean
equals(Object o)
int
hashCode()
Object
map(Object input)
Transform an object in to another objectList<Writable>
map(List<Writable> writables)
Transform a writable in to another writableObject
mapSequence(Object sequence)
Transform a sequenceString
outputColumnName()
The output column name after the operation has been appliedString[]
outputColumnNames()
The output column names This will often be the same as the inputvoid
setInputSchema(Schema inputSchema)
Set the input schema.Schema
transform(Schema schema)
-
Methods inherited from class org.datavec.api.transform.transform.BaseTransform
getInputSchema, mapSequence, toString
-
-
-
-
Constructor Detail
-
CategoricalToIntegerTransform
public CategoricalToIntegerTransform(String columnName)
-
-
Method Detail
-
setInputSchema
public void setInputSchema(Schema inputSchema)
Description copied from interface:ColumnOp
Set the input schema.- Specified by:
setInputSchema
in interfaceColumnOp
- Overrides:
setInputSchema
in classBaseTransform
-
map
public List<Writable> map(List<Writable> writables)
Description copied from interface:Transform
Transform a writable in to another writable- Parameters:
writables
- the record to transform- Returns:
- the transformed writable
-
map
public Object map(Object input)
Transform an object in to another object- Parameters:
input
- the record to transform- Returns:
- the transformed writable
-
canEqual
protected boolean canEqual(Object other)
-
outputColumnName
public String outputColumnName()
The output column name after the operation has been applied- Returns:
- the output column name
-
outputColumnNames
public String[] outputColumnNames()
The output column names This will often be the same as the input- Returns:
- the output column names
-
columnNames
public String[] columnNames()
Returns column names this op is meant to run on- Returns:
-
columnName
public String columnName()
Returns a singular column name this op is meant to run on- Returns:
-
-