dmx.compressor.fx.transform.configure_transform

dmx.compressor.fx.transform.configure_transform(gm: GraphModule, scopeDict: dict, cfg: str)

A function that changes the format of the ops according to the cfg file .. note:

Configure_transform will only change existing ops and will not add any additional ops.
Hence it is recommened to pass in a cfg file for cast_input_output_transform to make sure all necessary ops are added.
Parameters:
  • gm (torch.fx.GraphModule) – Graphmodule to apply changes on

  • scopeDict (dict) – Dictionary that maps node name to scope

  • cfg (str) – config file for setting the added ops formats.

Returns:

Graphmodule with updated formats