Skip to content

Commit ba2afef

Browse files
committed
make a copy of initial state
1 parent a104f05 commit ba2afef

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/diffusers/modular_pipelines/modular_pipeline.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1972,6 +1972,8 @@ def __call__(self, state: PipelineState = None, output: Union[str, List[str]] =
19721972
"""
19731973
if state is None:
19741974
state = PipelineState()
1975+
else:
1976+
state = deepcopy(state)
19751977

19761978
# Make a copy of the input kwargs
19771979
passed_kwargs = kwargs.copy()

0 commit comments

Comments
 (0)