MCPcopy
hub / github.com/NVIDIA/TensorRT-LLM / Mapping

Class Mapping

tensorrt_llm/mapping.py:394–573  ·  view source on GitHub ↗

A node with 8 GPUs, tp_size = 4, cp_size = 1, pp_size = 2 2 tp groups: - [0, 1, 2, 3] - [4, 5, 6, 7] 4 pp groups: - [0, 4] - [1, 5] - [2, 6] - [3, 7] A node with 8 GPUs, tp_size = 4, cp_size = 2, pp_size = 1 4 cp groups: - [0, 1] - [2, 3]

Source from the content-addressed store, hash-verified

392
393
394class Mapping(MappingBase):
395 """
396 A node with 8 GPUs, tp_size = 4, cp_size = 1, pp_size = 2
397
398 2 tp groups:
399
400 - [0, 1, 2, 3]
401 - [4, 5, 6, 7]
402
403 4 pp groups:
404
405 - [0, 4]
406 - [1, 5]
407 - [2, 6]
408 - [3, 7]
409
410 A node with 8 GPUs, tp_size = 4, cp_size = 2, pp_size = 1
411
412 4 cp groups:
413
414 - [0, 1]
415 - [2, 3]
416 - [4, 5]
417 - [6, 7]
418
419 2 tp groups:
420
421 - [0, 2, 4, 6]
422 - [1, 3, 5, 7]
423
424 A node with 8 GPUs, moe_tp_size = 2, moe_ep_size = 4
425
426 4 moe_tp groups:
427
428 - [0, 4]
429 - [1, 5]
430 - [2, 6]
431 - [3, 7]
432
433 2 moe_ep groups:
434
435 - [0, 1, 2, 3]
436 - [4, 5, 6, 7]
437
438 2 nodes with 16 GPUs, moe_tp_size = 2, moe_ep_size = 4, pp_size = 2
439
440 8 moe_tp groups:
441
442 - [0 4]
443 - [1 5]
444 - [2 6]
445 - [3 7]
446 - [8 12]
447 - [9 13]
448 - [10 14]
449 - [11 15]
450
451 4 moe_ep groups:

Callers 15

enc_dec_build_helperFunction · 0.90
allreduce_benchmarkFunction · 0.90
build_from_hfFunction · 0.90
engine_from_checkpointFunction · 0.90
create_kv_cache_managerFunction · 0.90
mappingMethod · 0.90
test_weights_loaderMethod · 0.90
build_and_run_tp2Function · 0.90
setUpMethod · 0.90

Calls

no outgoing calls

Tested by 15

engine_from_checkpointFunction · 0.72
create_kv_cache_managerFunction · 0.72
mappingMethod · 0.72
test_weights_loaderMethod · 0.72
build_and_run_tp2Function · 0.72
setUpMethod · 0.72
setUpMethod · 0.72
setUpMethod · 0.72