def normalize_tangents(self, dont_norm_tol=DEFAULT_DONT_NORMALIZE_TOLERANCE):
        zero = (0, 0, 0)

        tangents = [ ]
        for i, t in enumerate(self.tangents):
            if vmath.v3lengthsq(t) > dont_norm_tol: # Ensure the tangent isn't tiny before normalizing it.
                tangents.append(vmath.v3unitcube_clamp(vmath.v3normalize(t)))
            else:
                LOG.warning("%s: Found vertex[%i] with tangent < normalizable tolerance[%g]:%s",
                            "normalize_tangents", i, dont_norm_tol, t)
                tangents.append(zero)
        self.tangents = tangents

        binormals = [ ]
        for i, b in enumerate(self.binormals):
            if vmath.v3lengthsq(b) > dont_norm_tol:
                binormals.append(vmath.v3unitcube_clamp(vmath.v3normalize(b)))
            else:
                LOG.warning("%s: Found vertex[%i] with binormal < normalizable tolerance[%g]:%s",
                            "normalize_tangents", i, dont_norm_tol, b)
                binormals.append(zero)
        self.binormals = binormals
Normalize and clamp the new tangents and binormals.
dataset/ETHPy150Open turbulenz/turbulenz_tools/turbulenz_tools/tools/mesh.py/Mesh.normalize_tangents