IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /max/get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).

Python class

FrequencyData

FrequencyData

class max.pipelines.sampling.FrequencyData(data, offsets)

source

Bases: object

Container for token frequency data in CSR format.

Parameters:

data

data: Buffer

source

1D array of the column indices of the
non-zero elements in the matrix.
data[:, 1]: 1D array of the non-zero elements in the
matrix.

Type:

data[

Type:

, 0]

offsets

offsets: Buffer

source

shape [batch_size + 1] indicating start of each sequence’s data.

Type:

Row offsets