Spaces:
Running
Running
Commit
·
ca3dd1e
1
Parent(s):
9c9d4eb
feat: reverb plotting ylimits
Browse files
app.py
CHANGED
@@ -288,13 +288,15 @@ def plot_reverb(fx):
|
|
288 |
|
289 |
bc = fdn.params.c.norm() * fdn.params.b.norm()
|
290 |
log_bc = torch.log10(bc).item() * 20
|
291 |
-
eq_log_mags = [x + log_bc / len(eq_log_mags) for x in eq_log_mags]
|
292 |
-
ax.plot(w, sum(eq_log_mags), color="black", linestyle="-")
|
|
|
|
|
293 |
|
294 |
ax.set_xlabel("Frequency (Hz)")
|
295 |
ax.set_ylabel("Magnitude (dB)")
|
296 |
ax.set_xlim(20, 20000)
|
297 |
-
ax.set_ylim(-40,
|
298 |
ax.set_xscale("log")
|
299 |
ax.grid()
|
300 |
return fig
|
|
|
288 |
|
289 |
bc = fdn.params.c.norm() * fdn.params.b.norm()
|
290 |
log_bc = torch.log10(bc).item() * 20
|
291 |
+
# eq_log_mags = [x + log_bc / len(eq_log_mags) for x in eq_log_mags]
|
292 |
+
# ax.plot(w, sum(eq_log_mags), color="black", linestyle="-")
|
293 |
+
eq_log_mags = sum(eq_log_mags) + log_bc
|
294 |
+
ax.plot(w, eq_log_mags, color="black", linestyle="-")
|
295 |
|
296 |
ax.set_xlabel("Frequency (Hz)")
|
297 |
ax.set_ylabel("Magnitude (dB)")
|
298 |
ax.set_xlim(20, 20000)
|
299 |
+
ax.set_ylim(-40, 20)
|
300 |
ax.set_xscale("log")
|
301 |
ax.grid()
|
302 |
return fig
|