mirror of https://github.com/commaai/tinygrad.git
validate stable_diffusion output (#5163)
changed default steps, forgot to update validation
This commit is contained in:
parent
21b225ac45
commit
e4a5870b36
|
@ -643,7 +643,7 @@ if __name__ == "__main__":
|
|||
if not args.noshow: im.show()
|
||||
|
||||
# validation!
|
||||
if args.prompt == default_prompt and args.steps == 5 and args.seed == 0 and args.guidance == 7.5:
|
||||
if args.prompt == default_prompt and args.steps == 10 and args.seed == 0 and args.guidance == 7.5:
|
||||
ref_image = Tensor(np.array(Image.open(Path(__file__).parent / "stable_diffusion_seed0.png")))
|
||||
distance = (((x - ref_image).cast(dtypes.float) / ref_image.max())**2).mean().item()
|
||||
assert distance < 3e-4, colored(f"validation failed with {distance=}", "red")
|
||||
|
|
Loading…
Reference in New Issue