Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions tensorrt_llm/bench/benchmark/low_latency.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,12 +121,6 @@
default=1,
help="pipeline parallelism size",
)
@optgroup.option(
"--cp",
type=int,
default=1,
help="context parallelism size",
)
@optgroup.option(
"--ep",
type=int,
Expand Down
6 changes: 0 additions & 6 deletions tensorrt_llm/bench/benchmark/throughput.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,12 +202,6 @@
default=1,
help="pipeline parallelism size",
)
@optgroup.option(
"--cp",
type=int,
default=1,
help="context parallelism size",
)
@optgroup.option(
"--ep",
type=int,
Expand Down
20 changes: 1 addition & 19 deletions tensorrt_llm/commands/eval.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
from ..llmapi import BuildConfig, KvCacheConfig
from ..llmapi.llm_utils import update_llm_args_with_extra_options
from ..logger import logger, severity_map
from ..mapping import CpType


@click.group()
Expand Down Expand Up @@ -75,10 +74,6 @@
type=int,
default=1,
help='Pipeline parallelism size.')
@click.option("--cp_size",
type=int,
default=1,
help='Context parallelism size.')
@click.option("--ep_size",
type=int,
default=None,
Expand Down Expand Up @@ -110,18 +105,14 @@
is_flag=True,
default=False,
help="Flag for disabling KV cache reuse.")
@click.option("--cp_config",
type=dict,
default=None,
help="Context parallelism configuration as JSON.")
@click.pass_context
def main(ctx, model: str, tokenizer: Optional[str], log_level: str,
backend: str, max_beam_width: int, max_batch_size: int,
max_num_tokens: int, max_seq_len: int, tp_size: int, pp_size: int,
ep_size: Optional[int], gpus_per_node: Optional[int],
kv_cache_free_gpu_memory_fraction: float, trust_remote_code: bool,
revision: Optional[str], extra_llm_api_options: Optional[str],
disable_kv_cache_reuse: bool, cp_size: int, cp_config: Optional[dict]):
disable_kv_cache_reuse: bool):
logger.set_level(log_level)
build_config = BuildConfig(max_batch_size=max_batch_size,
max_num_tokens=max_num_tokens,
Expand All @@ -132,20 +123,11 @@ def main(ctx, model: str, tokenizer: Optional[str], log_level: str,
free_gpu_memory_fraction=kv_cache_free_gpu_memory_fraction,
enable_block_reuse=not disable_kv_cache_reuse)

if cp_config is not None and "cp_type" in cp_config:
cp_config = cp_config.copy()
try:
cp_config["cp_type"] = CpType[cp_config["cp_type"].upper()]
except KeyError:
raise ValueError(f"Invalid cp_type: {cp_config['cp_type']}. " \
f"Must be one of: {', '.join([t.name for t in CpType])}")
llm_args = {
"model": model,
"tokenizer": tokenizer,
"tensor_parallel_size": tp_size,
"pipeline_parallel_size": pp_size,
"context_parallel_size": cp_size,
"cp_config": cp_config if cp_config is not None else {},
"moe_expert_parallel_size": ep_size,
"gpus_per_node": gpus_per_node,
"trust_remote_code": trust_remote_code,
Expand Down
Loading