xDiT: RuntimeError for batch size greater than 1 in DistriPixArtAlphaPipeline - Reopen

#81

Hi,

Error still persist and it only works after commenting out the flagged lines of code.

After commenting out multi GPUs and batch size works for all parallelism except pipefusion.

For the following code line to run the script,

torchrun --nproc_per_node=2 scripts/pixart_example.py -p pipefusion

I get the following error,

[rank1]:   File "/opt/conda/envs/pipe_fusion/lib/python3.9/site-packages/pipefusion-0.1-py3.9.egg/pipefuser/pipelines/pip/distri_pixartalpha.py", line 242, in __call__
[rank1]: AttributeError: 'NoneType' object has no attribute 'classify_height_width_bin'

If i comment out the line 242 in PipeFusion/pipefuser/pipelines/pip/distri_pixartalpha.py, it works.

Also, there is some dependency conflict between “diffusers==0.29.0” and “distvae==0.0.0b3” (requires “diffusers==0.27.2”).

@Steaunk @feifeibear

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 23 (3 by maintainers)

Most upvoted comments

I am running this command.

torchrun --nproc_per_node=4 examples/pixartalpha_example.py --model models/PixArt-XL-2-1024-MS --pipefusion_parallel_degree 2 --num_inference_steps 20 --warmup_steps 0 --prompt "A small dog" --use_split_batch

It is working fine.

Screenshot 2024-07-30 at 6 33 18 PM

Cool. I just wanted to know for benchmarking and future work explorations.

#81

Hi,

Error still persist and it only works after commenting out the flagged lines of code.

After commenting out multi GPUs and batch size works for all parallelism except pipefusion.

For the following code line to run the script,

torchrun --nproc_per_node=2 scripts/pixart_example.py -p pipefusion

I get the following error,

[rank1]:   File "/opt/conda/envs/pipe_fusion/lib/python3.9/site-packages/pipefusion-0.1-py3.9.egg/pipefuser/pipelines/pip/distri_pixartalpha.py", line 242, in __call__
[rank1]: AttributeError: 'NoneType' object has no attribute 'classify_height_width_bin'

If i comment out the line 242 in PipeFusion/pipefuser/pipelines/pip/distri_pixartalpha.py, it works.

Also, there is some dependency conflict between “diffusers==0.29.0” and “distvae==0.0.0b3” (requires “diffusers==0.27.2”).

@Steaunk @feifeibear

Sorry, could you please pull the lastest main branch. We recently change code frequently.

Hi, SaudxInu. We are working on the solving dependency conflict now. For self.image_processor.classify_height_width_bin, I think it appears on diffusers>=0.29.0. And now we are trying to upgrade the diffusers version to 0.29.0, as we added the support for SD3 model.