def _evaluate(self, x, y, z):
    '\n        Returns the level of the interpolated function at each value in x,y,z.\n        Only called internally by HARKinterpolator3D.__call__ (etc).\n        '
    if _isscalar(x):
        z_pos = max(min(np.searchsorted(self.z_list, z), (self.z_n - 1)), 1)
        alpha = ((z - self.z_list[(z_pos - 1)]) / (self.z_list[z_pos] - self.z_list[(z_pos - 1)]))
        f = (((1 - alpha) * self.xyInterpolators[(z_pos - 1)](x, y)) + (alpha * self.xyInterpolators[z_pos](x, y)))
    else:
        m = len(x)
        z_pos = np.searchsorted(self.z_list, z)
        z_pos[(z_pos > (self.z_n - 1))] = (self.z_n - 1)
        z_pos[(z_pos < 1)] = 1
        f = (np.zeros(m) + np.nan)
        if (x.size > 0):
            for i in range(1, self.z_n):
                c = (z_pos == i)
                if np.any(c):
                    alpha = ((z[c] - self.z_list[(i - 1)]) / (self.z_list[i] - self.z_list[(i - 1)]))
                    f[c] = (((1 - alpha) * self.xyInterpolators[(i - 1)](x[c], y[c])) + (alpha * self.xyInterpolators[i](x[c], y[c])))
    return f
Returns the level of the interpolated function at each value in x,y,z.
Only called internally by HARKinterpolator3D.__call__ (etc).
def _evaluate(self, x, y, z):
    '\n        Returns the level of the interpolated function at each value in x,y,z.\n        Only called internally by HARKinterpolator3D.__call__ (etc).\n        '
    if _isscalar(x):
        z_pos = max(min(np.searchsorted(self.z_list, z), (self.z_n - 1)), 1)
        alpha = ((z - self.z_list[(z_pos - 1)]) / (self.z_list[z_pos] - self.z_list[(z_pos - 1)]))
        f = (((1 - alpha) * self.xyInterpolators[(z_pos - 1)](x, y)) + (alpha * self.xyInterpolators[z_pos](x, y)))
    else:
        m = len(x)
        z_pos = np.searchsorted(self.z_list, z)
        z_pos[(z_pos > (self.z_n - 1))] = (self.z_n - 1)
        z_pos[(z_pos < 1)] = 1
        f = (np.zeros(m) + np.nan)
        if (x.size > 0):
            for i in range(1, self.z_n):
                c = (z_pos == i)
                if np.any(c):
                    alpha = ((z[c] - self.z_list[(i - 1)]) / (self.z_list[i] - self.z_list[(i - 1)]))
                    f[c] = (((1 - alpha) * self.xyInterpolators[(i - 1)](x[c], y[c])) + (alpha * self.xyInterpolators[i](x[c], y[c])))
    return f