Exclude sensative layers from quantization on wan models
This commit is contained in:
@@ -211,6 +211,12 @@ class Wan2214bModel(Wan21):
|
||||
if not self.train_high_noise or not self.train_low_noise:
|
||||
self.target_lora_modules = ["WanTransformer3DModel"]
|
||||
|
||||
def get_quantization_exclude_modules(self):
|
||||
# the timestep/text conditioning embedders and the final projection feed
|
||||
# every downstream modulation; keep them in full precision when quantizing.
|
||||
# names are relative to each individual transformer (they quantize separately)
|
||||
return ["condition_embedder*", "proj_out*"]
|
||||
|
||||
@property
|
||||
def max_step_saves_to_keep_multiplier(self):
|
||||
# the cleanup mechanism checks this to see how many saves to keep
|
||||
|
||||
Reference in New Issue
Block a user