-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Allow pipeline to run in bfloat16
#581
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
Conversation
This may be a temporary solution until #567 is addressed.
This deals with the weights, not the model.
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. |
The The reason to do this is that, it's not recommended to keep For now we could create a branch with bfloat16 weights and the use that for inference. |
I removed the automatic conversion but left the other change in order to be able to load the models specifying a |
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.
LGTM, thanks a lot!
latents = jax.random.normal(prng_seed, shape=latents_shape, dtype=jnp.float32) | ||
else: | ||
if latents.shape != latents_shape: |
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.
This file doesn't seem to be in main
. Should be removed from here before mergin
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.
The merge target is flax_pipeline
for now.
Replaced by #600. |
Changes:
dtype
to be specified on model load. This is a temporary solution until Save trainingdtype
as part of the configuration #567 is addressed in a more principled way.bfloat16
orfloat16
if necessary.float32
during inference loop.See comment: #559 (comment)