zarox commited on
Commit
c850802
·
1 Parent(s): 1f7c7c0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +35 -7
app.py CHANGED
@@ -32,9 +32,37 @@ def process_audio(input_file,
32
 
33
 
34
 
35
- iface = gr.Interface(
36
- fn=process_audio,
37
- inputs=[
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
38
  gr.Audio(label="Upload your music file", type="filepath"),
39
 
40
  # 8d Effect and its arguments
@@ -55,9 +83,9 @@ iface = gr.Interface(
55
  gr.Slider(label="Reverb - Width", minimum=0, maximum=2, step=0.1, value=0.5),
56
  gr.Slider(label="Reverb - Wet Level", minimum=0, maximum=2, step=0.1, value=0.3),
57
  gr.Slider(label="Reverb - Dry Level", minimum=0, maximum=2, step=0.1, value=0.8),
58
- ],
59
- outputs=gr.Audio(label="Download processed music", type="filepath"),
60
- title="Audio Fusion"
61
- )
62
 
63
  iface.launch(share=False)
 
32
 
33
 
34
 
35
+ # iface = gr.Interface(
36
+ # fn=process_audio,
37
+ # inputs=[
38
+ # gr.Audio(label="Upload your music file", type="filepath"),
39
+
40
+ # # 8d Effect and its arguments
41
+ # gr.Checkbox(label="Apply 8D effect"),
42
+ # gr.Slider(label="8D - Pan Boundary", minimum=0, maximum=100, value=100),
43
+ # gr.Slider(label="8D - Jump Percentage", minimum=1, maximum=100, value=5),
44
+ # gr.Slider(label="8D - Time L to R (s)", minimum=1, maximum=30, value=10),
45
+ # gr.Slider(label="8D - Volume Multiplier", minimum=1, maximum=20, value=6),
46
+
47
+ # # SLowed Effect and its arguments
48
+ # gr.Checkbox(label="Apply slowed effect"),
49
+ # gr.Slider(label="Slowed - Speed Multiplier", minimum=0.1, maximum=4, step=0.01, value=0.92),
50
+
51
+ # # Reverb Effect and its arguments
52
+ # gr.Checkbox(label="Apply reverb effect"),
53
+ # gr.Slider(label="Reverb - Room Size", minimum=0, maximum=2, step=0.01, value=0.8),
54
+ # gr.Slider(label="Reverb - Damping", minimum=0, maximum=2, value=1),
55
+ # gr.Slider(label="Reverb - Width", minimum=0, maximum=2, step=0.1, value=0.5),
56
+ # gr.Slider(label="Reverb - Wet Level", minimum=0, maximum=2, step=0.1, value=0.3),
57
+ # gr.Slider(label="Reverb - Dry Level", minimum=0, maximum=2, step=0.1, value=0.8),
58
+ # ],
59
+ # outputs=gr.Audio(label="Download processed music", type="filepath"),
60
+ # title="Audio Fusion"
61
+ # )
62
+
63
+
64
+ with gr.Blocks() as iface:
65
+ inputs = [
66
  gr.Audio(label="Upload your music file", type="filepath"),
67
 
68
  # 8d Effect and its arguments
 
83
  gr.Slider(label="Reverb - Width", minimum=0, maximum=2, step=0.1, value=0.5),
84
  gr.Slider(label="Reverb - Wet Level", minimum=0, maximum=2, step=0.1, value=0.3),
85
  gr.Slider(label="Reverb - Dry Level", minimum=0, maximum=2, step=0.1, value=0.8),
86
+ ]
87
+ outputs = gr.Audio(label="Download processed music", type="filepath")
88
+ btn = gr.Button("Run")
89
+ btn.click(fn=process_audio, inputs=name, outputs=outputs, title="Audio Fusion", api_name="AudioFusion")
90
 
91
  iface.launch(share=False)