export#

Modules

modelopt.torch.export.convert_hf_config

Convert modelopt quantization export config to align with llm-compressor config format.

modelopt.torch.export.diffusers_utils

Code that export quantized Hugging Face models for deployment.

modelopt.torch.export.hf_export_handlers

Built-in module handlers for unified Hugging Face export.

modelopt.torch.export.layer_utils

Module-shape predicates and MoE quantizer helpers shared by every export backend.

modelopt.torch.export.layerwise_export

Write each decoder layer's quantized checkpoint shard as soon as it is calibrated.

modelopt.torch.export.model_utils

Utility functions for model type detection and classification.

modelopt.torch.export.moe_utils

Utilities for Mixture-of-Experts (MoE) model export.

modelopt.torch.export.plugins

Export package plugin.

modelopt.torch.export.quant_aware_conversion

Quantization-aware reverse weight conversion for unified HF export.

modelopt.torch.export.quant_format

The quantization and KV-cache format names shared by every export backend.

modelopt.torch.export.quant_utils

Utils for quantization including scaling factors adjustments.

modelopt.torch.export.registry

Registries dispatching per-module logic for the unified HF export path.

modelopt.torch.export.shard_cast_utils

Shared primitives for streaming checkpoint casts and export.

modelopt.torch.export.transformer_engine

Convert the Model Optimizer quantized model to the transformer_engine.

modelopt.torch.export.trtllm

Checkpoint export logic for the TensorRT-LLM specific format.

modelopt.torch.export.unified_export_hf

Code that export quantized Hugging Face models for deployment.

modelopt.torch.export.unified_export_hf_streaming

Streaming HF checkpoint export for disk/CPU-offloaded models.

modelopt.torch.export.unified_export_megatron

Code that export quantized Megatron Core models for deployment.

Export package for Hugging Face and Megatron-based models.