Package com.linkedin.feathr.common
Class Hasher
java.lang.Object
com.linkedin.feathr.common.Hasher
Generate hash for a tensor based on column types and values stored in the tensor.
This hash should be same for all tensor instances with same column types and values
even if they are implemented differently under the hood.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintapply(TensorData tensorData, boolean dimOnly) Get hash for tensorData optionally excluding value columnsstatic intgetHash(ReadableTuple readableTuple, int numCols)
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
Hasher
public Hasher()
-
-
Method Details
-
apply
Get hash for tensorData optionally excluding value columns- Parameters:
tensorData- input tensorData for hash is to be computeddimOnly- if true, only dimensions (non-value columns) are use in computation- Returns:
- hash for the tensor
-
getHash
-