TfIdfVectorizer

Description

Vectorizes the input text sequence.

Input

One input:

data: tensor of type int32 or int64.

Output

One output:

y: tensor of type float.

Attribute

max_gram_length: int, maximum n-gram length.

max_skip_count: int, maximum number of skips when constructing n-gram from data.

min_gram_length: int, minimum n-gram length.

mode: string. The weighting criteria. The value can be "TF" (term frequency), "IDF" (inverse document frequency) or "TFIDF" (the combination of TF and IDF).

ngram_counts: int list, start index of n-gram pooling, which helps determine the boundary of two consecutive n-grams.

ngram_indexes: int list. The ith element indicates the coordinate of the ith n-gram in the output tensor.

pool_int64s: int list, indicating the n-grams learned from the training dataset. This parameter and pool_strings cannot be assigned at the same time.

pool_strings: list of strings. Has the same meaning as pool_int64s.

weights: float list, which stores the pooling weight of each n-gram.

ONNX Opset Support

Opset v9/v10/v11/ v12/v13/v14/v15/v16/v17/v18