-
Notifications
You must be signed in to change notification settings - Fork 217
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
Add diffuser tests for optimized sdxl flow on HPU #1554
base: main
Are you sure you want to change the base?
Add diffuser tests for optimized sdxl flow on HPU #1554
Conversation
**kwargs, | ||
) | ||
logger = logging.get_logger(sd_pipe.__module__) | ||
logger.setLevel(level=diffusers.logging.INFO) |
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.
Is this only needed for the two calls to logger.info
below?
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.
yes
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.
I think we can just replace these calls with print
to not add more complexity to this test
|
||
original_dir = os.getcwd() | ||
config_dir = os.path.dirname(os.path.abspath("../examples/stable-diffusion/quantization")) | ||
os.chdir(config_dir) |
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.
Is this absolutely necessary?
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.
yes, this is required to avoid file not found error because we are executing inside from tests/, for below measurement file, it is present in examples/stable-diffusion/quantization
https://github.com/huggingface/optimum-habana/blob/main/examples/stable-diffusion/quantization/quant_config.json#L6
in the end I do restore the original directory
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.
Which method needs that? It's not possible to just pass the path as an argument?
To add diffuser tests for sdxl optimized flow for both bf16 and fp8 mode, verified and run locally
jira: SW-211820
use case PR #1519