Spaces:
Running
on
Zero
Running
on
Zero
Commit
·
ef45452
1
Parent(s):
c524f6f
modified: src/flux/modules/conditioner.py
Browse files- app.py +1 -1
- src/flux/modules/conditioner.py +1 -1
app.py
CHANGED
|
@@ -550,7 +550,7 @@ if __name__ == "__main__":
|
|
| 550 |
import argparse
|
| 551 |
parser = argparse.ArgumentParser(description="Flux")
|
| 552 |
parser.add_argument("--name", type=str, default="flux-dev", choices=list(configs.keys()), help="Model name")
|
| 553 |
-
parser.add_argument("--device", type=str, default="cuda"
|
| 554 |
parser.add_argument("--offload", default=False, help="Offload model to CPU when not in use")
|
| 555 |
parser.add_argument("--share", action="store_true", help="Create a public link to your demo")
|
| 556 |
parser.add_argument("--port", type=int, default=9090)
|
|
|
|
| 550 |
import argparse
|
| 551 |
parser = argparse.ArgumentParser(description="Flux")
|
| 552 |
parser.add_argument("--name", type=str, default="flux-dev", choices=list(configs.keys()), help="Model name")
|
| 553 |
+
parser.add_argument("--device", type=str, default="cuda", help="Device to use")
|
| 554 |
parser.add_argument("--offload", default=False, help="Offload model to CPU when not in use")
|
| 555 |
parser.add_argument("--share", action="store_true", help="Create a public link to your demo")
|
| 556 |
parser.add_argument("--port", type=int, default=9090)
|
src/flux/modules/conditioner.py
CHANGED
|
@@ -67,7 +67,7 @@ class HFEmbedder(nn.Module):
|
|
| 67 |
padding="max_length",
|
| 68 |
return_tensors="pt",
|
| 69 |
)
|
| 70 |
-
|
| 71 |
encoder_type = 'clip' if self.is_clip else 't5'
|
| 72 |
print(f'Forward pass for {encoder_type}')
|
| 73 |
input_ids = batch_encoding["input_ids"]
|
|
|
|
| 67 |
padding="max_length",
|
| 68 |
return_tensors="pt",
|
| 69 |
)
|
| 70 |
+
print(f'Batch Encoding {batch_encoding}')
|
| 71 |
encoder_type = 'clip' if self.is_clip else 't5'
|
| 72 |
print(f'Forward pass for {encoder_type}')
|
| 73 |
input_ids = batch_encoding["input_ids"]
|