@@ -2231,9 +2231,9 @@ def __call__(self, pipeline, state: PipelineState) -> PipelineState:
22312231 data .num_channels_unet = pipeline .unet .config .in_channels
22322232 data .disable_guidance = True if pipeline .unet .config .time_cond_proj_dim is not None else False
22332233 if data .disable_guidance :
2234- pipeline .guider ._force_disable ()
2234+ pipeline .guider .disable ()
22352235 else :
2236- pipeline .guider ._force_enable ()
2236+ pipeline .guider .enable ()
22372237
22382238 # Prepare extra step kwargs. TODO: Logic should ideally just be moved out of the pipeline
22392239 data .extra_step_kwargs = self .prepare_extra_step_kwargs (pipeline , data .generator , data .eta )
@@ -2611,9 +2611,9 @@ def __call__(self, pipeline, state: PipelineState) -> PipelineState:
26112611 # (2) Prepare conditional inputs for unet using the guider
26122612 data .disable_guidance = True if pipeline .unet .config .time_cond_proj_dim is not None else False
26132613 if data .disable_guidance :
2614- pipeline .guider ._force_disable ()
2614+ pipeline .guider .disable ()
26152615 else :
2616- pipeline .guider ._force_enable ()
2616+ pipeline .guider .enable ()
26172617
26182618 # (4) Prepare extra step kwargs. TODO: Logic should ideally just be moved out of the pipeline
26192619 data .extra_step_kwargs = self .prepare_extra_step_kwargs (pipeline , data .generator , data .eta )
@@ -3011,9 +3011,9 @@ def __call__(self, pipeline, state: PipelineState) -> PipelineState:
30113011 # adding default guider arguments: disable_guidance, guidance_scale, guidance_rescale
30123012 data .disable_guidance = True if pipeline .unet .config .time_cond_proj_dim is not None else False
30133013 if data .disable_guidance :
3014- pipeline .guider ._force_disable ()
3014+ pipeline .guider .disable ()
30153015 else :
3016- pipeline .guider ._force_enable ()
3016+ pipeline .guider .enable ()
30173017
30183018 data .control_type = data .control_type .reshape (1 , - 1 ).to (data .device , dtype = data .prompt_embeds .dtype )
30193019 repeat_by = data .batch_size * data .num_images_per_prompt // data .control_type .shape [0 ]
0 commit comments