TensorRT-LLMs/tensorrt_llm/_torch/modules
bhsueh_NV 129bf19980
model: support Qwen3 (#4010)
* add qwen3 dense model pytorch backend support, initial commit

solve the results error issue

add qwen3 moe model pytorch backend support

reformat the code

* perf - use flash_infer rmsnorm for qwen3

* feat - support qwen3 moe rmsnorm

* Put the computation of Q and K norm (in attn) into a single CUDA stream, and get a 5% - 8% throughput improvement on Qwen3 4B and Qwen3 - moe 30B - A3B.

* Put the computation of Q and K norm (in attn) into a single CUDA stream, and get a 5% - 8% throughput improvement on Qwen3 4B and Qwen3 - moe 30B - A3B. -- Forgot to update all modifications.

* fix bugs of running qwen3 public models and fp8 models

Signed-off-by: bhsueh <11360707+byshiue@users.noreply.github.com>

* fix bugs due to rebase

Signed-off-by: bhsueh <11360707+byshiue@users.noreply.github.com>

* fix bugs captured by pre-commi

Signed-off-by: bhsueh <11360707+byshiue@users.noreply.github.com>

* fix bug of attention

Signed-off-by: bhsueh <11360707+byshiue@users.noreply.github.com>

---------

Signed-off-by: bhsueh <11360707+byshiue@users.noreply.github.com>
Co-authored-by: Keddy Jin <jin.gq@aliyun.com>
Co-authored-by: Jiying Dong <87510204+dongjiyingdjy@users.noreply.github.com>
Co-authored-by: shao <shao@nvidia.com>
2025-05-01 23:12:41 +08:00
..
mamba Fix create_weights in attention (#3692) 2025-04-24 07:30:00 +08:00
__init__.py Update TensorRT-LLM (#2755) 2025-02-11 03:01:00 +00:00
attention.py model: support Qwen3 (#4010) 2025-05-01 23:12:41 +08:00
decoder_layer.py chore: Use ellipsis as default value to detect whether residual argument is provided (#3626) 2025-04-17 12:31:58 +08:00
embedding.py feat: llama4 input processor (#3383) 2025-04-25 16:47:14 -07:00
fused_moe.py refactor: (part1) Add contraints doc for fusedMoe module. (#3882) 2025-04-29 22:23:02 +08:00
gated_mlp.py Fix create_weights in attention (#3692) 2025-04-24 07:30:00 +08:00
linear.py model: support Qwen3 (#4010) 2025-05-01 23:12:41 +08:00
logits_procesor.py Update (#2978) 2025-03-23 16:39:35 +08:00
mlp.py Fix create_weights in attention (#3692) 2025-04-24 07:30:00 +08:00
multi_stream_utils.py [chore] Make llama4 MoE use maybe_execute_in_parallel (#3779) 2025-04-28 10:58:03 -04:00
rms_norm.py fix: llama4: address couple of issues in llama4 attention module (#3491) 2025-04-18 01:54:59 +00:00
rotary_embedding.py feat: Support cos_sin_cache in all cases. (#3517) 2025-04-16 13:48:44 +08:00