# Normalize a Mel-Spec over which axis?

I have to find out: how to normalize a Mel-spectrogram.(for mashine-learning purpose) However, I don't know which axis has to be transformed.

The spectrogram S is of shape (m x n) where n are the time-frames and m are the frequency-bins. Over which axis do I have to do the normalization ?

I would normalize over the m-axis, because every frequency-bin is independent form all other bins.

     1 | 1 | 1
f   2 | 1 | 0
z   0 | 1 | 1        normalize over all fz-bins or ove time ?
0 | 0 | 0

time