fffiloni commited on
Commit
e0dcf65
โ€ข
1 Parent(s): 38a3fb3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -5
app.py CHANGED
@@ -175,16 +175,17 @@ with gr.Blocks(css="style.css") as demo:
175
 
176
  input_img = gr.Image(type="filepath", elem_id="input-img")
177
  music_output = gr.Audio(label="Result", type="filepath", elem_id="music-output")
178
- track_duration = gr.Slider(minimum=20, maximum=120, value=30, step=5, label="Track duration", elem_id="duration-inp")
179
- with gr.Row():
180
- gen_intensity = gr.Dropdown(choices=["low", "medium", "high"], value="medium", label="Intensity")
181
- gen_mode = gr.Radio(label="mode", choices=["track", "loop"], value="track")
182
- generate = gr.Button("Generate Music from Image")
183
 
184
  with gr.Group(elem_id="share-btn-container"):
185
  community_icon = gr.HTML(community_icon_html, visible=False)
186
  loading_icon = gr.HTML(loading_icon_html, visible=False)
187
  share_button = gr.Button("Share to community", elem_id="share-btn", visible=False)
 
 
 
 
 
 
188
 
189
  gr.HTML(article)
190
  generate.click(get_prompts, inputs=[input_img,track_duration,gen_intensity,gen_mode], outputs=[music_output, share_button, community_icon, loading_icon], api_name="i2m")
 
175
 
176
  input_img = gr.Image(type="filepath", elem_id="input-img")
177
  music_output = gr.Audio(label="Result", type="filepath", elem_id="music-output")
 
 
 
 
 
178
 
179
  with gr.Group(elem_id="share-btn-container"):
180
  community_icon = gr.HTML(community_icon_html, visible=False)
181
  loading_icon = gr.HTML(loading_icon_html, visible=False)
182
  share_button = gr.Button("Share to community", elem_id="share-btn", visible=False)
183
+
184
+ track_duration = gr.Slider(minimum=20, maximum=120, value=30, step=5, label="Track duration", elem_id="duration-inp")
185
+ with gr.Row():
186
+ gen_intensity = gr.Dropdown(choices=["low", "medium", "high"], value="medium", label="Intensity")
187
+ gen_mode = gr.Radio(label="mode", choices=["track", "loop"], value="track")
188
+ generate = gr.Button("Generate Music from Image")
189
 
190
  gr.HTML(article)
191
  generate.click(get_prompts, inputs=[input_img,track_duration,gen_intensity,gen_mode], outputs=[music_output, share_button, community_icon, loading_icon], api_name="i2m")