Add option to store TE in bf16 (#7461)

This commit is contained in:
BVH
2025-04-01 23:18:53 +05:30
committed by GitHub
parent 548457bac4
commit 301e26b131
2 changed files with 3 additions and 0 deletions

View File

@@ -823,6 +823,8 @@ def text_encoder_dtype(device=None):
return torch.float8_e5m2
elif args.fp16_text_enc:
return torch.float16
elif args.bf16_text_enc:
return torch.bfloat16
elif args.fp32_text_enc:
return torch.float32