Skip to content

tracking removal of the set_inductor_config argument from quantize_ #1715

@vkuzo

Description

@vkuzo

summary

We are migrating the set_inductor_config argument of quantize_ to individual workflows. Motivation:

  1. this functionality was intended for inference, and we don't want to expose it to future training workflows that we plan to add to quantize_.
  2. higher level, this flag couples torchao workflows with torch.compile, which is not ideal. We would rather keep these systems decoupled at the quantize_ API level, with individual workflows opting in as needed.

Impact on users

  • for torchao v0.9.0:: if you are passing in set_inductor_config to quantize_, your callsite will keep working with a deprecation warning. We recommend that you migrate this option to your individual workflow.
  • for torchao v0.10.0: the set_inductor_config argument will be removed from quantize_.

API changes

# torchao v0.8.x
def quantize_(
    ...,
    set_inductor_config: bool = True,
    ...,
): ...

# torchao v.0.9.0
def quantize_(
    ...,
    set_inductor_config: Optional[bool] = None,
    ...,
):
    # if set_inductor_config != None, throw a deprecation warning
    # if set_inductor_config == None, set it to True to stay consistent with old behavior

# torchao v0.10.0
def quantize_(
    ...,
):
    # set_inductor_config is removed from quantize_ and moved to relevant individual workflows

PR to remove the old syntax: #1865

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions