For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).
Python class
GraphPipelineModel
GraphPipelineModelโ
class max.pipelines.lib.GraphPipelineModel(pipeline_config, session, devices, kv_cache_config, weights, adapter, return_logits, *, memory_plan, return_hidden_states=ReturnHiddenStates.NONE, max_batch_size=1)
Bases: PipelineModel[BaseContextType, _ModelConfigT, Model]
Graph-API pipeline model without KV cache.
Subclasses implement _build_graph_for_compile() and optionally
_create_model_config() and _wire_batch_processor().
-
Parameters:
-
- pipeline_config (PipelineConfig)
- session (InferenceSession)
- devices (list[Device])
- kv_cache_config (KVCacheConfig)
- weights (Weights)
- adapter (WeightsAdapter | None)
- return_logits (ReturnLogits)
- memory_plan (MemoryPlan)
- return_hidden_states (ReturnHiddenStates)
- max_batch_size (int)
load_model()โ
load_model(session)
Load weights, build the graph, compile, and wire the batch processor.
-
Parameters:
-
session (InferenceSession)
-
Return type: