fffiloni commited on
Commit
dfc282b
·
verified ·
1 Parent(s): 4cf9612

add model option on non shared ui

Browse files
Files changed (1) hide show
  1. app_df.py +9 -2
app_df.py CHANGED
@@ -130,6 +130,13 @@ def generate_diffusion_forced_video(
130
  resolution_options = ["540P", "720P"]
131
  model_options = ["Skywork/SkyReels-V2-DF-1.3B-540P"] # Update if there are more
132
 
 
 
 
 
 
 
 
133
  length_options = []
134
  if is_shared_ui is True:
135
  length_options = ["4", "10"]
@@ -172,7 +179,7 @@ with gr.Blocks() as demo:
172
 
173
  with gr.Accordion("Advanced Settings", open=False):
174
  model_id = gr.Dropdown(choices=model_options, value=model_options[0], label="Model ID")
175
- resolution = gr.Radio(choices=resolution_options, value="540P", label="Resolution", interactive=False)
176
  ar_step = gr.Number(label="AR Step", value=0)
177
  causal_attention = gr.Checkbox(label="Causal Attention")
178
  causal_block_size = gr.Number(label="Causal Block Size", value=1)
@@ -183,7 +190,7 @@ with gr.Blocks() as demo:
183
  shift = gr.Slider(minimum=0.0, maximum=20.0, value=8.0, step=0.1, label="Shift")
184
  inference_steps = gr.Slider(minimum=1, maximum=100, value=30, step=1, label="Inference Steps")
185
  use_usp = gr.Checkbox(label="Use USP")
186
- offload = gr.Checkbox(label="Offload", value=True, interactive=False)
187
  fps = gr.Slider(minimum=1, maximum=60, value=24, step=1, label="FPS")
188
  seed = gr.Number(label="Seed (optional)", precision=0)
189
  prompt_enhancer = gr.Checkbox(label="Prompt Enhancer")
 
130
  resolution_options = ["540P", "720P"]
131
  model_options = ["Skywork/SkyReels-V2-DF-1.3B-540P"] # Update if there are more
132
 
133
+ if is_shared_ui is False:
134
+ model_options = [
135
+ "Skywork/SkyReels-V2-DF-1.3B-540P",
136
+ "Skywork/SkyReels-V2-DF-14B-540P",
137
+ "Skywork/SkyReels-V2-DF-14B-720P"
138
+ ]
139
+
140
  length_options = []
141
  if is_shared_ui is True:
142
  length_options = ["4", "10"]
 
179
 
180
  with gr.Accordion("Advanced Settings", open=False):
181
  model_id = gr.Dropdown(choices=model_options, value=model_options[0], label="Model ID")
182
+ resolution = gr.Radio(choices=resolution_options, value="540P", label="Resolution", interactive=False if is_shared_ui else True)
183
  ar_step = gr.Number(label="AR Step", value=0)
184
  causal_attention = gr.Checkbox(label="Causal Attention")
185
  causal_block_size = gr.Number(label="Causal Block Size", value=1)
 
190
  shift = gr.Slider(minimum=0.0, maximum=20.0, value=8.0, step=0.1, label="Shift")
191
  inference_steps = gr.Slider(minimum=1, maximum=100, value=30, step=1, label="Inference Steps")
192
  use_usp = gr.Checkbox(label="Use USP")
193
+ offload = gr.Checkbox(label="Offload", value=True, interactive=False if is_shared_ui else True)
194
  fps = gr.Slider(minimum=1, maximum=60, value=24, step=1, label="FPS")
195
  seed = gr.Number(label="Seed (optional)", precision=0)
196
  prompt_enhancer = gr.Checkbox(label="Prompt Enhancer")