We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 58431f1 commit 8fe5a14Copy full SHA for 8fe5a14
src/diffusers/hooks/group_offloading.py
@@ -499,7 +499,10 @@ def _apply_group_offloading_block_level(
499
the CPU memory is a bottleneck but may counteract the benefits of using streams.
500
"""
501
if stream is not None and num_blocks_per_group != 1:
502
- raise ValueError(f"Using streams is only supported for num_blocks_per_group=1. Got {num_blocks_per_group=}.")
+ logger.warning(
503
+ f"Using streams is only supported for num_blocks_per_group=1. Got {num_blocks_per_group=}. Setting it to 1."
504
+ )
505
+ num_blocks_per_group = 1
506
507
# Create module groups for ModuleList and Sequential blocks
508
modules_with_group_offloading = set()
0 commit comments