vllm-cpu 0.8.5.post2__cp310-cp310-manylinux_2_17_x86_64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of vllm-cpu might be problematic. Click here for more details.
- vllm/_C.abi3.so +0 -0
- vllm/__init__.py +170 -0
- vllm/_custom_ops.py +1536 -0
- vllm/_ipex_ops.py +241 -0
- vllm/_version.py +34 -0
- vllm/adapter_commons/__init__.py +0 -0
- vllm/adapter_commons/layers.py +16 -0
- vllm/adapter_commons/models.py +105 -0
- vllm/adapter_commons/request.py +25 -0
- vllm/adapter_commons/utils.py +92 -0
- vllm/adapter_commons/worker_manager.py +38 -0
- vllm/assets/__init__.py +0 -0
- vllm/assets/audio.py +38 -0
- vllm/assets/base.py +40 -0
- vllm/assets/image.py +31 -0
- vllm/assets/video.py +103 -0
- vllm/attention/__init__.py +19 -0
- vllm/attention/backends/__init__.py +0 -0
- vllm/attention/backends/abstract.py +306 -0
- vllm/attention/backends/blocksparse_attn.py +457 -0
- vllm/attention/backends/cpu_mla.py +303 -0
- vllm/attention/backends/flash_attn.py +999 -0
- vllm/attention/backends/flashinfer.py +1092 -0
- vllm/attention/backends/flashmla.py +242 -0
- vllm/attention/backends/hpu_attn.py +301 -0
- vllm/attention/backends/ipex_attn.py +396 -0
- vllm/attention/backends/mla/__init__.py +0 -0
- vllm/attention/backends/mla/common.py +1444 -0
- vllm/attention/backends/pallas.py +346 -0
- vllm/attention/backends/placeholder_attn.py +399 -0
- vllm/attention/backends/rocm_aiter_mla.py +412 -0
- vllm/attention/backends/rocm_flash_attn.py +969 -0
- vllm/attention/backends/torch_sdpa.py +691 -0
- vllm/attention/backends/triton_mla.py +113 -0
- vllm/attention/backends/utils.py +609 -0
- vllm/attention/backends/xformers.py +798 -0
- vllm/attention/layer.py +443 -0
- vllm/attention/ops/__init__.py +0 -0
- vllm/attention/ops/blocksparse_attention/__init__.py +0 -0
- vllm/attention/ops/blocksparse_attention/blocksparse_attention_kernel.py +432 -0
- vllm/attention/ops/blocksparse_attention/interface.py +238 -0
- vllm/attention/ops/blocksparse_attention/utils.py +244 -0
- vllm/attention/ops/chunked_prefill_paged_decode.py +366 -0
- vllm/attention/ops/flashmla.py +115 -0
- vllm/attention/ops/hpu_paged_attn.py +105 -0
- vllm/attention/ops/ipex_attn.py +193 -0
- vllm/attention/ops/merge_attn_states.py +42 -0
- vllm/attention/ops/nki_flash_attn.py +905 -0
- vllm/attention/ops/paged_attn.py +255 -0
- vllm/attention/ops/prefix_prefill.py +902 -0
- vllm/attention/ops/rocm_aiter_mla.py +42 -0
- vllm/attention/ops/rocm_aiter_paged_attn.py +101 -0
- vllm/attention/ops/triton_decode_attention.py +675 -0
- vllm/attention/ops/triton_flash_attention.py +1375 -0
- vllm/attention/ops/triton_merge_attn_states.py +96 -0
- vllm/attention/selector.py +186 -0
- vllm/attention/utils/fa_utils.py +54 -0
- vllm/beam_search.py +82 -0
- vllm/benchmarks/__init__.py +0 -0
- vllm/benchmarks/datasets.py +831 -0
- vllm/benchmarks/endpoint_request_func.py +160 -0
- vllm/benchmarks/latency.py +181 -0
- vllm/benchmarks/serve.py +925 -0
- vllm/benchmarks/throughput.py +608 -0
- vllm/benchmarks/utils.py +69 -0
- vllm/collect_env.py +795 -0
- vllm/compilation/__init__.py +0 -0
- vllm/compilation/backends.py +715 -0
- vllm/compilation/compiler_interface.py +437 -0
- vllm/compilation/counter.py +33 -0
- vllm/compilation/decorators.py +249 -0
- vllm/compilation/fix_functionalization.py +182 -0
- vllm/compilation/fusion.py +617 -0
- vllm/compilation/fx_utils.py +60 -0
- vllm/compilation/inductor_pass.py +114 -0
- vllm/compilation/monitor.py +38 -0
- vllm/compilation/multi_output_match.py +108 -0
- vllm/compilation/noop_elimination.py +135 -0
- vllm/compilation/pass_manager.py +74 -0
- vllm/compilation/sequence_parallelism.py +266 -0
- vllm/compilation/torch25_custom_graph_pass.py +41 -0
- vllm/compilation/vllm_inductor_pass.py +68 -0
- vllm/compilation/wrapper.py +129 -0
- vllm/config.py +4179 -0
- vllm/connections.py +170 -0
- vllm/core/__init__.py +0 -0
- vllm/core/block/__init__.py +0 -0
- vllm/core/block/block_table.py +398 -0
- vllm/core/block/common.py +370 -0
- vllm/core/block/cpu_gpu_block_allocator.py +440 -0
- vllm/core/block/interfaces.py +318 -0
- vllm/core/block/naive_block.py +465 -0
- vllm/core/block/prefix_caching_block.py +1134 -0
- vllm/core/block/utils.py +27 -0
- vllm/core/block_manager.py +520 -0
- vllm/core/evictor.py +156 -0
- vllm/core/interfaces.py +134 -0
- vllm/core/placeholder_block_space_manager.py +99 -0
- vllm/core/scheduler.py +2060 -0
- vllm/device_allocator/__init__.py +0 -0
- vllm/device_allocator/cumem.py +280 -0
- vllm/distributed/__init__.py +5 -0
- vllm/distributed/communication_op.py +40 -0
- vllm/distributed/device_communicators/__init__.py +0 -0
- vllm/distributed/device_communicators/base_device_communicator.py +151 -0
- vllm/distributed/device_communicators/cpu_communicator.py +139 -0
- vllm/distributed/device_communicators/cuda_communicator.py +131 -0
- vllm/distributed/device_communicators/cuda_wrapper.py +179 -0
- vllm/distributed/device_communicators/custom_all_reduce.py +301 -0
- vllm/distributed/device_communicators/custom_all_reduce_utils.py +257 -0
- vllm/distributed/device_communicators/hpu_communicator.py +45 -0
- vllm/distributed/device_communicators/neuron_communicator.py +19 -0
- vllm/distributed/device_communicators/pynccl.py +217 -0
- vllm/distributed/device_communicators/pynccl_wrapper.py +340 -0
- vllm/distributed/device_communicators/shm_broadcast.py +557 -0
- vllm/distributed/device_communicators/tpu_communicator.py +93 -0
- vllm/distributed/device_communicators/xpu_communicator.py +54 -0
- vllm/distributed/kv_transfer/README.md +29 -0
- vllm/distributed/kv_transfer/__init__.py +11 -0
- vllm/distributed/kv_transfer/disagg_prefill_workflow.jpg +0 -0
- vllm/distributed/kv_transfer/kv_connector/__init__.py +0 -0
- vllm/distributed/kv_transfer/kv_connector/base.py +127 -0
- vllm/distributed/kv_transfer/kv_connector/factory.py +107 -0
- vllm/distributed/kv_transfer/kv_connector/lmcache_connector.py +98 -0
- vllm/distributed/kv_transfer/kv_connector/mooncake_store_connector.py +201 -0
- vllm/distributed/kv_transfer/kv_connector/simple_connector.py +328 -0
- vllm/distributed/kv_transfer/kv_connector/utils.py +90 -0
- vllm/distributed/kv_transfer/kv_connector/v1/__init__.py +8 -0
- vllm/distributed/kv_transfer/kv_connector/v1/base.py +209 -0
- vllm/distributed/kv_transfer/kv_connector/v1/lmcache_connector.py +131 -0
- vllm/distributed/kv_transfer/kv_connector/v1/shared_storage_connector.py +383 -0
- vllm/distributed/kv_transfer/kv_connector_agent.py +76 -0
- vllm/distributed/kv_transfer/kv_lookup_buffer/__init__.py +0 -0
- vllm/distributed/kv_transfer/kv_lookup_buffer/base.py +174 -0
- vllm/distributed/kv_transfer/kv_lookup_buffer/mooncake_store.py +160 -0
- vllm/distributed/kv_transfer/kv_lookup_buffer/simple_buffer.py +236 -0
- vllm/distributed/kv_transfer/kv_pipe/__init__.py +0 -0
- vllm/distributed/kv_transfer/kv_pipe/base.py +66 -0
- vllm/distributed/kv_transfer/kv_pipe/mooncake_pipe.py +279 -0
- vllm/distributed/kv_transfer/kv_pipe/pynccl_pipe.py +279 -0
- vllm/distributed/kv_transfer/kv_transfer_state.py +70 -0
- vllm/distributed/parallel_state.py +1209 -0
- vllm/distributed/utils.py +366 -0
- vllm/engine/__init__.py +0 -0
- vllm/engine/arg_utils.py +1724 -0
- vllm/engine/async_llm_engine.py +1261 -0
- vllm/engine/async_timeout.py +191 -0
- vllm/engine/llm_engine.py +2150 -0
- vllm/engine/metrics.py +717 -0
- vllm/engine/metrics_types.py +96 -0
- vllm/engine/multiprocessing/__init__.py +183 -0
- vllm/engine/multiprocessing/client.py +745 -0
- vllm/engine/multiprocessing/engine.py +450 -0
- vllm/engine/output_processor/__init__.py +0 -0
- vllm/engine/output_processor/interfaces.py +74 -0
- vllm/engine/output_processor/multi_step.py +210 -0
- vllm/engine/output_processor/single_step.py +136 -0
- vllm/engine/output_processor/stop_checker.py +130 -0
- vllm/engine/output_processor/util.py +27 -0
- vllm/engine/protocol.py +302 -0
- vllm/entrypoints/__init__.py +0 -0
- vllm/entrypoints/api_server.py +177 -0
- vllm/entrypoints/chat_utils.py +1259 -0
- vllm/entrypoints/cli/__init__.py +0 -0
- vllm/entrypoints/cli/benchmark/__init__.py +0 -0
- vllm/entrypoints/cli/benchmark/base.py +38 -0
- vllm/entrypoints/cli/benchmark/latency.py +29 -0
- vllm/entrypoints/cli/benchmark/main.py +53 -0
- vllm/entrypoints/cli/benchmark/serve.py +29 -0
- vllm/entrypoints/cli/benchmark/throughput.py +29 -0
- vllm/entrypoints/cli/collect_env.py +35 -0
- vllm/entrypoints/cli/main.py +59 -0
- vllm/entrypoints/cli/openai.py +175 -0
- vllm/entrypoints/cli/serve.py +59 -0
- vllm/entrypoints/cli/types.py +24 -0
- vllm/entrypoints/launcher.py +146 -0
- vllm/entrypoints/llm.py +1450 -0
- vllm/entrypoints/logger.py +44 -0
- vllm/entrypoints/openai/__init__.py +0 -0
- vllm/entrypoints/openai/api_server.py +1130 -0
- vllm/entrypoints/openai/cli_args.py +296 -0
- vllm/entrypoints/openai/logits_processors.py +89 -0
- vllm/entrypoints/openai/protocol.py +1806 -0
- vllm/entrypoints/openai/run_batch.py +439 -0
- vllm/entrypoints/openai/serving_chat.py +1210 -0
- vllm/entrypoints/openai/serving_completion.py +557 -0
- vllm/entrypoints/openai/serving_embedding.py +245 -0
- vllm/entrypoints/openai/serving_engine.py +569 -0
- vllm/entrypoints/openai/serving_models.py +314 -0
- vllm/entrypoints/openai/serving_pooling.py +237 -0
- vllm/entrypoints/openai/serving_score.py +439 -0
- vllm/entrypoints/openai/serving_tokenization.py +147 -0
- vllm/entrypoints/openai/serving_transcription.py +421 -0
- vllm/entrypoints/openai/tool_parsers/__init__.py +19 -0
- vllm/entrypoints/openai/tool_parsers/abstract_tool_parser.py +163 -0
- vllm/entrypoints/openai/tool_parsers/granite_20b_fc_tool_parser.py +254 -0
- vllm/entrypoints/openai/tool_parsers/granite_tool_parser.py +232 -0
- vllm/entrypoints/openai/tool_parsers/hermes_tool_parser.py +370 -0
- vllm/entrypoints/openai/tool_parsers/internlm2_tool_parser.py +211 -0
- vllm/entrypoints/openai/tool_parsers/jamba_tool_parser.py +303 -0
- vllm/entrypoints/openai/tool_parsers/llama_tool_parser.py +262 -0
- vllm/entrypoints/openai/tool_parsers/mistral_tool_parser.py +342 -0
- vllm/entrypoints/openai/tool_parsers/phi4mini_tool_parser.py +110 -0
- vllm/entrypoints/openai/tool_parsers/pythonic_tool_parser.py +292 -0
- vllm/entrypoints/openai/tool_parsers/utils.py +123 -0
- vllm/entrypoints/score_utils.py +49 -0
- vllm/entrypoints/ssl.py +74 -0
- vllm/entrypoints/utils.py +136 -0
- vllm/env_override.py +34 -0
- vllm/envs.py +800 -0
- vllm/executor/__init__.py +0 -0
- vllm/executor/executor_base.py +400 -0
- vllm/executor/mp_distributed_executor.py +243 -0
- vllm/executor/msgspec_utils.py +29 -0
- vllm/executor/multiproc_worker_utils.py +312 -0
- vllm/executor/ray_distributed_executor.py +700 -0
- vllm/executor/ray_utils.py +400 -0
- vllm/executor/uniproc_executor.py +141 -0
- vllm/forward_context.py +159 -0
- vllm/inputs/__init__.py +37 -0
- vllm/inputs/data.py +248 -0
- vllm/inputs/parse.py +121 -0
- vllm/inputs/preprocess.py +745 -0
- vllm/inputs/registry.py +212 -0
- vllm/jsontree.py +79 -0
- vllm/logger.py +210 -0
- vllm/logging_utils/__init__.py +7 -0
- vllm/logging_utils/formatter.py +17 -0
- vllm/logits_process.py +121 -0
- vllm/lora/__init__.py +0 -0
- vllm/lora/fully_sharded_layers.py +335 -0
- vllm/lora/layers.py +1263 -0
- vllm/lora/lora.py +198 -0
- vllm/lora/models.py +802 -0
- vllm/lora/ops/__init__.py +0 -0
- vllm/lora/ops/torch_ops/__init__.py +15 -0
- vllm/lora/ops/torch_ops/lora_ops.py +115 -0
- vllm/lora/ops/triton_ops/__init__.py +11 -0
- vllm/lora/ops/triton_ops/kernel_utils.py +243 -0
- vllm/lora/ops/triton_ops/lora_expand.py +293 -0
- vllm/lora/ops/triton_ops/lora_kernel_metadata.py +147 -0
- vllm/lora/ops/triton_ops/lora_shrink.py +247 -0
- vllm/lora/ops/triton_ops/utils.py +121 -0
- vllm/lora/peft_helper.py +115 -0
- vllm/lora/punica_wrapper/__init__.py +9 -0
- vllm/lora/punica_wrapper/punica_base.py +483 -0
- vllm/lora/punica_wrapper/punica_cpu.py +348 -0
- vllm/lora/punica_wrapper/punica_gpu.py +289 -0
- vllm/lora/punica_wrapper/punica_hpu.py +144 -0
- vllm/lora/punica_wrapper/punica_selector.py +20 -0
- vllm/lora/punica_wrapper/utils.py +161 -0
- vllm/lora/request.py +97 -0
- vllm/lora/resolver.py +83 -0
- vllm/lora/utils.py +237 -0
- vllm/lora/worker_manager.py +251 -0
- vllm/model_executor/__init__.py +15 -0
- vllm/model_executor/custom_op.py +153 -0
- vllm/model_executor/guided_decoding/__init__.py +180 -0
- vllm/model_executor/guided_decoding/guidance_decoding.py +63 -0
- vllm/model_executor/guided_decoding/guidance_logits_processors.py +85 -0
- vllm/model_executor/guided_decoding/guided_fields.py +42 -0
- vllm/model_executor/guided_decoding/lm_format_enforcer_decoding.py +66 -0
- vllm/model_executor/guided_decoding/outlines_decoding.py +154 -0
- vllm/model_executor/guided_decoding/outlines_logits_processors.py +271 -0
- vllm/model_executor/guided_decoding/reasoner/__init__.py +35 -0
- vllm/model_executor/guided_decoding/utils.py +241 -0
- vllm/model_executor/guided_decoding/xgrammar_decoding.py +425 -0
- vllm/model_executor/layers/__init__.py +0 -0
- vllm/model_executor/layers/activation.py +368 -0
- vllm/model_executor/layers/fused_moe/__init__.py +51 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=14336,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=14336,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=1792,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=1792,device_name=NVIDIA_A100-SXM4-80GB.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=3072,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=3072,device_name=NVIDIA_H100_80GB_HBM3,dtype=int8_w8a16.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=3072,device_name=NVIDIA_H100_80GB_HBM3.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=3584,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=3584,device_name=NVIDIA_A100-SXM4-80GB.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=1,N=7168,device_name=NVIDIA_A100-SXM4-80GB.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=1024,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=192,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=192,device_name=NVIDIA_H20.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=192,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=384,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=384,device_name=NVIDIA_H20.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=384,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=384,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=512,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=768,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=768,device_name=NVIDIA_H20.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=768,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=768,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=128,N=96,device_name=NVIDIA_H20.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1024,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1024,device_name=NVIDIA_H100.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1344,device_name=NVIDIA_A100-SXM4-40GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1344,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1344,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=14336,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=14336,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1792,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=1792,device_name=NVIDIA_A100-SXM4-80GB.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=2688,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=2688,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=3072,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=3072,device_name=NVIDIA_H100_80GB_HBM3,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=3200,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +130 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=3584,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=3584,device_name=NVIDIA_A100-SXM4-80GB.json +218 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=6400,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +130 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=7168,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=int8_w8a16.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=16,N=800,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +130 -0
- vllm/model_executor/layers/fused_moe/configs/E=160,N=192,device_name=NVIDIA_A800-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=1024,device_name=AMD_Instinct_MI325X,block_shape=[128,128].json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=1024,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=128,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=256,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=512,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=256,N=64,device_name=NVIDIA_A800-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=60,N=1408,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=60,N=176,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=60,N=352,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=60,N=704,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=1280,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=1280,device_name=NVIDIA_A800-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=1280,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=1280,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=1280,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=1280,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=2560,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=2560,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=2560,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=320,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=320,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=320,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=320,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_A800-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_GeForce_RTX_4090,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=64,N=640,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +138 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=14336,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=16384,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=16384,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=16384,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=16384,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=NVIDIA_A100-SXM4-40GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=1792,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=2048,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_A100-SXM4-40GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_GeForce_RTX_4090,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=3584,device_name=NVIDIA_L40S.json +173 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=4096,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=NVIDIA_A100-SXM4-80GB.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=NVIDIA_H100_80GB_HBM3.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=7168,device_name=NVIDIA_H200.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=8192,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=8192,device_name=AMD_Instinct_MI300X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=8192,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8.json +164 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=8192,device_name=AMD_Instinct_MI325X.json +200 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=8192,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/E=8,N=8192,device_name=NVIDIA_H200,dtype=fp8_w8a8.json +146 -0
- vllm/model_executor/layers/fused_moe/configs/README +12 -0
- vllm/model_executor/layers/fused_moe/cutlass_moe.py +180 -0
- vllm/model_executor/layers/fused_moe/deep_gemm_moe.py +294 -0
- vllm/model_executor/layers/fused_moe/fused_marlin_moe.py +374 -0
- vllm/model_executor/layers/fused_moe/fused_moe.py +1539 -0
- vllm/model_executor/layers/fused_moe/layer.py +949 -0
- vllm/model_executor/layers/fused_moe/moe_align_block_size.py +243 -0
- vllm/model_executor/layers/fused_moe/moe_pallas.py +64 -0
- vllm/model_executor/layers/fused_moe/moe_torch_iterative.py +59 -0
- vllm/model_executor/layers/fused_moe/rocm_aiter_fused_moe.py +416 -0
- vllm/model_executor/layers/fused_moe/utils.py +48 -0
- vllm/model_executor/layers/layernorm.py +277 -0
- vllm/model_executor/layers/lightning_attn.py +651 -0
- vllm/model_executor/layers/linear.py +1518 -0
- vllm/model_executor/layers/logits_processor.py +196 -0
- vllm/model_executor/layers/mamba/__init__.py +0 -0
- vllm/model_executor/layers/mamba/mamba2_metadata.py +109 -0
- vllm/model_executor/layers/mamba/mamba_mixer.py +244 -0
- vllm/model_executor/layers/mamba/mamba_mixer2.py +538 -0
- vllm/model_executor/layers/mamba/ops/__init__.py +0 -0
- vllm/model_executor/layers/mamba/ops/causal_conv1d.py +104 -0
- vllm/model_executor/layers/mamba/ops/mamba_ssm.py +415 -0
- vllm/model_executor/layers/mamba/ops/ssd_bmm.py +261 -0
- vllm/model_executor/layers/mamba/ops/ssd_chunk_scan.py +588 -0
- vllm/model_executor/layers/mamba/ops/ssd_chunk_state.py +750 -0
- vllm/model_executor/layers/mamba/ops/ssd_combined.py +231 -0
- vllm/model_executor/layers/mamba/ops/ssd_state_passing.py +205 -0
- vllm/model_executor/layers/pooler.py +336 -0
- vllm/model_executor/layers/quantization/__init__.py +153 -0
- vllm/model_executor/layers/quantization/aqlm.py +374 -0
- vllm/model_executor/layers/quantization/awq.py +184 -0
- vllm/model_executor/layers/quantization/awq_marlin.py +518 -0
- vllm/model_executor/layers/quantization/awq_triton.py +319 -0
- vllm/model_executor/layers/quantization/base_config.py +145 -0
- vllm/model_executor/layers/quantization/bitblas.py +459 -0
- vllm/model_executor/layers/quantization/bitsandbytes.py +396 -0
- vllm/model_executor/layers/quantization/compressed_tensors/__init__.py +0 -0
- vllm/model_executor/layers/quantization/compressed_tensors/compressed_tensors.py +624 -0
- vllm/model_executor/layers/quantization/compressed_tensors/compressed_tensors_moe.py +1100 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/__init__.py +20 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_24.py +357 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_scheme.py +54 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_w4a16_24.py +159 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_w8a16_fp8.py +119 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_w8a8_fp8.py +149 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_w8a8_int8.py +110 -0
- vllm/model_executor/layers/quantization/compressed_tensors/schemes/compressed_tensors_wNa16.py +200 -0
- vllm/model_executor/layers/quantization/compressed_tensors/triton_scaled_mm.py +205 -0
- vllm/model_executor/layers/quantization/compressed_tensors/utils.py +213 -0
- vllm/model_executor/layers/quantization/deepspeedfp.py +193 -0
- vllm/model_executor/layers/quantization/experts_int8.py +194 -0
- vllm/model_executor/layers/quantization/fbgemm_fp8.py +168 -0
- vllm/model_executor/layers/quantization/fp8.py +832 -0
- vllm/model_executor/layers/quantization/gguf.py +408 -0
- vllm/model_executor/layers/quantization/gptq.py +276 -0
- vllm/model_executor/layers/quantization/gptq_bitblas.py +438 -0
- vllm/model_executor/layers/quantization/gptq_marlin.py +643 -0
- vllm/model_executor/layers/quantization/gptq_marlin_24.py +295 -0
- vllm/model_executor/layers/quantization/hqq_marlin.py +328 -0
- vllm/model_executor/layers/quantization/ipex_quant.py +250 -0
- vllm/model_executor/layers/quantization/kernels/__init__.py +0 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/MPLinearKernel.py +89 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/__init__.py +82 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/allspark.py +115 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/bitblas.py +299 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/exllama.py +142 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/machete.py +119 -0
- vllm/model_executor/layers/quantization/kernels/mixed_precision/marlin.py +132 -0
- vllm/model_executor/layers/quantization/kernels/scaled_mm/ScaledMMLinearKernel.py +66 -0
- vllm/model_executor/layers/quantization/kernels/scaled_mm/__init__.py +86 -0
- vllm/model_executor/layers/quantization/kernels/scaled_mm/aiter.py +119 -0
- vllm/model_executor/layers/quantization/kernels/scaled_mm/cutlass.py +136 -0
- vllm/model_executor/layers/quantization/kernels/scaled_mm/triton.py +40 -0
- vllm/model_executor/layers/quantization/kernels/scaled_mm/xla.py +104 -0
- vllm/model_executor/layers/quantization/kv_cache.py +137 -0
- vllm/model_executor/layers/quantization/marlin.py +259 -0
- vllm/model_executor/layers/quantization/modelopt.py +410 -0
- vllm/model_executor/layers/quantization/moe_wna16.py +447 -0
- vllm/model_executor/layers/quantization/neuron_quant.py +67 -0
- vllm/model_executor/layers/quantization/ptpc_fp8.py +125 -0
- vllm/model_executor/layers/quantization/qqq.py +273 -0
- vllm/model_executor/layers/quantization/quark/__init__.py +0 -0
- vllm/model_executor/layers/quantization/quark/quark.py +385 -0
- vllm/model_executor/layers/quantization/quark/quark_moe.py +236 -0
- vllm/model_executor/layers/quantization/quark/schemes/__init__.py +7 -0
- vllm/model_executor/layers/quantization/quark/schemes/quark_scheme.py +54 -0
- vllm/model_executor/layers/quantization/quark/schemes/quark_w8a8_fp8.py +142 -0
- vllm/model_executor/layers/quantization/quark/schemes/quark_w8a8_int8.py +121 -0
- vllm/model_executor/layers/quantization/quark/utils.py +102 -0
- vllm/model_executor/layers/quantization/schema.py +85 -0
- vllm/model_executor/layers/quantization/torchao.py +127 -0
- vllm/model_executor/layers/quantization/tpu_int8.py +119 -0
- vllm/model_executor/layers/quantization/utils/__init__.py +5 -0
- vllm/model_executor/layers/quantization/utils/allspark_utils.py +51 -0
- vllm/model_executor/layers/quantization/utils/bitblas_utils.py +198 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=1536,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=1536,K=7168,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2048,K=512,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=2304,K=7168,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=24576,K=7168,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=256,K=7168,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=1536,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=3072,K=7168,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=32768,K=512,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=36864,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=36864,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=36864,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=36864,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=36864,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4096,K=512,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=4608,K=7168,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=512,K=7168,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +18 -0
- vllm/model_executor/layers/quantization/utils/configs/N=576,K=7168,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1024,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=1152,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=128,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=16384,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_A100-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_A800-SXM4-80GB,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_H20,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=18432,device_name=NVIDIA_L20Y,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2048,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=NVIDIA_H100_80GB_HBM3,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=2304,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=NVIDIA_B200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=NVIDIA_H20,dtype=int8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=NVIDIA_H200,dtype=fp8_w8a8,block_shape=[128,128].json +146 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=256,device_name=NVIDIA_L20,dtype=fp8_w8a8,block_shape=[128,128].json +26 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=8192,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=8192,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=7168,K=8192,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=8192,K=1536,device_name=AMD_Instinct_MI300X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=8192,K=1536,device_name=AMD_Instinct_MI325X,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/configs/N=8192,K=1536,device_name=AMD_Instinct_MI325_OAM,dtype=fp8_w8a8,block_shape=[128,128].json +164 -0
- vllm/model_executor/layers/quantization/utils/fp8_utils.py +523 -0
- vllm/model_executor/layers/quantization/utils/gptq_utils.py +94 -0
- vllm/model_executor/layers/quantization/utils/int8_utils.py +459 -0
- vllm/model_executor/layers/quantization/utils/layer_utils.py +39 -0
- vllm/model_executor/layers/quantization/utils/machete_utils.py +32 -0
- vllm/model_executor/layers/quantization/utils/marlin_utils.py +413 -0
- vllm/model_executor/layers/quantization/utils/marlin_utils_fp8.py +110 -0
- vllm/model_executor/layers/quantization/utils/marlin_utils_test.py +164 -0
- vllm/model_executor/layers/quantization/utils/marlin_utils_test_24.py +464 -0
- vllm/model_executor/layers/quantization/utils/marlin_utils_test_qqq.py +127 -0
- vllm/model_executor/layers/quantization/utils/quant_utils.py +571 -0
- vllm/model_executor/layers/quantization/utils/w8a8_utils.py +404 -0
- vllm/model_executor/layers/rejection_sampler.py +400 -0
- vllm/model_executor/layers/resampler.py +269 -0
- vllm/model_executor/layers/rotary_embedding.py +1598 -0
- vllm/model_executor/layers/sampler.py +1221 -0
- vllm/model_executor/layers/spec_decode_base_sampler.py +258 -0
- vllm/model_executor/layers/typical_acceptance_sampler.py +172 -0
- vllm/model_executor/layers/utils.py +99 -0
- vllm/model_executor/layers/vocab_parallel_embedding.py +485 -0
- vllm/model_executor/model_loader/__init__.py +20 -0
- vllm/model_executor/model_loader/loader.py +1542 -0
- vllm/model_executor/model_loader/neuron.py +243 -0
- vllm/model_executor/model_loader/tensorizer.py +468 -0
- vllm/model_executor/model_loader/utils.py +171 -0
- vllm/model_executor/model_loader/weight_utils.py +749 -0
- vllm/model_executor/models/__init__.py +27 -0
- vllm/model_executor/models/adapters.py +247 -0
- vllm/model_executor/models/arctic.py +559 -0
- vllm/model_executor/models/aria.py +656 -0
- vllm/model_executor/models/aya_vision.py +461 -0
- vllm/model_executor/models/baichuan.py +469 -0
- vllm/model_executor/models/bamba.py +542 -0
- vllm/model_executor/models/bart.py +936 -0
- vllm/model_executor/models/bert.py +725 -0
- vllm/model_executor/models/blip.py +337 -0
- vllm/model_executor/models/blip2.py +717 -0
- vllm/model_executor/models/bloom.py +358 -0
- vllm/model_executor/models/chameleon.py +1135 -0
- vllm/model_executor/models/chatglm.py +476 -0
- vllm/model_executor/models/clip.py +410 -0
- vllm/model_executor/models/commandr.py +466 -0
- vllm/model_executor/models/constant_size_cache.py +136 -0
- vllm/model_executor/models/dbrx.py +469 -0
- vllm/model_executor/models/deepseek.py +484 -0
- vllm/model_executor/models/deepseek_mtp.py +266 -0
- vllm/model_executor/models/deepseek_v2.py +830 -0
- vllm/model_executor/models/deepseek_vl2.py +647 -0
- vllm/model_executor/models/eagle.py +247 -0
- vllm/model_executor/models/exaone.py +548 -0
- vllm/model_executor/models/fairseq2_llama.py +153 -0
- vllm/model_executor/models/falcon.py +508 -0
- vllm/model_executor/models/florence2.py +1102 -0
- vllm/model_executor/models/fuyu.py +388 -0
- vllm/model_executor/models/gemma.py +423 -0
- vllm/model_executor/models/gemma2.py +423 -0
- vllm/model_executor/models/gemma3.py +531 -0
- vllm/model_executor/models/gemma3_mm.py +716 -0
- vllm/model_executor/models/glm.py +22 -0
- vllm/model_executor/models/glm4.py +303 -0
- vllm/model_executor/models/glm4v.py +647 -0
- vllm/model_executor/models/gpt2.py +313 -0
- vllm/model_executor/models/gpt_bigcode.py +336 -0
- vllm/model_executor/models/gpt_j.py +337 -0
- vllm/model_executor/models/gpt_neox.py +330 -0
- vllm/model_executor/models/granite.py +494 -0
- vllm/model_executor/models/granite_speech.py +777 -0
- vllm/model_executor/models/granitemoe.py +435 -0
- vllm/model_executor/models/granitemoeshared.py +339 -0
- vllm/model_executor/models/gritlm.py +245 -0
- vllm/model_executor/models/grok1.py +560 -0
- vllm/model_executor/models/h2ovl.py +542 -0
- vllm/model_executor/models/idefics2_vision_model.py +387 -0
- vllm/model_executor/models/idefics3.py +767 -0
- vllm/model_executor/models/interfaces.py +569 -0
- vllm/model_executor/models/interfaces_base.py +163 -0
- vllm/model_executor/models/intern_vit.py +476 -0
- vllm/model_executor/models/internlm2.py +453 -0
- vllm/model_executor/models/internlm2_ve.py +146 -0
- vllm/model_executor/models/internvl.py +945 -0
- vllm/model_executor/models/jais.py +371 -0
- vllm/model_executor/models/jamba.py +590 -0
- vllm/model_executor/models/kimi_vl.py +577 -0
- vllm/model_executor/models/llama.py +619 -0
- vllm/model_executor/models/llama4.py +530 -0
- vllm/model_executor/models/llama_eagle.py +152 -0
- vllm/model_executor/models/llama_eagle3.py +232 -0
- vllm/model_executor/models/llava.py +869 -0
- vllm/model_executor/models/llava_next.py +582 -0
- vllm/model_executor/models/llava_next_video.py +470 -0
- vllm/model_executor/models/llava_onevision.py +954 -0
- vllm/model_executor/models/mamba.py +271 -0
- vllm/model_executor/models/mamba2.py +302 -0
- vllm/model_executor/models/mamba_cache.py +76 -0
- vllm/model_executor/models/medusa.py +210 -0
- vllm/model_executor/models/minicpm.py +592 -0
- vllm/model_executor/models/minicpm3.py +229 -0
- vllm/model_executor/models/minicpmo.py +725 -0
- vllm/model_executor/models/minicpmv.py +1287 -0
- vllm/model_executor/models/minimax_cache.py +35 -0
- vllm/model_executor/models/minimax_text_01.py +1261 -0
- vllm/model_executor/models/mistral3.py +598 -0
- vllm/model_executor/models/mixtral.py +485 -0
- vllm/model_executor/models/mixtral_quant.py +447 -0
- vllm/model_executor/models/mllama.py +1623 -0
- vllm/model_executor/models/mllama4.py +838 -0
- vllm/model_executor/models/mlp_speculator.py +205 -0
- vllm/model_executor/models/modernbert.py +325 -0
- vllm/model_executor/models/module_mapping.py +71 -0
- vllm/model_executor/models/molmo.py +1567 -0
- vllm/model_executor/models/moonvit.py +628 -0
- vllm/model_executor/models/mpt.py +329 -0
- vllm/model_executor/models/nemotron.py +506 -0
- vllm/model_executor/models/nemotron_nas.py +446 -0
- vllm/model_executor/models/nvlm_d.py +212 -0
- vllm/model_executor/models/olmo.py +390 -0
- vllm/model_executor/models/olmo2.py +412 -0
- vllm/model_executor/models/olmoe.py +449 -0
- vllm/model_executor/models/opt.py +410 -0
- vllm/model_executor/models/orion.py +356 -0
- vllm/model_executor/models/paligemma.py +397 -0
- vllm/model_executor/models/persimmon.py +342 -0
- vllm/model_executor/models/phi.py +354 -0
- vllm/model_executor/models/phi3.py +18 -0
- vllm/model_executor/models/phi3_small.py +463 -0
- vllm/model_executor/models/phi3v.py +722 -0
- vllm/model_executor/models/phi4mm.py +1263 -0
- vllm/model_executor/models/phi4mm_audio.py +1232 -0
- vllm/model_executor/models/phi4mm_utils.py +1883 -0
- vllm/model_executor/models/phimoe.py +666 -0
- vllm/model_executor/models/pixtral.py +1281 -0
- vllm/model_executor/models/plamo2.py +736 -0
- vllm/model_executor/models/prithvi_geospatial_mae.py +231 -0
- vllm/model_executor/models/qwen.py +360 -0
- vllm/model_executor/models/qwen2.py +552 -0
- vllm/model_executor/models/qwen2_5_omni_thinker.py +901 -0
- vllm/model_executor/models/qwen2_5_vl.py +1136 -0
- vllm/model_executor/models/qwen2_audio.py +402 -0
- vllm/model_executor/models/qwen2_moe.py +531 -0
- vllm/model_executor/models/qwen2_rm.py +130 -0
- vllm/model_executor/models/qwen2_vl.py +1409 -0
- vllm/model_executor/models/qwen3.py +319 -0
- vllm/model_executor/models/qwen3_moe.py +528 -0
- vllm/model_executor/models/qwen_vl.py +784 -0
- vllm/model_executor/models/registry.py +611 -0
- vllm/model_executor/models/roberta.py +332 -0
- vllm/model_executor/models/siglip.py +522 -0
- vllm/model_executor/models/skyworkr1v.py +949 -0
- vllm/model_executor/models/smolvlm.py +51 -0
- vllm/model_executor/models/solar.py +504 -0
- vllm/model_executor/models/stablelm.py +349 -0
- vllm/model_executor/models/starcoder2.py +355 -0
- vllm/model_executor/models/telechat2.py +139 -0
- vllm/model_executor/models/teleflm.py +78 -0
- vllm/model_executor/models/transformers.py +442 -0
- vllm/model_executor/models/ultravox.py +655 -0
- vllm/model_executor/models/utils.py +714 -0
- vllm/model_executor/models/vision.py +149 -0
- vllm/model_executor/models/whisper.py +746 -0
- vllm/model_executor/models/zamba2.py +1008 -0
- vllm/model_executor/parameter.py +458 -0
- vllm/model_executor/pooling_metadata.py +71 -0
- vllm/model_executor/sampling_metadata.py +596 -0
- vllm/model_executor/utils.py +53 -0
- vllm/multimodal/__init__.py +31 -0
- vllm/multimodal/audio.py +105 -0
- vllm/multimodal/base.py +218 -0
- vllm/multimodal/hasher.py +103 -0
- vllm/multimodal/image.py +77 -0
- vllm/multimodal/inputs.py +843 -0
- vllm/multimodal/parse.py +454 -0
- vllm/multimodal/processing.py +1760 -0
- vllm/multimodal/profiling.py +274 -0
- vllm/multimodal/registry.py +321 -0
- vllm/multimodal/utils.py +386 -0
- vllm/multimodal/video.py +166 -0
- vllm/outputs.py +521 -0
- vllm/platforms/__init__.py +286 -0
- vllm/platforms/cpu.py +182 -0
- vllm/platforms/cuda.py +463 -0
- vllm/platforms/hpu.py +94 -0
- vllm/platforms/interface.py +427 -0
- vllm/platforms/neuron.py +69 -0
- vllm/platforms/rocm.py +346 -0
- vllm/platforms/tpu.py +174 -0
- vllm/platforms/xpu.py +142 -0
- vllm/plugins/__init__.py +82 -0
- vllm/pooling_params.py +53 -0
- vllm/profiler/__init__.py +7 -0
- vllm/profiler/layerwise_profile.py +374 -0
- vllm/profiler/utils.py +147 -0
- vllm/prompt_adapter/__init__.py +0 -0
- vllm/prompt_adapter/layers.py +82 -0
- vllm/prompt_adapter/models.py +357 -0
- vllm/prompt_adapter/request.py +36 -0
- vllm/prompt_adapter/utils.py +97 -0
- vllm/prompt_adapter/worker_manager.py +178 -0
- vllm/py.typed +2 -0
- vllm/reasoning/__init__.py +12 -0
- vllm/reasoning/abs_reasoning_parsers.py +189 -0
- vllm/reasoning/deepseek_r1_reasoning_parser.py +172 -0
- vllm/reasoning/granite_reasoning_parser.py +362 -0
- vllm/sampling_params.py +598 -0
- vllm/scalar_type.py +335 -0
- vllm/scripts.py +14 -0
- vllm/sequence.py +1486 -0
- vllm/spec_decode/__init__.py +0 -0
- vllm/spec_decode/batch_expansion.py +505 -0
- vllm/spec_decode/draft_model_runner.py +335 -0
- vllm/spec_decode/interfaces.py +98 -0
- vllm/spec_decode/medusa_worker.py +137 -0
- vllm/spec_decode/metrics.py +212 -0
- vllm/spec_decode/mlp_speculator_worker.py +93 -0
- vllm/spec_decode/mqa_scorer.py +159 -0
- vllm/spec_decode/multi_step_worker.py +416 -0
- vllm/spec_decode/ngram_worker.py +195 -0
- vllm/spec_decode/proposer_worker_base.py +58 -0
- vllm/spec_decode/smaller_tp_proposer_worker.py +194 -0
- vllm/spec_decode/spec_decode_worker.py +1324 -0
- vllm/spec_decode/target_model_runner.py +44 -0
- vllm/spec_decode/top1_proposer.py +274 -0
- vllm/spec_decode/util.py +276 -0
- vllm/test_utils.py +129 -0
- vllm/third_party/__init__.py +0 -0
- vllm/third_party/pynvml.py +6139 -0
- vllm/tracing.py +130 -0
- vllm/transformers_utils/__init__.py +19 -0
- vllm/transformers_utils/config.py +813 -0
- vllm/transformers_utils/configs/__init__.py +52 -0
- vllm/transformers_utils/configs/arctic.py +206 -0
- vllm/transformers_utils/configs/chatglm.py +71 -0
- vllm/transformers_utils/configs/cohere2.py +194 -0
- vllm/transformers_utils/configs/dbrx.py +280 -0
- vllm/transformers_utils/configs/deepseek_vl2.py +216 -0
- vllm/transformers_utils/configs/eagle.py +65 -0
- vllm/transformers_utils/configs/exaone.py +191 -0
- vllm/transformers_utils/configs/falcon.py +89 -0
- vllm/transformers_utils/configs/h2ovl.py +15 -0
- vllm/transformers_utils/configs/internvl.py +53 -0
- vllm/transformers_utils/configs/jais.py +237 -0
- vllm/transformers_utils/configs/kimi_vl.py +36 -0
- vllm/transformers_utils/configs/medusa.py +62 -0
- vllm/transformers_utils/configs/mllama.py +30 -0
- vllm/transformers_utils/configs/mlp_speculator.py +67 -0
- vllm/transformers_utils/configs/moonvit.py +32 -0
- vllm/transformers_utils/configs/mpt.py +179 -0
- vllm/transformers_utils/configs/nemotron.py +204 -0
- vllm/transformers_utils/configs/nvlm_d.py +14 -0
- vllm/transformers_utils/configs/skyworkr1v.py +53 -0
- vllm/transformers_utils/configs/solar.py +246 -0
- vllm/transformers_utils/configs/telechat2.py +63 -0
- vllm/transformers_utils/configs/ultravox.py +107 -0
- vllm/transformers_utils/detokenizer.py +167 -0
- vllm/transformers_utils/detokenizer_utils.py +188 -0
- vllm/transformers_utils/processor.py +210 -0
- vllm/transformers_utils/processors/__init__.py +6 -0
- vllm/transformers_utils/processors/deepseek_vl2.py +363 -0
- vllm/transformers_utils/s3_utils.py +161 -0
- vllm/transformers_utils/tokenizer.py +291 -0
- vllm/transformers_utils/tokenizer_base.py +146 -0
- vllm/transformers_utils/tokenizer_group.py +110 -0
- vllm/transformers_utils/tokenizers/__init__.py +9 -0
- vllm/transformers_utils/tokenizers/mistral.py +483 -0
- vllm/transformers_utils/utils.py +98 -0
- vllm/triton_utils/__init__.py +5 -0
- vllm/triton_utils/importing.py +53 -0
- vllm/usage/__init__.py +0 -0
- vllm/usage/usage_lib.py +255 -0
- vllm/utils.py +2692 -0
- vllm/v1/__init__.py +0 -0
- vllm/v1/attention/__init__.py +0 -0
- vllm/v1/attention/backends/__init__.py +0 -0
- vllm/v1/attention/backends/flash_attn.py +783 -0
- vllm/v1/attention/backends/flashinfer.py +638 -0
- vllm/v1/attention/backends/mla/__init__.py +0 -0
- vllm/v1/attention/backends/mla/common.py +974 -0
- vllm/v1/attention/backends/mla/flashmla.py +149 -0
- vllm/v1/attention/backends/mla/triton_mla.py +118 -0
- vllm/v1/attention/backends/pallas.py +221 -0
- vllm/v1/attention/backends/triton_attn.py +198 -0
- vllm/v1/core/__init__.py +0 -0
- vllm/v1/core/block_pool.py +281 -0
- vllm/v1/core/encoder_cache_manager.py +149 -0
- vllm/v1/core/kv_cache_manager.py +385 -0
- vllm/v1/core/kv_cache_utils.py +744 -0
- vllm/v1/core/sched/__init__.py +0 -0
- vllm/v1/core/sched/interface.py +134 -0
- vllm/v1/core/sched/output.py +126 -0
- vllm/v1/core/sched/scheduler.py +838 -0
- vllm/v1/core/sched/utils.py +22 -0
- vllm/v1/core/specialized_manager.py +161 -0
- vllm/v1/engine/__init__.py +166 -0
- vllm/v1/engine/async_llm.py +532 -0
- vllm/v1/engine/core.py +701 -0
- vllm/v1/engine/core_client.py +942 -0
- vllm/v1/engine/detokenizer.py +260 -0
- vllm/v1/engine/exceptions.py +16 -0
- vllm/v1/engine/llm_engine.py +285 -0
- vllm/v1/engine/logprobs.py +198 -0
- vllm/v1/engine/mm_input_cache.py +82 -0
- vllm/v1/engine/output_processor.py +420 -0
- vllm/v1/engine/parallel_sampling.py +132 -0
- vllm/v1/engine/processor.py +387 -0
- vllm/v1/executor/__init__.py +0 -0
- vllm/v1/executor/abstract.py +112 -0
- vllm/v1/executor/multiproc_executor.py +480 -0
- vllm/v1/executor/ray_distributed_executor.py +61 -0
- vllm/v1/kv_cache_interface.py +166 -0
- vllm/v1/metrics/__init__.py +0 -0
- vllm/v1/metrics/loggers.py +498 -0
- vllm/v1/metrics/stats.py +238 -0
- vllm/v1/outputs.py +111 -0
- vllm/v1/request.py +178 -0
- vllm/v1/sample/__init__.py +0 -0
- vllm/v1/sample/metadata.py +43 -0
- vllm/v1/sample/ops/__init__.py +0 -0
- vllm/v1/sample/ops/bad_words.py +38 -0
- vllm/v1/sample/ops/penalties.py +58 -0
- vllm/v1/sample/ops/topk_topp_sampler.py +315 -0
- vllm/v1/sample/rejection_sampler.py +631 -0
- vllm/v1/sample/sampler.py +270 -0
- vllm/v1/sample/tpu/__init__.py +0 -0
- vllm/v1/sample/tpu/metadata.py +118 -0
- vllm/v1/sample/tpu/sampler.py +154 -0
- vllm/v1/serial_utils.py +274 -0
- vllm/v1/spec_decode/__init__.py +0 -0
- vllm/v1/spec_decode/eagle.py +318 -0
- vllm/v1/spec_decode/metadata.py +61 -0
- vllm/v1/spec_decode/metrics.py +164 -0
- vllm/v1/spec_decode/ngram_proposer.py +131 -0
- vllm/v1/spec_decode/utils.py +18 -0
- vllm/v1/stats/__init__.py +0 -0
- vllm/v1/stats/common.py +453 -0
- vllm/v1/structured_output/__init__.py +113 -0
- vllm/v1/structured_output/backend_guidance.py +215 -0
- vllm/v1/structured_output/backend_types.py +96 -0
- vllm/v1/structured_output/backend_xgrammar.py +299 -0
- vllm/v1/structured_output/request.py +84 -0
- vllm/v1/structured_output/utils.py +174 -0
- vllm/v1/utils.py +249 -0
- vllm/v1/worker/__init__.py +0 -0
- vllm/v1/worker/block_table.py +87 -0
- vllm/v1/worker/gpu_input_batch.py +677 -0
- vllm/v1/worker/gpu_model_runner.py +1776 -0
- vllm/v1/worker/gpu_worker.py +349 -0
- vllm/v1/worker/lora_model_runner_mixin.py +145 -0
- vllm/v1/worker/tpu_model_runner.py +1419 -0
- vllm/v1/worker/tpu_worker.py +260 -0
- vllm/v1/worker/utils.py +74 -0
- vllm/v1/worker/worker_base.py +64 -0
- vllm/version.py +40 -0
- vllm/vllm_flash_attn/.gitkeep +0 -0
- vllm/worker/__init__.py +0 -0
- vllm/worker/cache_engine.py +144 -0
- vllm/worker/cpu_enc_dec_model_runner.py +323 -0
- vllm/worker/cpu_model_runner.py +668 -0
- vllm/worker/cpu_pooling_model_runner.py +122 -0
- vllm/worker/cpu_worker.py +400 -0
- vllm/worker/enc_dec_model_runner.py +542 -0
- vllm/worker/hpu_model_runner.py +2221 -0
- vllm/worker/hpu_worker.py +483 -0
- vllm/worker/model_runner.py +2056 -0
- vllm/worker/model_runner_base.py +281 -0
- vllm/worker/multi_step_hpu_worker.py +122 -0
- vllm/worker/multi_step_model_runner.py +908 -0
- vllm/worker/multi_step_tpu_worker.py +107 -0
- vllm/worker/multi_step_worker.py +196 -0
- vllm/worker/neuron_model_runner.py +336 -0
- vllm/worker/neuron_worker.py +138 -0
- vllm/worker/pooling_model_runner.py +200 -0
- vllm/worker/tpu_model_runner.py +908 -0
- vllm/worker/tpu_worker.py +332 -0
- vllm/worker/utils.py +52 -0
- vllm/worker/worker.py +570 -0
- vllm/worker/worker_base.py +644 -0
- vllm/worker/xpu_model_runner.py +603 -0
- vllm/worker/xpu_worker.py +185 -0
- vllm_cpu-0.8.5.post2.dist-info/METADATA +309 -0
- vllm_cpu-0.8.5.post2.dist-info/RECORD +1103 -0
- vllm_cpu-0.8.5.post2.dist-info/WHEEL +5 -0
- vllm_cpu-0.8.5.post2.dist-info/entry_points.txt +2 -0
- vllm_cpu-0.8.5.post2.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,832 @@
|
|
|
1
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
2
|
+
|
|
3
|
+
import importlib.util
|
|
4
|
+
from typing import Any, Callable, Dict, List, Optional
|
|
5
|
+
|
|
6
|
+
import torch
|
|
7
|
+
import torch.nn.functional as F
|
|
8
|
+
from torch.nn import Module
|
|
9
|
+
from torch.nn.parameter import Parameter
|
|
10
|
+
|
|
11
|
+
import vllm.envs as envs
|
|
12
|
+
from vllm import _custom_ops as ops
|
|
13
|
+
from vllm.distributed import get_tensor_model_parallel_world_size
|
|
14
|
+
from vllm.logger import init_logger
|
|
15
|
+
from vllm.model_executor.layers.fused_moe import (FusedMoE, FusedMoEMethodBase,
|
|
16
|
+
FusedMoeWeightScaleSupported)
|
|
17
|
+
from vllm.model_executor.layers.linear import (LinearBase, LinearMethodBase,
|
|
18
|
+
UnquantizedLinearMethod)
|
|
19
|
+
from vllm.model_executor.layers.quantization.base_config import (
|
|
20
|
+
QuantizationConfig, QuantizeMethodBase)
|
|
21
|
+
from vllm.model_executor.layers.quantization.kv_cache import BaseKVCacheMethod
|
|
22
|
+
from vllm.model_executor.layers.quantization.utils.marlin_utils_fp8 import (
|
|
23
|
+
apply_fp8_marlin_linear, prepare_fp8_layer_for_marlin)
|
|
24
|
+
from vllm.model_executor.layers.quantization.utils.quant_utils import (
|
|
25
|
+
is_layer_skipped)
|
|
26
|
+
from vllm.model_executor.layers.quantization.utils.w8a8_utils import (
|
|
27
|
+
Fp8LinearOp, all_close_1d, convert_to_channelwise,
|
|
28
|
+
cutlass_block_fp8_supported, cutlass_fp8_supported,
|
|
29
|
+
maybe_create_device_identity, normalize_e4m3fn_to_e4m3fnuz,
|
|
30
|
+
per_tensor_dequantize, requantize_with_max_scale)
|
|
31
|
+
from vllm.model_executor.parameter import (BlockQuantScaleParameter,
|
|
32
|
+
ModelWeightParameter,
|
|
33
|
+
PerTensorScaleParameter)
|
|
34
|
+
from vllm.model_executor.utils import set_weight_attrs
|
|
35
|
+
from vllm.platforms import current_platform
|
|
36
|
+
|
|
37
|
+
ACTIVATION_SCHEMES = ["static", "dynamic"]
|
|
38
|
+
|
|
39
|
+
logger = init_logger(__name__)
|
|
40
|
+
|
|
41
|
+
has_deep_gemm = importlib.util.find_spec("deep_gemm") is not None
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def _is_col_major(x: torch.Tensor) -> bool:
|
|
45
|
+
assert x.dim() == 3
|
|
46
|
+
b, m, n = x.shape
|
|
47
|
+
return x.stride(0) == m * n and x.stride(1) == 1 and x.stride(2) == m
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
class Fp8Config(QuantizationConfig):
|
|
51
|
+
"""Config class for FP8."""
|
|
52
|
+
|
|
53
|
+
def __init__(
|
|
54
|
+
self,
|
|
55
|
+
is_checkpoint_fp8_serialized: bool = False,
|
|
56
|
+
activation_scheme: str = "dynamic",
|
|
57
|
+
ignored_layers: Optional[List[str]] = None,
|
|
58
|
+
weight_block_size: Optional[List[int]] = None,
|
|
59
|
+
) -> None:
|
|
60
|
+
super().__init__()
|
|
61
|
+
self.is_checkpoint_fp8_serialized = is_checkpoint_fp8_serialized
|
|
62
|
+
if is_checkpoint_fp8_serialized:
|
|
63
|
+
logger.warning("Detected fp8 checkpoint. Please note that the "
|
|
64
|
+
"format is experimental and subject to change.")
|
|
65
|
+
if activation_scheme not in ACTIVATION_SCHEMES:
|
|
66
|
+
raise ValueError(
|
|
67
|
+
f"Unsupported activation scheme {activation_scheme}")
|
|
68
|
+
self.activation_scheme = activation_scheme
|
|
69
|
+
self.ignored_layers = ignored_layers or []
|
|
70
|
+
if weight_block_size is not None:
|
|
71
|
+
if not is_checkpoint_fp8_serialized:
|
|
72
|
+
raise ValueError(
|
|
73
|
+
"The block-wise quantization only supports fp8-serialized "
|
|
74
|
+
"checkpoint for now.")
|
|
75
|
+
if len(weight_block_size) != 2:
|
|
76
|
+
raise ValueError(
|
|
77
|
+
"The quantization block size of weight must have 2 "
|
|
78
|
+
f"dimensions, but got {len(weight_block_size)} dimensions")
|
|
79
|
+
if activation_scheme != "dynamic":
|
|
80
|
+
raise ValueError("The block-wise quantization only supports "
|
|
81
|
+
"dynamic activation scheme for now, but got "
|
|
82
|
+
f"{activation_scheme} activation scheme.")
|
|
83
|
+
self.weight_block_size = weight_block_size
|
|
84
|
+
|
|
85
|
+
@classmethod
|
|
86
|
+
def get_name(cls) -> str:
|
|
87
|
+
return "fp8"
|
|
88
|
+
|
|
89
|
+
@classmethod
|
|
90
|
+
def get_supported_act_dtypes(cls) -> List[torch.dtype]:
|
|
91
|
+
return [torch.bfloat16, torch.half]
|
|
92
|
+
|
|
93
|
+
@classmethod
|
|
94
|
+
def get_min_capability(cls) -> int:
|
|
95
|
+
return 80
|
|
96
|
+
|
|
97
|
+
@classmethod
|
|
98
|
+
def get_config_filenames(cls) -> List[str]:
|
|
99
|
+
return []
|
|
100
|
+
|
|
101
|
+
@classmethod
|
|
102
|
+
def from_config(cls, config: Dict[str, Any]) -> "Fp8Config":
|
|
103
|
+
quant_method = cls.get_from_keys(config, ["quant_method"])
|
|
104
|
+
is_checkpoint_fp8_serialized = ("fp8" in quant_method)
|
|
105
|
+
activation_scheme = cls.get_from_keys(config, ["activation_scheme"])
|
|
106
|
+
ignored_layers = cls.get_from_keys_or(config, ["ignored_layers"], None)
|
|
107
|
+
weight_block_size = cls.get_from_keys_or(config, ["weight_block_size"],
|
|
108
|
+
None)
|
|
109
|
+
return cls(is_checkpoint_fp8_serialized=is_checkpoint_fp8_serialized,
|
|
110
|
+
activation_scheme=activation_scheme,
|
|
111
|
+
ignored_layers=ignored_layers,
|
|
112
|
+
weight_block_size=weight_block_size)
|
|
113
|
+
|
|
114
|
+
def get_quant_method(self, layer: torch.nn.Module,
|
|
115
|
+
prefix: str) -> Optional["QuantizeMethodBase"]:
|
|
116
|
+
from vllm.attention.layer import Attention # Avoid circular import
|
|
117
|
+
|
|
118
|
+
if isinstance(layer, LinearBase):
|
|
119
|
+
if is_layer_skipped(prefix=prefix,
|
|
120
|
+
ignored_layers=self.ignored_layers,
|
|
121
|
+
fused_mapping=self.packed_modules_mapping):
|
|
122
|
+
return UnquantizedLinearMethod()
|
|
123
|
+
return Fp8LinearMethod(self)
|
|
124
|
+
elif isinstance(layer, FusedMoE):
|
|
125
|
+
return Fp8MoEMethod(self)
|
|
126
|
+
elif isinstance(layer, Attention):
|
|
127
|
+
return Fp8KVCacheMethod(self)
|
|
128
|
+
return None
|
|
129
|
+
|
|
130
|
+
def get_cache_scale(self, name: str) -> Optional[str]:
|
|
131
|
+
"""
|
|
132
|
+
Check whether the param name matches the format for k/v cache scales
|
|
133
|
+
in compressed-tensors. If this is the case, return its equivalent
|
|
134
|
+
param name expected by vLLM
|
|
135
|
+
|
|
136
|
+
:param name: param name
|
|
137
|
+
:return: matching param name for KV cache scale in vLLM
|
|
138
|
+
"""
|
|
139
|
+
if name.endswith(".output_scale") and ".k_proj" in name:
|
|
140
|
+
return name.replace(".k_proj.output_scale", ".attn.k_scale")
|
|
141
|
+
if name.endswith(".output_scale") and ".v_proj" in name:
|
|
142
|
+
return name.replace(".v_proj.output_scale", ".attn.v_scale")
|
|
143
|
+
if name.endswith(".output_scale") and ".q_proj" in name:
|
|
144
|
+
return name.replace(".q_proj.output_scale", ".attn.q_scale")
|
|
145
|
+
if name.endswith("self_attn.prob_output_scale"):
|
|
146
|
+
return name.replace(".prob_output_scale", ".attn.prob_scale")
|
|
147
|
+
# If no matches, return None
|
|
148
|
+
return None
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
class Fp8LinearMethod(LinearMethodBase):
|
|
152
|
+
"""Linear method for FP8.
|
|
153
|
+
Supports loading FP8 checkpoints with static weight scale and
|
|
154
|
+
dynamic/static activation scale.
|
|
155
|
+
|
|
156
|
+
Also supports loading quantized FP16/BF16 model checkpoints with dynamic
|
|
157
|
+
activation scaling. The weight scaling factor will be initialized after
|
|
158
|
+
the model weights are loaded.
|
|
159
|
+
|
|
160
|
+
Limitations:
|
|
161
|
+
1. Only support per-tensor quantization due to torch._scaled_mm support.
|
|
162
|
+
2. Only support float8_e4m3fn data type due to the limitation of
|
|
163
|
+
torch._scaled_mm (https://github.com/pytorch/pytorch/blob/2e48b39603411a41c5025efbe52f89560b827825/aten/src/ATen/native/cuda/Blas.cpp#L854-L856)
|
|
164
|
+
|
|
165
|
+
Args:
|
|
166
|
+
quant_config: The quantization config.
|
|
167
|
+
"""
|
|
168
|
+
|
|
169
|
+
def __init__(self, quant_config: Fp8Config):
|
|
170
|
+
self.quant_config = quant_config
|
|
171
|
+
self.cutlass_block_fp8_supported = cutlass_block_fp8_supported()
|
|
172
|
+
self.out_dtype = torch.get_default_dtype()
|
|
173
|
+
|
|
174
|
+
# For GPUs that lack FP8 hardware support, we can leverage the Marlin
|
|
175
|
+
# kernel for fast weight-only FP8 quantization
|
|
176
|
+
self.use_marlin = (not current_platform.has_device_capability(89)
|
|
177
|
+
or envs.VLLM_TEST_FORCE_FP8_MARLIN)
|
|
178
|
+
# Disable marlin for rocm
|
|
179
|
+
if current_platform.is_rocm():
|
|
180
|
+
self.use_marlin = False
|
|
181
|
+
|
|
182
|
+
self.block_quant = self.quant_config.weight_block_size is not None
|
|
183
|
+
if self.block_quant:
|
|
184
|
+
# Marlin doesn't support block-wise fp8
|
|
185
|
+
self.use_marlin = False
|
|
186
|
+
|
|
187
|
+
self.fp8_linear = Fp8LinearOp(
|
|
188
|
+
# Default to using per_token quantization if cutlass is supported
|
|
189
|
+
use_per_token_if_dynamic=cutlass_fp8_supported())
|
|
190
|
+
|
|
191
|
+
def create_weights(
|
|
192
|
+
self,
|
|
193
|
+
layer: torch.nn.Module,
|
|
194
|
+
input_size_per_partition: int,
|
|
195
|
+
output_partition_sizes: List[int],
|
|
196
|
+
input_size: int,
|
|
197
|
+
output_size: int,
|
|
198
|
+
params_dtype: torch.dtype,
|
|
199
|
+
**extra_weight_attrs,
|
|
200
|
+
):
|
|
201
|
+
maybe_create_device_identity()
|
|
202
|
+
|
|
203
|
+
output_size_per_partition = sum(output_partition_sizes)
|
|
204
|
+
weight_loader = extra_weight_attrs.get("weight_loader")
|
|
205
|
+
|
|
206
|
+
if self.block_quant:
|
|
207
|
+
tp_size = get_tensor_model_parallel_world_size()
|
|
208
|
+
assert self.quant_config.weight_block_size is not None
|
|
209
|
+
block_n, block_k = (
|
|
210
|
+
self.quant_config.weight_block_size[0],
|
|
211
|
+
self.quant_config.weight_block_size[1],
|
|
212
|
+
)
|
|
213
|
+
# Required by row parallel
|
|
214
|
+
if (tp_size > 1
|
|
215
|
+
and input_size // input_size_per_partition == tp_size
|
|
216
|
+
and input_size_per_partition % block_k != 0):
|
|
217
|
+
raise ValueError(
|
|
218
|
+
f"Weight input_size_per_partition = "
|
|
219
|
+
f"{input_size_per_partition} is not divisible by "
|
|
220
|
+
f"weight quantization block_k = {block_k}.")
|
|
221
|
+
# Required by column parallel or enabling merged weights
|
|
222
|
+
if (tp_size > 1 and output_size // output_size_per_partition
|
|
223
|
+
== tp_size) or len(output_partition_sizes) > 1:
|
|
224
|
+
for output_partition_size in output_partition_sizes:
|
|
225
|
+
if output_partition_size % block_n != 0:
|
|
226
|
+
raise ValueError(
|
|
227
|
+
f"Weight output_partition_size = "
|
|
228
|
+
f"{output_partition_size} is not divisible by "
|
|
229
|
+
f"weight quantization block_n = {block_n}.")
|
|
230
|
+
|
|
231
|
+
layer.logical_widths = output_partition_sizes
|
|
232
|
+
|
|
233
|
+
layer.input_size_per_partition = input_size_per_partition
|
|
234
|
+
layer.output_size_per_partition = output_size_per_partition
|
|
235
|
+
layer.orig_dtype = params_dtype
|
|
236
|
+
|
|
237
|
+
# WEIGHT
|
|
238
|
+
weight_dtype = (torch.float8_e4m3fn
|
|
239
|
+
if self.quant_config.is_checkpoint_fp8_serialized else
|
|
240
|
+
params_dtype)
|
|
241
|
+
|
|
242
|
+
weight = ModelWeightParameter(data=torch.empty(
|
|
243
|
+
output_size_per_partition,
|
|
244
|
+
input_size_per_partition,
|
|
245
|
+
dtype=weight_dtype),
|
|
246
|
+
input_dim=1,
|
|
247
|
+
output_dim=0,
|
|
248
|
+
weight_loader=weight_loader)
|
|
249
|
+
layer.register_parameter("weight", weight)
|
|
250
|
+
|
|
251
|
+
# If checkpoint is serialized fp8, load them.
|
|
252
|
+
# Otherwise, wait until process_weights_after_loading.
|
|
253
|
+
if self.quant_config.is_checkpoint_fp8_serialized:
|
|
254
|
+
# WEIGHT SCALE
|
|
255
|
+
if not self.block_quant:
|
|
256
|
+
scale = PerTensorScaleParameter(
|
|
257
|
+
data=torch.empty(len(output_partition_sizes),
|
|
258
|
+
dtype=torch.float32),
|
|
259
|
+
weight_loader=weight_loader,
|
|
260
|
+
)
|
|
261
|
+
scale[:] = torch.finfo(torch.float32).min
|
|
262
|
+
set_weight_attrs(scale, {"scale_type": "weight_scale"})
|
|
263
|
+
layer.register_parameter("weight_scale", scale)
|
|
264
|
+
else:
|
|
265
|
+
assert self.quant_config.activation_scheme == "dynamic"
|
|
266
|
+
scale = BlockQuantScaleParameter(
|
|
267
|
+
data=torch.empty(
|
|
268
|
+
(output_size_per_partition + block_n - 1) // block_n,
|
|
269
|
+
(input_size_per_partition + block_k - 1) // block_k,
|
|
270
|
+
dtype=torch.float32,
|
|
271
|
+
),
|
|
272
|
+
input_dim=1,
|
|
273
|
+
output_dim=0,
|
|
274
|
+
weight_loader=weight_loader,
|
|
275
|
+
)
|
|
276
|
+
scale[:] = torch.finfo(torch.float32).min
|
|
277
|
+
set_weight_attrs(scale, {"scale_type": "weight_scale"})
|
|
278
|
+
# The weight_scale_inv name is intentional for deepseekv3
|
|
279
|
+
layer.register_parameter("weight_scale_inv", scale)
|
|
280
|
+
|
|
281
|
+
# INPUT ACTIVATION SCALE
|
|
282
|
+
if self.quant_config.activation_scheme == "static":
|
|
283
|
+
scale = PerTensorScaleParameter(data=torch.empty(
|
|
284
|
+
len(output_partition_sizes), dtype=torch.float32),
|
|
285
|
+
weight_loader=weight_loader)
|
|
286
|
+
|
|
287
|
+
scale[:] = torch.finfo(torch.float32).min
|
|
288
|
+
set_weight_attrs(scale, {"scale_type": "input_scale"})
|
|
289
|
+
layer.register_parameter("input_scale", scale)
|
|
290
|
+
else:
|
|
291
|
+
layer.register_parameter("input_scale", None)
|
|
292
|
+
|
|
293
|
+
def _maybe_pad_weight(self, weight: torch.Tensor) -> torch.Tensor:
|
|
294
|
+
# Pad the weight tensor. This is an optimization on ROCm platform, which
|
|
295
|
+
# can benefit from tensors located far enough from one another in memory
|
|
296
|
+
if (envs.VLLM_ROCM_FP8_PADDING and current_platform.is_rocm()
|
|
297
|
+
and weight.stride(-1) == 1
|
|
298
|
+
and (weight.stride(-2) * weight.element_size()) % 512 == 0):
|
|
299
|
+
num_pad = 256 // weight.element_size()
|
|
300
|
+
weight = F.pad(weight, (0, num_pad), "constant", 0)[..., :-num_pad]
|
|
301
|
+
torch.cuda.empty_cache()
|
|
302
|
+
return weight
|
|
303
|
+
|
|
304
|
+
def process_weights_after_loading(self, layer: Module) -> None:
|
|
305
|
+
# TODO(rob): refactor block quant into separate class.
|
|
306
|
+
if self.block_quant:
|
|
307
|
+
assert self.quant_config.activation_scheme == "dynamic"
|
|
308
|
+
if current_platform.is_fp8_fnuz():
|
|
309
|
+
weight, weight_scale_inv, _ = \
|
|
310
|
+
normalize_e4m3fn_to_e4m3fnuz(
|
|
311
|
+
weight=layer.weight,
|
|
312
|
+
weight_scale=layer.weight_scale_inv)
|
|
313
|
+
else:
|
|
314
|
+
weight = layer.weight.data
|
|
315
|
+
weight_scale_inv = layer.weight_scale_inv.data
|
|
316
|
+
|
|
317
|
+
weight = self._maybe_pad_weight(weight)
|
|
318
|
+
|
|
319
|
+
# Torch.compile cannot use Parameter subclasses.
|
|
320
|
+
layer.weight = Parameter(weight, requires_grad=False)
|
|
321
|
+
layer.weight_scale_inv = Parameter(weight_scale_inv,
|
|
322
|
+
requires_grad=False)
|
|
323
|
+
return
|
|
324
|
+
|
|
325
|
+
# If checkpoint not serialized fp8, quantize the weights.
|
|
326
|
+
if not self.quant_config.is_checkpoint_fp8_serialized:
|
|
327
|
+
qweight, weight_scale = ops.scaled_fp8_quant(layer.weight,
|
|
328
|
+
scale=None)
|
|
329
|
+
|
|
330
|
+
# If using marlin (w8a16), kernel uses channelwise weights,
|
|
331
|
+
# so extend the weight scales to be channelwise.
|
|
332
|
+
if self.use_marlin:
|
|
333
|
+
assert weight_scale.numel() == 1
|
|
334
|
+
weight_scale = convert_to_channelwise(
|
|
335
|
+
weight_scale.expand(len(layer.logical_widths)),
|
|
336
|
+
layer.logical_widths)
|
|
337
|
+
|
|
338
|
+
# Update the layer with the new values.
|
|
339
|
+
layer.weight = Parameter(qweight.t(), requires_grad=False)
|
|
340
|
+
layer.weight_scale = Parameter(weight_scale, requires_grad=False)
|
|
341
|
+
layer.input_scale = None
|
|
342
|
+
|
|
343
|
+
# If checkpoint is fp8, handle that there are N scales for N
|
|
344
|
+
# shards in a fused module
|
|
345
|
+
else:
|
|
346
|
+
layer.weight_scale = torch.nn.Parameter(layer.weight_scale.data,
|
|
347
|
+
requires_grad=False)
|
|
348
|
+
if self.quant_config.activation_scheme == "static":
|
|
349
|
+
layer.input_scale = torch.nn.Parameter(layer.input_scale.data,
|
|
350
|
+
requires_grad=False)
|
|
351
|
+
# If using marlin (w8a16), kernel uses channelwise weights,
|
|
352
|
+
# so extend the weight scales to be channelwise.
|
|
353
|
+
if self.use_marlin:
|
|
354
|
+
weight = layer.weight
|
|
355
|
+
weight_scale = convert_to_channelwise(layer.weight_scale,
|
|
356
|
+
layer.logical_widths)
|
|
357
|
+
|
|
358
|
+
# If using w8a8, torch._scaled_mm needs per tensor, so
|
|
359
|
+
# requantize the logical shards as a single weight.
|
|
360
|
+
else:
|
|
361
|
+
# Dequant -> Quant with max scale so we can run per tensor.
|
|
362
|
+
weight = layer.weight
|
|
363
|
+
weight_scale = layer.weight_scale
|
|
364
|
+
|
|
365
|
+
if current_platform.is_fp8_fnuz():
|
|
366
|
+
weight, weight_scale, input_scale = \
|
|
367
|
+
normalize_e4m3fn_to_e4m3fnuz(
|
|
368
|
+
weight=weight,
|
|
369
|
+
weight_scale=weight_scale,
|
|
370
|
+
input_scale=layer.input_scale)
|
|
371
|
+
if input_scale is not None:
|
|
372
|
+
layer.input_scale = Parameter(input_scale,
|
|
373
|
+
requires_grad=False)
|
|
374
|
+
|
|
375
|
+
weight_scale, weight = requantize_with_max_scale(
|
|
376
|
+
weight=weight,
|
|
377
|
+
weight_scale=weight_scale,
|
|
378
|
+
logical_widths=layer.logical_widths,
|
|
379
|
+
)
|
|
380
|
+
|
|
381
|
+
weight = self._maybe_pad_weight(weight)
|
|
382
|
+
# Update layer with new values.
|
|
383
|
+
layer.weight = Parameter(weight.t(), requires_grad=False)
|
|
384
|
+
layer.weight_scale = Parameter(weight_scale, requires_grad=False)
|
|
385
|
+
if self.quant_config.activation_scheme == "static":
|
|
386
|
+
layer.input_scale = Parameter(layer.input_scale.max(),
|
|
387
|
+
requires_grad=False)
|
|
388
|
+
|
|
389
|
+
if self.use_marlin:
|
|
390
|
+
prepare_fp8_layer_for_marlin(layer)
|
|
391
|
+
# Activations not quantized for marlin.
|
|
392
|
+
del layer.input_scale
|
|
393
|
+
|
|
394
|
+
def apply(self,
|
|
395
|
+
layer: torch.nn.Module,
|
|
396
|
+
x: torch.Tensor,
|
|
397
|
+
bias: Optional[torch.Tensor] = None) -> torch.Tensor:
|
|
398
|
+
|
|
399
|
+
if self.use_marlin:
|
|
400
|
+
return apply_fp8_marlin_linear(
|
|
401
|
+
input=x,
|
|
402
|
+
weight=layer.weight,
|
|
403
|
+
weight_scale=layer.weight_scale,
|
|
404
|
+
workspace=layer.workspace,
|
|
405
|
+
size_n=layer.output_size_per_partition,
|
|
406
|
+
size_k=layer.input_size_per_partition,
|
|
407
|
+
bias=bias)
|
|
408
|
+
|
|
409
|
+
if self.block_quant:
|
|
410
|
+
assert self.quant_config.weight_block_size is not None
|
|
411
|
+
return torch.ops.vllm.apply_w8a8_block_fp8_linear(
|
|
412
|
+
input=x,
|
|
413
|
+
weight=layer.weight,
|
|
414
|
+
block_size=self.quant_config.weight_block_size,
|
|
415
|
+
weight_scale=layer.weight_scale_inv,
|
|
416
|
+
input_scale=layer.input_scale,
|
|
417
|
+
bias=bias,
|
|
418
|
+
cutlass_block_fp8_supported=self.cutlass_block_fp8_supported,
|
|
419
|
+
)
|
|
420
|
+
|
|
421
|
+
return self.fp8_linear.apply(input=x,
|
|
422
|
+
weight=layer.weight,
|
|
423
|
+
weight_scale=layer.weight_scale,
|
|
424
|
+
out_dtype=self.out_dtype,
|
|
425
|
+
input_scale=layer.input_scale,
|
|
426
|
+
bias=bias)
|
|
427
|
+
|
|
428
|
+
|
|
429
|
+
class Fp8MoEMethod(FusedMoEMethodBase):
|
|
430
|
+
"""MoE method for FP8.
|
|
431
|
+
Supports loading FP8 checkpoints with static weight scale and
|
|
432
|
+
dynamic/static activation scale.
|
|
433
|
+
|
|
434
|
+
Also supports loading quantized FP16/BF16 model checkpoints with dynamic
|
|
435
|
+
activation scaling. The weight scaling factor will be initialized after
|
|
436
|
+
the model weights are loaded.
|
|
437
|
+
|
|
438
|
+
Args:
|
|
439
|
+
quant_config: The quantization config.
|
|
440
|
+
"""
|
|
441
|
+
|
|
442
|
+
def __init__(self, quant_config: Fp8Config):
|
|
443
|
+
self.quant_config = quant_config
|
|
444
|
+
self.block_quant = self.quant_config.weight_block_size is not None
|
|
445
|
+
|
|
446
|
+
# Check for DeepGemm support.
|
|
447
|
+
self.allow_deep_gemm = False
|
|
448
|
+
if envs.VLLM_USE_DEEP_GEMM:
|
|
449
|
+
if not has_deep_gemm:
|
|
450
|
+
logger.warning_once("Failed to import DeepGemm kernels.")
|
|
451
|
+
elif (current_platform.is_cuda()
|
|
452
|
+
and current_platform.has_device_capability(90)):
|
|
453
|
+
logger.info_once("Using DeepGemm kernels for Fp8MoEMethod.")
|
|
454
|
+
self.allow_deep_gemm = True
|
|
455
|
+
else:
|
|
456
|
+
logger.warning_once(
|
|
457
|
+
"DeepGemm not supported on the current platform.")
|
|
458
|
+
|
|
459
|
+
def create_weights(self, layer: Module, num_experts: int, hidden_size: int,
|
|
460
|
+
intermediate_size_per_partition: int,
|
|
461
|
+
params_dtype: torch.dtype, **extra_weight_attrs):
|
|
462
|
+
|
|
463
|
+
if self.quant_config.is_checkpoint_fp8_serialized:
|
|
464
|
+
params_dtype = torch.float8_e4m3fn
|
|
465
|
+
if self.block_quant:
|
|
466
|
+
assert self.quant_config.weight_block_size is not None
|
|
467
|
+
tp_size = get_tensor_model_parallel_world_size()
|
|
468
|
+
block_n, block_k = (
|
|
469
|
+
self.quant_config.weight_block_size[0],
|
|
470
|
+
self.quant_config.weight_block_size[1],
|
|
471
|
+
)
|
|
472
|
+
# NOTE: To ensure proper alignment of the block-wise quantization
|
|
473
|
+
# scales, the output_size of the weights for both the gate and up
|
|
474
|
+
# layers must be divisible by block_n.
|
|
475
|
+
# Required by column parallel or enabling merged weights
|
|
476
|
+
if intermediate_size_per_partition % block_n != 0:
|
|
477
|
+
raise ValueError(
|
|
478
|
+
f"The output_size of gate's and up's weight = "
|
|
479
|
+
f"{intermediate_size_per_partition} is not divisible by "
|
|
480
|
+
f"weight quantization block_n = {block_n}.")
|
|
481
|
+
if (tp_size > 1
|
|
482
|
+
and intermediate_size_per_partition % block_k != 0):
|
|
483
|
+
# Required by row parallel
|
|
484
|
+
raise ValueError(
|
|
485
|
+
f"The input_size of down's weight = "
|
|
486
|
+
f"{intermediate_size_per_partition} is not divisible by "
|
|
487
|
+
f"weight quantization block_k = {block_k}.")
|
|
488
|
+
|
|
489
|
+
# WEIGHTS
|
|
490
|
+
w13_weight = torch.nn.Parameter(torch.empty(
|
|
491
|
+
num_experts,
|
|
492
|
+
2 * intermediate_size_per_partition,
|
|
493
|
+
hidden_size,
|
|
494
|
+
dtype=params_dtype),
|
|
495
|
+
requires_grad=False)
|
|
496
|
+
layer.register_parameter("w13_weight", w13_weight)
|
|
497
|
+
set_weight_attrs(w13_weight, extra_weight_attrs)
|
|
498
|
+
|
|
499
|
+
w2_weight = torch.nn.Parameter(torch.empty(
|
|
500
|
+
num_experts,
|
|
501
|
+
hidden_size,
|
|
502
|
+
intermediate_size_per_partition,
|
|
503
|
+
dtype=params_dtype),
|
|
504
|
+
requires_grad=False)
|
|
505
|
+
layer.register_parameter("w2_weight", w2_weight)
|
|
506
|
+
set_weight_attrs(w2_weight, extra_weight_attrs)
|
|
507
|
+
|
|
508
|
+
# WEIGHT_SCALES
|
|
509
|
+
if not self.block_quant:
|
|
510
|
+
# Allocate 2 scales for w1 and w3 respectively.
|
|
511
|
+
# They will be combined to a single scale after weight loading.
|
|
512
|
+
w13_weight_scale = torch.nn.Parameter(torch.ones(
|
|
513
|
+
num_experts, 2, dtype=torch.float32),
|
|
514
|
+
requires_grad=False)
|
|
515
|
+
w2_weight_scale = torch.nn.Parameter(torch.ones(
|
|
516
|
+
num_experts, dtype=torch.float32),
|
|
517
|
+
requires_grad=False)
|
|
518
|
+
layer.register_parameter("w13_weight_scale", w13_weight_scale)
|
|
519
|
+
layer.register_parameter("w2_weight_scale", w2_weight_scale)
|
|
520
|
+
else:
|
|
521
|
+
w13_weight_scale = torch.nn.Parameter(
|
|
522
|
+
torch.ones(
|
|
523
|
+
num_experts,
|
|
524
|
+
2 * ((intermediate_size_per_partition + block_n - 1) //
|
|
525
|
+
block_n),
|
|
526
|
+
(hidden_size + block_k - 1) // block_k,
|
|
527
|
+
dtype=torch.float32,
|
|
528
|
+
),
|
|
529
|
+
requires_grad=False,
|
|
530
|
+
)
|
|
531
|
+
w2_weight_scale = torch.nn.Parameter(
|
|
532
|
+
torch.ones(
|
|
533
|
+
num_experts,
|
|
534
|
+
(hidden_size + block_n - 1) // block_n,
|
|
535
|
+
(intermediate_size_per_partition + block_k - 1) // block_k,
|
|
536
|
+
dtype=torch.float32,
|
|
537
|
+
),
|
|
538
|
+
requires_grad=False,
|
|
539
|
+
)
|
|
540
|
+
layer.register_parameter("w13_weight_scale_inv", w13_weight_scale)
|
|
541
|
+
layer.register_parameter("w2_weight_scale_inv", w2_weight_scale)
|
|
542
|
+
assert self.quant_config.activation_scheme == "dynamic"
|
|
543
|
+
|
|
544
|
+
# Add the quantization method used (per tensor/grouped/channel)
|
|
545
|
+
# to ensure the weight scales are loaded in properly
|
|
546
|
+
extra_weight_attrs.update(
|
|
547
|
+
{"quant_method": FusedMoeWeightScaleSupported.BLOCK.
|
|
548
|
+
value} if self.block_quant else
|
|
549
|
+
{"quant_method": FusedMoeWeightScaleSupported.TENSOR.value})
|
|
550
|
+
# If loading fp8 checkpoint, pass the weight loaders.
|
|
551
|
+
# If loading an fp16 checkpoint, do not (we will quantize in
|
|
552
|
+
# process_weights_after_loading()
|
|
553
|
+
if self.quant_config.is_checkpoint_fp8_serialized:
|
|
554
|
+
set_weight_attrs(w13_weight_scale, extra_weight_attrs)
|
|
555
|
+
set_weight_attrs(w2_weight_scale, extra_weight_attrs)
|
|
556
|
+
|
|
557
|
+
# INPUT_SCALES
|
|
558
|
+
if self.quant_config.activation_scheme == "static":
|
|
559
|
+
if not self.quant_config.is_checkpoint_fp8_serialized:
|
|
560
|
+
raise ValueError(
|
|
561
|
+
"Found static activation scheme for checkpoint that "
|
|
562
|
+
"was not serialized fp8.")
|
|
563
|
+
|
|
564
|
+
w13_input_scale = torch.nn.Parameter(torch.ones(
|
|
565
|
+
num_experts, dtype=torch.float32),
|
|
566
|
+
requires_grad=False)
|
|
567
|
+
layer.register_parameter("w13_input_scale", w13_input_scale)
|
|
568
|
+
set_weight_attrs(w13_input_scale, extra_weight_attrs)
|
|
569
|
+
|
|
570
|
+
w2_input_scale = torch.nn.Parameter(torch.ones(
|
|
571
|
+
num_experts, dtype=torch.float32),
|
|
572
|
+
requires_grad=False)
|
|
573
|
+
layer.register_parameter("w2_input_scale", w2_input_scale)
|
|
574
|
+
set_weight_attrs(w2_input_scale, extra_weight_attrs)
|
|
575
|
+
|
|
576
|
+
else:
|
|
577
|
+
layer.w13_input_scale = None
|
|
578
|
+
layer.w2_input_scale = None
|
|
579
|
+
|
|
580
|
+
def process_weights_after_loading(self, layer: Module) -> None:
|
|
581
|
+
# Lazy import to avoid importing triton too early.
|
|
582
|
+
from vllm.model_executor.layers.fused_moe.rocm_aiter_fused_moe import (
|
|
583
|
+
expand_weights, is_rocm_aiter_moe_enabled, shuffle_weights)
|
|
584
|
+
|
|
585
|
+
# TODO (rob): refactor block quant into separate class.
|
|
586
|
+
if self.block_quant:
|
|
587
|
+
assert self.quant_config.activation_scheme == "dynamic"
|
|
588
|
+
if current_platform.is_fp8_fnuz():
|
|
589
|
+
w13_weight, w13_weight_scale_inv, w13_input_scale = \
|
|
590
|
+
normalize_e4m3fn_to_e4m3fnuz(
|
|
591
|
+
layer.w13_weight, layer.w13_weight_scale_inv,
|
|
592
|
+
layer.w13_input_scale)
|
|
593
|
+
w2_weight, w2_weight_scale_inv, w2_input_scale = \
|
|
594
|
+
normalize_e4m3fn_to_e4m3fnuz(
|
|
595
|
+
layer.w2_weight, layer.w2_weight_scale_inv,
|
|
596
|
+
layer.w2_input_scale)
|
|
597
|
+
else:
|
|
598
|
+
w13_weight = layer.w13_weight.data
|
|
599
|
+
w13_weight_scale_inv = layer.w13_weight_scale_inv.data
|
|
600
|
+
w2_weight = layer.w2_weight
|
|
601
|
+
w2_weight_scale_inv = layer.w2_weight_scale_inv
|
|
602
|
+
|
|
603
|
+
# torch.compile() cannot use Parameter subclasses.
|
|
604
|
+
layer.w13_weight = Parameter(w13_weight, requires_grad=False)
|
|
605
|
+
layer.w13_weight_scale_inv = Parameter(w13_weight_scale_inv,
|
|
606
|
+
requires_grad=False)
|
|
607
|
+
layer.w2_weight = Parameter(w2_weight, requires_grad=False)
|
|
608
|
+
layer.w2_weight_scale_inv = Parameter(w2_weight_scale_inv,
|
|
609
|
+
requires_grad=False)
|
|
610
|
+
if is_rocm_aiter_moe_enabled():
|
|
611
|
+
# reshaping weights is required for aiter moe kernel.
|
|
612
|
+
shuffled_w13, shuffled_w2 = shuffle_weights(
|
|
613
|
+
layer.w13_weight.data, layer.w2_weight.data)
|
|
614
|
+
|
|
615
|
+
layer.w13_weight = torch.nn.Parameter(shuffled_w13,
|
|
616
|
+
requires_grad=False)
|
|
617
|
+
layer.w2_weight = torch.nn.Parameter(shuffled_w2,
|
|
618
|
+
requires_grad=False)
|
|
619
|
+
|
|
620
|
+
# DeepGemm scales need to be transposed and aligned. We try to do
|
|
621
|
+
# it ahead of time for performance reasons.
|
|
622
|
+
if self.allow_deep_gemm:
|
|
623
|
+
# Lazy import to avoid CUDA initialization problems.
|
|
624
|
+
import deep_gemm as dg
|
|
625
|
+
if _is_col_major(layer.w13_weight_scale_inv):
|
|
626
|
+
layer.w13_weight_scale_inv = \
|
|
627
|
+
dg.get_col_major_tma_aligned_tensor(layer.w13_weight_scale_inv).contiguous()
|
|
628
|
+
if _is_col_major(layer.w2_weight_scale_inv):
|
|
629
|
+
layer.w2_weight_scale_inv = \
|
|
630
|
+
dg.get_col_major_tma_aligned_tensor(layer.w2_weight_scale_inv).contiguous()
|
|
631
|
+
|
|
632
|
+
return
|
|
633
|
+
|
|
634
|
+
# If checkpoint is fp16, quantize in place.
|
|
635
|
+
if not self.quant_config.is_checkpoint_fp8_serialized:
|
|
636
|
+
fp8_dtype = current_platform.fp8_dtype()
|
|
637
|
+
w13_weight = torch.empty_like(layer.w13_weight.data,
|
|
638
|
+
dtype=fp8_dtype)
|
|
639
|
+
w2_weight = torch.empty_like(layer.w2_weight.data, dtype=fp8_dtype)
|
|
640
|
+
|
|
641
|
+
# Re-initialize w13_scale because we directly quantize
|
|
642
|
+
# merged w13 weights and generate a single scaling factor.
|
|
643
|
+
layer.w13_weight_scale = torch.nn.Parameter(torch.ones(
|
|
644
|
+
layer.local_num_experts,
|
|
645
|
+
dtype=torch.float32,
|
|
646
|
+
device=w13_weight.device),
|
|
647
|
+
requires_grad=False)
|
|
648
|
+
for expert in range(layer.local_num_experts):
|
|
649
|
+
w13_weight[expert, :, :], layer.w13_weight_scale[
|
|
650
|
+
expert] = ops.scaled_fp8_quant(
|
|
651
|
+
layer.w13_weight.data[expert, :, :])
|
|
652
|
+
w2_weight[expert, :, :], layer.w2_weight_scale[
|
|
653
|
+
expert] = ops.scaled_fp8_quant(
|
|
654
|
+
layer.w2_weight.data[expert, :, :])
|
|
655
|
+
layer.w13_weight = torch.nn.Parameter(w13_weight,
|
|
656
|
+
requires_grad=False)
|
|
657
|
+
layer.w2_weight = torch.nn.Parameter(w2_weight,
|
|
658
|
+
requires_grad=False)
|
|
659
|
+
if is_rocm_aiter_moe_enabled():
|
|
660
|
+
# reshaping weights is required for aiter moe kernel.
|
|
661
|
+
w13_scales, w2_scales = expand_weights(
|
|
662
|
+
layer.w13_weight_scale.data,
|
|
663
|
+
layer.w2_weight_scale.data,
|
|
664
|
+
expansion_dims=[
|
|
665
|
+
layer.w13_weight.shape[1], layer.w2_weight.shape[1]
|
|
666
|
+
])
|
|
667
|
+
layer.w13_weight_scale = torch.nn.Parameter(
|
|
668
|
+
w13_scales.contiguous(), requires_grad=False)
|
|
669
|
+
layer.w2_weight_scale = torch.nn.Parameter(
|
|
670
|
+
w2_scales.contiguous(), requires_grad=False)
|
|
671
|
+
|
|
672
|
+
shuffled_w13, shuffled_w2 = shuffle_weights(
|
|
673
|
+
layer.w13_weight, layer.w2_weight)
|
|
674
|
+
|
|
675
|
+
layer.w13_weight = torch.nn.Parameter(shuffled_w13,
|
|
676
|
+
requires_grad=False)
|
|
677
|
+
layer.w2_weight = torch.nn.Parameter(shuffled_w2,
|
|
678
|
+
requires_grad=False)
|
|
679
|
+
return
|
|
680
|
+
|
|
681
|
+
# If checkpoint is fp8, we need to handle that the
|
|
682
|
+
# MoE kernels require single activation scale and single weight
|
|
683
|
+
# scale for w13 per expert.
|
|
684
|
+
else:
|
|
685
|
+
# Fp8 moe kernels require a single activation scale.
|
|
686
|
+
# We take the max of all the scales in case they differ.
|
|
687
|
+
if self.quant_config.activation_scheme == "static":
|
|
688
|
+
if (layer.w13_input_scale is None
|
|
689
|
+
or layer.w2_input_scale is None):
|
|
690
|
+
raise ValueError(
|
|
691
|
+
"QuantConfig has static quantization, but found "
|
|
692
|
+
"activation scales are None.")
|
|
693
|
+
if (not all_close_1d(layer.w13_input_scale)
|
|
694
|
+
or not all_close_1d(layer.w2_input_scale)):
|
|
695
|
+
logger.warning_once(
|
|
696
|
+
"Found input_scales that are not equal for "
|
|
697
|
+
"fp8 MoE layer. Using the maximum across experts "
|
|
698
|
+
"for each layer.")
|
|
699
|
+
layer.w13_input_scale = torch.nn.Parameter(
|
|
700
|
+
layer.w13_input_scale.max(), requires_grad=False)
|
|
701
|
+
layer.w2_input_scale = torch.nn.Parameter(
|
|
702
|
+
layer.w2_input_scale.max(), requires_grad=False)
|
|
703
|
+
if current_platform.is_fp8_fnuz():
|
|
704
|
+
# Normalize the weights and scales
|
|
705
|
+
w13_weight, w13_weight_scale, w13_input_scale = \
|
|
706
|
+
normalize_e4m3fn_to_e4m3fnuz(
|
|
707
|
+
layer.w13_weight, layer.w13_weight_scale,
|
|
708
|
+
layer.w13_input_scale)
|
|
709
|
+
w2_weight, w2_weight_scale, w2_input_scale = \
|
|
710
|
+
normalize_e4m3fn_to_e4m3fnuz(
|
|
711
|
+
layer.w2_weight, layer.w2_weight_scale,
|
|
712
|
+
layer.w2_input_scale)
|
|
713
|
+
# Reset the parameter
|
|
714
|
+
layer.w13_weight = torch.nn.Parameter(w13_weight,
|
|
715
|
+
requires_grad=False)
|
|
716
|
+
layer.w13_weight_scale = torch.nn.Parameter(
|
|
717
|
+
w13_weight_scale, requires_grad=False)
|
|
718
|
+
if w13_input_scale is not None:
|
|
719
|
+
layer.w13_input_scale = torch.nn.Parameter(
|
|
720
|
+
w13_input_scale, requires_grad=False)
|
|
721
|
+
layer.w2_weight = torch.nn.Parameter(w2_weight,
|
|
722
|
+
requires_grad=False)
|
|
723
|
+
layer.w2_weight_scale = torch.nn.Parameter(w2_weight_scale,
|
|
724
|
+
requires_grad=False)
|
|
725
|
+
if w2_input_scale is not None:
|
|
726
|
+
layer.w2_input_scale = torch.nn.Parameter(
|
|
727
|
+
w2_input_scale, requires_grad=False)
|
|
728
|
+
|
|
729
|
+
# Fp8 moe kernel needs single weight scale for w13 per expert.
|
|
730
|
+
# We take the max then dequant and requant each expert.
|
|
731
|
+
assert layer.w13_weight_scale is not None
|
|
732
|
+
shard_size = layer.intermediate_size_per_partition
|
|
733
|
+
max_w13_scales = layer.w13_weight_scale.max(dim=1).values
|
|
734
|
+
for expert_id in range(layer.local_num_experts):
|
|
735
|
+
start = 0
|
|
736
|
+
for shard_id in range(2):
|
|
737
|
+
dq_weight = per_tensor_dequantize(
|
|
738
|
+
layer.w13_weight[expert_id][start:start +
|
|
739
|
+
shard_size, :],
|
|
740
|
+
layer.w13_weight_scale[expert_id][shard_id])
|
|
741
|
+
layer.w13_weight[expert_id][
|
|
742
|
+
start:start + shard_size, :], _ = ops.scaled_fp8_quant(
|
|
743
|
+
dq_weight, max_w13_scales[expert_id])
|
|
744
|
+
start += shard_size
|
|
745
|
+
|
|
746
|
+
if is_rocm_aiter_moe_enabled():
|
|
747
|
+
# reshaping weights is required for aiter moe kernel.
|
|
748
|
+
expansion_dims = [
|
|
749
|
+
layer.w13_weight.shape[1], layer.w2_weight.shape[1]
|
|
750
|
+
]
|
|
751
|
+
max_w13_scales, w2_scales = expand_weights(
|
|
752
|
+
max_w13_scales,
|
|
753
|
+
layer.w2_weight_scale.data,
|
|
754
|
+
expansion_dims=expansion_dims)
|
|
755
|
+
layer.w2_weight_scale = torch.nn.Parameter(
|
|
756
|
+
w2_scales.contiguous(), requires_grad=False)
|
|
757
|
+
|
|
758
|
+
shuffled_w13, shuffled_w2 = shuffle_weights(
|
|
759
|
+
layer.w13_weight, layer.w2_weight)
|
|
760
|
+
|
|
761
|
+
layer.w13_weight = torch.nn.Parameter(shuffled_w13,
|
|
762
|
+
requires_grad=False)
|
|
763
|
+
layer.w2_weight = torch.nn.Parameter(shuffled_w2,
|
|
764
|
+
requires_grad=False)
|
|
765
|
+
|
|
766
|
+
layer.w13_weight_scale = torch.nn.Parameter(max_w13_scales,
|
|
767
|
+
requires_grad=False)
|
|
768
|
+
return
|
|
769
|
+
|
|
770
|
+
def apply(
|
|
771
|
+
self,
|
|
772
|
+
layer: torch.nn.Module,
|
|
773
|
+
x: torch.Tensor,
|
|
774
|
+
router_logits: torch.Tensor,
|
|
775
|
+
top_k: int,
|
|
776
|
+
renormalize: bool,
|
|
777
|
+
use_grouped_topk: bool = False,
|
|
778
|
+
topk_group: Optional[int] = None,
|
|
779
|
+
num_expert_group: Optional[int] = None,
|
|
780
|
+
global_num_experts: int = -1,
|
|
781
|
+
expert_map: Optional[torch.Tensor] = None,
|
|
782
|
+
custom_routing_function: Optional[Callable] = None,
|
|
783
|
+
scoring_func: str = "softmax",
|
|
784
|
+
e_score_correction_bias: Optional[torch.Tensor] = None,
|
|
785
|
+
apply_router_weight_on_input: bool = False,
|
|
786
|
+
activation: str = "silu",
|
|
787
|
+
) -> torch.Tensor:
|
|
788
|
+
from vllm.model_executor.layers.fused_moe import fused_experts
|
|
789
|
+
|
|
790
|
+
topk_weights, topk_ids = FusedMoE.select_experts(
|
|
791
|
+
hidden_states=x,
|
|
792
|
+
router_logits=router_logits,
|
|
793
|
+
use_grouped_topk=use_grouped_topk,
|
|
794
|
+
top_k=top_k,
|
|
795
|
+
renormalize=renormalize,
|
|
796
|
+
topk_group=topk_group,
|
|
797
|
+
num_expert_group=num_expert_group,
|
|
798
|
+
custom_routing_function=custom_routing_function,
|
|
799
|
+
scoring_func=scoring_func,
|
|
800
|
+
e_score_correction_bias=e_score_correction_bias,
|
|
801
|
+
)
|
|
802
|
+
|
|
803
|
+
return fused_experts(
|
|
804
|
+
x,
|
|
805
|
+
layer.w13_weight,
|
|
806
|
+
layer.w2_weight,
|
|
807
|
+
topk_weights=topk_weights,
|
|
808
|
+
topk_ids=topk_ids,
|
|
809
|
+
inplace=True,
|
|
810
|
+
activation=activation,
|
|
811
|
+
use_fp8_w8a8=True,
|
|
812
|
+
global_num_experts=global_num_experts,
|
|
813
|
+
apply_router_weight_on_input=apply_router_weight_on_input,
|
|
814
|
+
expert_map=expert_map,
|
|
815
|
+
w1_scale=(layer.w13_weight_scale_inv
|
|
816
|
+
if self.block_quant else layer.w13_weight_scale),
|
|
817
|
+
w2_scale=(layer.w2_weight_scale_inv
|
|
818
|
+
if self.block_quant else layer.w2_weight_scale),
|
|
819
|
+
a1_scale=layer.w13_input_scale,
|
|
820
|
+
a2_scale=layer.w2_input_scale,
|
|
821
|
+
block_shape=self.quant_config.weight_block_size,
|
|
822
|
+
allow_deep_gemm=self.allow_deep_gemm,
|
|
823
|
+
)
|
|
824
|
+
|
|
825
|
+
|
|
826
|
+
class Fp8KVCacheMethod(BaseKVCacheMethod):
|
|
827
|
+
"""
|
|
828
|
+
Supports loading kv-cache scaling factors from FP8 checkpoints.
|
|
829
|
+
"""
|
|
830
|
+
|
|
831
|
+
def __init__(self, quant_config: Fp8Config):
|
|
832
|
+
super().__init__(quant_config)
|