hatchetProject / QuEST

QuEST: Efficient Finetuning for Low-bit Diffusion Models
26 stars 2 forks source link

layer_reconstruction() got an unexpected keyword argument 'timesteps' #4

Closed colorjam closed 3 months ago

colorjam commented 4 months ago

Hi, I set --quant_act in script but get the following error: image

hatchetProject commented 4 months ago

Hi, for our method, we do not use activation reconstruction (see this line).

If you would like to use the commented code, you can delete the timesteps argument in kwargs (line 541).

colorjam commented 3 months ago

@hatchetProject Thanks for your answer. I try again for weight-only quantization, but meet another error when saving parameters: image

hatchetProject commented 3 months ago

Hi, if you are using weight-only quantization (not including the command of --quant_act), then comment out the line of:

qnn.save_dict_params()

This line is meant for saving the quantization parameters of the activation quantizers. Since you are doing weight-only quantization, the activation quantization parameters are not initialized and will be None, leading to the error.

I have also made changes in the repo's code of txt2img.py to deal with this issue.