Skip to content

torch_tvarant.compiler

Graph compiler that fuses GEMM epilogues and pointwise chains for inference on device="tvarant".

import torch_tvarant
compiled = torch_tvarant.compiler.compile(model)
y = compiled(x)
API Summary
compile Compile a module for inference
compile_fx Fuse an FX graph
trace_module FX-trace with inlined Linear/activations
fuse_gemm_epilogue Fuse mm/linear + act into linear_act
fuse_pointwise Collapse pointwise chains
register Register Dynamo backend "tvarant"
TvarantTracer Custom FX tracer