Skip to content

Conversation

@Lewington-pitsos
Copy link
Contributor

closes #914

Currently all 11 related tests pass with pytest tests\pipelines\stable_diffusion\test_stable_diffusion_inpaint.py tests\pipelines\stable_diffusion\test_stable_diffusion_inpaint_legacy.py -k test_stable_diffusion_inpaint however they use my own huggingface dataset.

Waiting on this dataset PR to be merged before we can update the URLs and merge this one.

Once this is merged I intend to apply the same strategy to improve other tests.

get tests passing with greater precision using lewington images
@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Oct 28, 2022

The documentation is not available anymore as the PR was closed or merged.

@Lewington-pitsos
Copy link
Contributor Author

@patrickvonplaten I'm submitting this PR a little early, as I am not sure if anyone generally checks dataset PRs on huggingface, and I wanted to get your attention since at the moment you're still assigned to the issue.

@patrickvonplaten
Copy link
Contributor

Hey @Lewington-pitsos this is a great PR! I'll accepted the change on https://huggingface.co/datasets/hf-internal-testing/diffusers-images/discussions/2 - thanks a mille for adding the datasets directly there.

Also, sadly we cannot guarantee a precision of 1e-4 across devices, the best we can do seems to be 1e-3 as pointed out here:
#902 (comment)

@patrickvonplaten patrickvonplaten merged commit 8ee2191 into huggingface:main Nov 2, 2022
@patrickvonplaten
Copy link
Contributor

@Lewington-pitsos, if you're interesting we still need to change the integration tests for text2image and img2img from PIL images to numpy just like you've done here. Leaving #914 open for this

@Lewington-pitsos
Copy link
Contributor Author

On it like a bonnet!

@patrickvonplaten
Copy link
Contributor

Very cool - it's merged :-)

yoonseokjin pushed a commit to yoonseokjin/diffusers that referenced this pull request Dec 25, 2023
)

* improve test precision

get tests passing with greater precision using lewington images

* make old numpy load function a wrapper around a more flexible numpy loading function

* adhere to black formatting

* add more black formatting

* adhere to isort

* loosen precision and replace path

Co-authored-by: Patrick von Platen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve the precision of our integration tests

3 participants