Skip to content

Fail when invalid arguments are provided in the recipe for a modifier #1226

@dsikka

Description

@dsikka

Describe the bug

  • You can provide extra irrelevant arguments when specifying a modifier and no error is thrown
  • This can mask issues for arguments that may no longer be supported or if they are provided incorrectly

E.g:

quant_stage:
    quant_modifiers:
        QuantizationModifier:
            dampen: 0.1
            ignore: ["lm_head"]
            config_groups:
                group_0:
                    weights:
                        num_bits: 8
                        type: "float"
                        symmetric: true
                        strategy: "tensor"
                        observer: "mse"
                    targets: ["Linear"]
  • The recipe below specifies dampen for the QuantizationModifier, however, this is not a valid argument and no error is thrown

Expected behavior

  • Validate recipe arguments are valid for the modifiers being specified

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueA good first issue for users wanting to contribute

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions