def normalizeFreqs(self,D):
        if D == {}:
            return D
        #take the sum of all frequencies in D
        s = 0
        for w in D:
            s = s + D[w].freq
        # divide each frequency by the sum
        for w in D:
            D[w].set_sub1(self.normalizeFreqs(D[w].sub1))
            D[w].set_sub2(self.normalizeFreqs(D[w].sub2))
            D[w].set_norm(float(s)/D[w].freq)
        return D

    # gives entries (and subentries) in D scores based on ratio to the baseline of SuperD
dataset/ETHPy150Open jbrew/pt-voicebox/vbox.py/Voicebox.normalizeFreqs/swapped operands of `/`