Neural network for off-line Z classification and energy calibration