nlp
1.2.0
nlp
/
com.londogard.nlp.meachinelearning.transformers
/
Bm25Transformer
Bm25Transformer
public
final
class
Bm25Transformer
implements
Transformer
<
Float
,
Float
>
Content copied to clipboard
Constructors
Functions
Properties
Constructors
Bm25Transformer
Link copied to clipboard
public
Bm25Transformer
Bm25Transformer
(
Integer
k
,
Float
b
)
Content copied to clipboard
Functions
fit
Link copied to clipboard
public
Unit
fit
(
MultiArray
<
Float
,
D2
>
input
)
Content copied to clipboard
fit
Transform
Link copied to clipboard
public
MultiArray
<
Float
,
D2
>
fitTransform
(
MultiArray
<
Float
,
D2
>
input
)
Content copied to clipboard
get
B
Link copied to clipboard
public
final
Float
getB
(
)
Content copied to clipboard
get
Idf
Link copied to clipboard
public
final
NDArray
<
Float
,
D1
>
getIdf
(
)
Content copied to clipboard
get
K
Link copied to clipboard
public
final
Integer
getK
(
)
Content copied to clipboard
set
Idf
Link copied to clipboard
public
final
Unit
setIdf
(
NDArray
<
Float
,
D1
>
idf
)
Content copied to clipboard
transform
Link copied to clipboard
public
D2SparseArray
transform
(
MultiArray
<
Float
,
D2
>
input
)
Content copied to clipboard
Input is a count matrix
Properties
b
Link copied to clipboard
private
final
Float
b
Content copied to clipboard
idf
Link copied to clipboard
private
NDArray
<
Float
,
D1
>
idf
Content copied to clipboard
k
Link copied to clipboard
private
final
Integer
k
Content copied to clipboard