-
Notifications
You must be signed in to change notification settings - Fork 653
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
scale parameter for torch.nn.functional.scaled_dot_product_attention #2294
Conversation
Tested for apple/ml-stable-diffusion#345 with: python -m python_coreml_stable_diffusion.torch2coreml --convert-text-encoder --model-version runwayml/stable-diffusion-v1-5 -o /tmp --check-output-correctness which yields: ...
Converting PyTorch Frontend ==> MIL Ops: 100%██████████▍| 447/449 [00:00<00:00, 8624.97 ops/s]
Running MIL frontend_pytorch pipeline: 100%██████████| 5/5 [00:00<00:00, 267.80 passes/s]
Running MIL default pipeline: 100%|██████████▍ 79/79 [00:02<00:00, 36.21 passes/s]
Running MIL backend_mlprogram pipeline: 100%██████████| 12/12 [00:00<00:00, 310.13 passes/s]
INFO:__main__:Saved text_encoder into /tmp/Stable_Diffusion_version_runwayml_stable-diffusion-v1-5_text_encoder.mlpackage
INFO:__main__:text_encoder baseline PyTorch to reference CoreML: PSNR changed by -173.8 dB (230.4 -> 56.6)
INFO:__main__:56.6 dB > 35 dB (minimum allowed) parity check passed
... |
@atiorh Great! Thank you for the PR! |
@junpeiz Just pushed, is this aligned with your test coverage expectations? |
Looks good! Thank you so much for adding the test. I kicked off a CI run: https://gitlab.com/coremltools1/coremltools/-/pipelines/1404611382 |
@atiorh Looks like flake8 failed. Could you |
@junpeiz Updated, thanks! |
Thanks! Kicked off CI: https://gitlab.com/coremltools1/coremltools/-/pipelines/1404713912 |
Looks like python-3.10 PyTorch tests failed. I do not see much info about the failure in the logs. |
If you search
|
Will be fixed in 8.0 release |
apple/ml-stable-diffusion#345