News for hackers. Stuff that matters.
Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by julien_c on Tuesday June 28, 2022 @03:17AM (#31905058)
what's the inference time on M1?
Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by tomduncalf on Tuesday June 28, 2022 @03:47AM (#31905229)
Running the "alien life" example from the README took 30 seconds on my M1 Max. I don't think it uses the GPU at all.

I couldn't get the "mega" option to work, I got an error "TypeError: lax.dynamic_update_slice requires arguments to have the same dtypes, got float32, float16" (looks like a known issue https://github.com/kuprel/min-dalle/issues/2)

Edit: installing flax 0.4.2 fixes this issue, thank all!

Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by klohto on Tuesday June 28, 2022 @04:15AM (#31905396)
The thread now has a fix. As for the GPU, it's possible to get it working with some extra steps https://github.com/google/jax/issues/8074

Macbook Pro M1 Pro numbers (CPU):

    python3 image_from_text.py --text='court sketch of godzilla on trial' --mega   640.24s user 179.30s system 544% cpu 2:30.39 total
Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by tomduncalf on Tuesday June 28, 2022 @04:59AM (#31905636)
From reading that thread it didn't sound like GPU was fully supported yet, were you able to get it working?
Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by tomduncalf on Tuesday June 28, 2022 @04:58AM (#31905629)
Pretty much identical on M1 Max

python3 image_from_text.py --text='a comfy chair that looks like an avocado' 612.30s user 180.72s system 552% cpu 2:23.52 total

Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by kuprel on Tuesday June 28, 2022 @07:33AM (#31906404)
Thanks for catching this. I just updated it so that it should work with the latest flax.
Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by lloeki on Tuesday June 28, 2022 @07:29AM (#31906386)
This appears to have been fixed moments ago:

https://github.com/kuprel/min-dalle/commit/38ebe54a382f36dc7...

Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by NhanH on Tuesday June 28, 2022 @04:16AM (#31905405)
Change the flax version to 0.4.2 (currently 0.5.2) will work

So much for semver :(

Re:Show HN: I stripped DALL·E Mini to its bare essentials an... by Twisol on Tuesday June 28, 2022 @05:15AM (#31905724)
0.y.z is kind of an "all bets are off" situation in semver: https://semver.org/#spec-item-4

> Major version zero (0.y.z) is for initial development. Anything MAY change at any time. The public API SHOULD NOT be considered stable.

Variant schemes like the one respected by Cargo (https://doc.rust-lang.org/cargo/reference/semver.html) aren't usually much different.

> Initial development releases starting with "0.y.z" can treat changes in "y" as a major release, and "z" as a minor release.