MCPcopy Index your code
hub / github.com/NVIDIA/TensorRT-LLM / precision

Function precision

tensorrt_llm/_common.py:125–130  ·  view source on GitHub ↗
(dtype)

Source from the content-addressed store, hash-verified

123
124@contextlib.contextmanager
125def precision(dtype):
126 if isinstance(dtype, str):
127 dtype = str_dtype_to_trt(dtype)
128 prev_dtype = switch_net_dtype(dtype)
129 yield
130 switch_net_dtype(prev_dtype)
131
132
133def serialize_engine(engine, path):

Callers 5

rms_normFunction · 0.85
forwardMethod · 0.85
forwardMethod · 0.85
forwardMethod · 0.85
forwardMethod · 0.85

Calls 2

str_dtype_to_trtFunction · 0.85
switch_net_dtypeFunction · 0.85

Tested by

no test coverage detected