-
Notifications
You must be signed in to change notification settings - Fork 199
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementation of Batching, Enabling HPU Graphs and FP8 quantization for SD3 Pipeline #1345
base: main
Are you sure you want to change the base?
Implementation of Batching, Enabling HPU Graphs and FP8 quantization for SD3 Pipeline #1345
Conversation
Considering number of samples as 1 ( whole batch ) to have perf measure consistent with industry standard for easier comparison
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please see inline comments and requested changes. Also, make sure there is at least 1 CI test for SD3 with batching added to test_diffusers
optimum/habana/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Outdated
Show resolved
Hide resolved
optimum/habana/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Outdated
Show resolved
Hide resolved
optimum/habana/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Outdated
Show resolved
Hide resolved
optimum/habana/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Outdated
Show resolved
Hide resolved
optimum/habana/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Outdated
Show resolved
Hide resolved
optimum/habana/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Please add a test for batch sizes to tests /test_diffusers.py
Added the tests for Batch Size |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. There are some extra spaces in sd3 pipeline file you should run make style
to fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should add example of running FP8 mode in README
examples/stable-diffusion/quantization/stable-diffusion-3/measure_config.json
Outdated
Show resolved
Hide resolved
examples/stable-diffusion/quantization/stable-diffusion-3/quantize_config.json
Outdated
Show resolved
Hide resolved
Added the example |
Fixed |
@dsocek Please provide Feedback on the changes |
@libinta Request to review the PR and push for merging |
@deepak-gowda-narayana , |
Result Summary of fast_tests.sh python -m pytest tests/test_gaudi_configuration.py tests/test_trainer_distributed.py tests/test_trainer.py tests/test_trainer_seq2seq.py Result Summary of fast_tests_diffusers.sh python -m pytest tests/test_diffusers.py Result Summary of slow_tests_diffusers.sh The Throughput in GaudiDDPMPipeline is calculated with the formula The failing test currently compares throughput against a benchmark value, assuming that higher throughput is better. However, the throughput metric is measured in seconds per sample, where lower values indicate better performance. I am working on a fix to correct the throughput calculation in the pipeline and will update the test accordingly |
Added support and enabled the follow for SD3 Pipeline.
What does this PR do?
Fixes # (issue)
Before submitting