make Sd3T5 shared.opts.sd3_enable_t5 independent

This commit is contained in:
Won-Kyu Park 2024-09-20 13:07:27 +09:00
parent 30d0f950b7
commit 11c9bc719c
No known key found for this signature in database
GPG Key ID: 53AA79C8C9535D15

View File

@ -140,7 +140,7 @@ class Sd3T5(torch.nn.Module):
return tokens, multipliers
def forward(self, texts, *, token_count):
if not self.t5xxl or not shared.opts.sd3_enable_t5:
if not self.t5xxl:
return torch.zeros((len(texts), token_count, 4096), device=devices.device, dtype=devices.dtype)
tokens_batch = []