mirror of
https://github.com/Wan-Video/Wan2.1.git
synced 2025-11-04 14:16:57 +00:00
flux is back from hiding
This commit is contained in:
parent
d3abf8da44
commit
bc9e54a3ee
16
defaults/flux.json
Normal file
16
defaults/flux.json
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
{
|
||||||
|
"model": {
|
||||||
|
"name": "Flux 1 Dev 12B",
|
||||||
|
"architecture": "flux",
|
||||||
|
"description": "FLUX.1 Dev is a 12 billion parameter rectified flow transformer capable of generating images from text descriptions.",
|
||||||
|
"URLs": [
|
||||||
|
"https://huggingface.co/DeepBeepMeep/Flux/resolve/main/flux1-dev_bf16.safetensors",
|
||||||
|
"https://huggingface.co/DeepBeepMeep/Flux/resolve/main/flux1-dev_quanto_bf16_int8.safetensors"
|
||||||
|
],
|
||||||
|
"image_outputs": true,
|
||||||
|
"flux-model": "flux-dev"
|
||||||
|
},
|
||||||
|
"prompt": "draw a hat",
|
||||||
|
"resolution": "1280x720",
|
||||||
|
"batch_size": 1
|
||||||
|
}
|
||||||
BIN
favicon.png
Normal file
BIN
favicon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 16 KiB |
14
wgp.py
14
wgp.py
@ -6026,21 +6026,23 @@ def use_video_settings(state, input_file_list, choice):
|
|||||||
if configs == None:
|
if configs == None:
|
||||||
gr.Info("No Settings to Extract")
|
gr.Info("No Settings to Extract")
|
||||||
else:
|
else:
|
||||||
|
current_model_type = state["model_type"]
|
||||||
model_type = configs["model_type"]
|
model_type = configs["model_type"]
|
||||||
|
models_compatible = are_model_types_compatible(model_type,current_model_type)
|
||||||
|
if models_compatible:
|
||||||
|
model_type = current_model_type
|
||||||
defaults = get_model_settings(state, model_type)
|
defaults = get_model_settings(state, model_type)
|
||||||
defaults = get_default_settings(model_type) if defaults == None else defaults
|
defaults = get_default_settings(model_type) if defaults == None else defaults
|
||||||
defaults.update(configs)
|
defaults.update(configs)
|
||||||
current_model_type = state["model_type"]
|
|
||||||
prompt = configs.get("prompt", "")
|
prompt = configs.get("prompt", "")
|
||||||
|
set_model_settings(state, model_type, defaults)
|
||||||
if has_image_file_extension(file_name):
|
if has_image_file_extension(file_name):
|
||||||
gr.Info(f"Settings Loaded from Image with prompt '{prompt[:100]}'")
|
gr.Info(f"Settings Loaded from Image with prompt '{prompt[:100]}'")
|
||||||
else:
|
else:
|
||||||
gr.Info(f"Settings Loaded from Video with prompt '{prompt[:100]}'")
|
gr.Info(f"Settings Loaded from Video with prompt '{prompt[:100]}'")
|
||||||
if are_model_types_compatible(model_type,current_model_type):
|
if models_compatible:
|
||||||
set_model_settings(state, current_model_type, defaults)
|
|
||||||
return gr.update(), str(time.time())
|
return gr.update(), str(time.time())
|
||||||
else:
|
else:
|
||||||
set_model_settings(state, model_type, defaults)
|
|
||||||
return generate_dropdown_model_list(model_type), gr.update()
|
return generate_dropdown_model_list(model_type), gr.update()
|
||||||
else:
|
else:
|
||||||
gr.Info(f"No Video is Selected")
|
gr.Info(f"No Video is Selected")
|
||||||
@ -8770,5 +8772,5 @@ if __name__ == "__main__":
|
|||||||
else:
|
else:
|
||||||
url = "http://" + server_name
|
url = "http://" + server_name
|
||||||
webbrowser.open(url + ":" + str(server_port), new = 0, autoraise = True)
|
webbrowser.open(url + ":" + str(server_port), new = 0, autoraise = True)
|
||||||
demo.launch(server_name=server_name, server_port=server_port, share=args.share, allowed_paths=[save_path])
|
demo.launch(favicon_path="favicon.png", server_name=server_name, server_port=server_port, share=args.share, allowed_paths=[save_path])
|
||||||
# Lucky me !!!
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user