def METHOD_NAME(fileName):
    """Function to compute second deviatoric stress invariant.
    """
    h5 = h5py.File(fileName, "r", driver="sec2")
    times = h5['time'][:, 0, 0]
    timeYears = times / timeUnits
    numSteps = times.shape[0]
    stressInvarMean = numpy.zeros(numSteps, dtype=numpy.float64)
    stress = h5['cell_fields/stress'][:, :, :] / stressUnits
    h5.close()
    pres = (stress[:, :, 0] + stress[:, :, 1] + stress[:, :, 2]) / 3.0
    s11 = stress[:, :, 0] - pres
    s22 = stress[:, :, 1] - pres
    s33 = stress[:, :, 2] - pres
    s12 = stress[:, :, 3]
    s23 = stress[:, :, 4]
    s13 = stress[:, :, 5]
    stressInvar = numpy.sqrt(0.5 * (s11 * s11 + s22 * s22 + s33 * s33 +
                                    2.0 * (s12 * s12 + s13 * s13 + s23 * s23)))
    print("File %s:" % fileName)
    for stepNum in range(numSteps):
        meanVal = numpy.mean(stressInvar[stepNum, :])
        minVal = numpy.amin(stressInvar[stepNum, :])
        maxVal = numpy.amax(stressInvar[stepNum, :])
        stdDev = numpy.std(stressInvar[stepNum, :])
        print("Step number:  %d" % stepNum)
        print("Stress values in MPa:")
        print("  Mean of stress invariant:                %g" % meanVal)
        print("  Minimum of stress invariant:             %g" % minVal)
        print("  Maximum of stress invariant:             %g" % maxVal)
        print("  Standard deviation of stress invariant   %g" % stdDev)
        stressInvarMean[stepNum] = meanVal
    return (stressInvarMean, timeYears)