Error in conversion pipeline. xs and ys should have size ni+1, nj+1

Hi - Can someone tell me what this error means?

Error in conversion pipeline. xs and ys should have size ni+1, nj+1.

I am trying to create a spectrogram heatmap in CairoMakie. I’ve created some test data (called test) from a wav file using the spectrogram function in the DSP.jl package.

If I try to create the heatmap using:

CairoMakie.heatmap(test.time, test.freq, pow2db.(test.power))

I get the above error.

I can generate the heatmap using Plots.jl:

Plots.heatmap(test.time, test.freq, pow2db.(test.power), 
        xlabel="Time (seconds)", 
        ylabel="Frequency (Hz)",
        fillcolor = :jet,
        title="Spectrogram from WAV File")

Thank you for any insight!

I can resolve the CairoMakie heatmap issue if I transpose the values for the ‘z’ element:

CairoMakie.heatmap(test.time, test.freq, transpose(pow2db.(test.power)))

I don’t know why it works in the Plots.jl package without the transpose.

I get the same error when I want to save a heatmap as a pdf. Producing the plot works fine, even saving as a png works. But when trying to save it as a pdf i get the same error as described above. I also would be grateful for any insight. Thank you!