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

LoRAInputs

LoRAInputs​

class max.pipelines.lora.LoRAInputs(ids, ranks, grouped_offsets, num_active, end_idx, batch_seq_len, ids_kv, grouped_offsets_kv)

source

Bases: object

Per-batch LoRA buffers passed to a model graph.

Fields are ordered to match the graph’s LoRA input signature. Use buffers() to splice them into a model ABI call.

Parameters:

batch_seq_len​

batch_seq_len: Buffer

source

buffers()​

buffers()

source

Returns the buffers in canonical (field-declaration) order.

Return type:

tuple[Buffer, …]

end_idx​

end_idx: Buffer

source

grouped_offsets​

grouped_offsets: Buffer

source

grouped_offsets_kv​

grouped_offsets_kv: Buffer

source

ids​

ids: Buffer

source

ids_kv​

ids_kv: Buffer

source

num_active​

num_active: Buffer

source

ranks​

ranks: Buffer

source