Spaces:
Paused
Paused
Remove torch_dtype
Browse files
app.py
CHANGED
@@ -30,7 +30,6 @@ else:
|
|
30 |
state_dict, network_alphas = FluxFillPipeline.lora_state_dict(
|
31 |
pretrained_model_name_or_path_or_dict="blanchon/FluxFillFurniture",
|
32 |
weight_name="pytorch_lora_weights3.safetensors",
|
33 |
-
torch_dtype=torch.bfloat16,
|
34 |
return_alphas=True,
|
35 |
)
|
36 |
|
@@ -38,13 +37,12 @@ else:
|
|
38 |
msg = "Invalid LoRA checkpoint."
|
39 |
raise ValueError(msg)
|
40 |
|
41 |
-
pipe = FluxFillPipeline.from_pretrained(
|
42 |
-
|
43 |
-
)
|
44 |
FluxFillPipeline.load_lora_into_transformer(
|
45 |
state_dict=state_dict,
|
46 |
network_alphas=network_alphas,
|
47 |
-
torch_dtype=torch.bfloat16,
|
48 |
transformer=pipe.transformer,
|
49 |
)
|
50 |
pipe.to(DEVICE)
|
|
|
30 |
state_dict, network_alphas = FluxFillPipeline.lora_state_dict(
|
31 |
pretrained_model_name_or_path_or_dict="blanchon/FluxFillFurniture",
|
32 |
weight_name="pytorch_lora_weights3.safetensors",
|
|
|
33 |
return_alphas=True,
|
34 |
)
|
35 |
|
|
|
37 |
msg = "Invalid LoRA checkpoint."
|
38 |
raise ValueError(msg)
|
39 |
|
40 |
+
pipe = FluxFillPipeline.from_pretrained("black-forest-labs/FLUX.1-Fill-dev").to(
|
41 |
+
DEVICE
|
42 |
+
)
|
43 |
FluxFillPipeline.load_lora_into_transformer(
|
44 |
state_dict=state_dict,
|
45 |
network_alphas=network_alphas,
|
|
|
46 |
transformer=pipe.transformer,
|
47 |
)
|
48 |
pipe.to(DEVICE)
|