Update: Python Compatability

2023/06/08

Hey everyone,

My website now has support for Python code using PyScript! This means that, on top of formatting code for LaTeX formulas…

    sr1, sample1 = wavread('./reunion.wav')
    sample1 = sample1[:int(len(sample1)/4)]
    figure, axs = plt.subplots(1,2)
    figure.set_size_inches(18, 8)
    figure.suptitle("Chopin Op.28 No. 1 \"Reunion\"")
    axs[0].plot(sample1); axs[0].set_title("Waveform")
    a = spectrogram(axs[1], sample1, sr1)
    display(figure, target="plot")

…my website can now show implementations of formulas and display and plot code output! I hope to start using this feature for my future Audio Processing articles by directly implementing Python code into the page. However, if it starts to take too long to load, I might just go back to the tried and true method of uploading screenshots of graphs.

-Evan