(clip)
return diff
@param clip: A numpy array of shape [c.TRAIN_HEIGHT, c.TRAIN_WIDTH, (3 * (c.HIST_LEN + 1))].
    @return: The sum of l2 differences between the frame pixels of each sequential pair of frames.
def clip_l2_diff(clip):
    """
    @param clip: A numpy array of shape [c.TRAIN_HEIGHT, c.TRAIN_WIDTH, (3 * (c.HIST_LEN + 1))].
    @return: The sum of l2 differences between the frame pixels of each sequential pair of frames.
    """
    diff = 0
    for i in xrange(c.HIST_LEN):
        frame = clip[:, :, 3 * i:3 * (i + 1)]
        next_frame = clip[:, :, 3 * (i + 1):3 * (i + 2)]
        # noinspection PyTypeChecker
        diff += np.sum(np.square(next_frame - frame))

    return diff
def clip_l2_diff ( clip ) : diff = 0 for i in xrange ( c . HIST_LEN ) : frame = clip [ : , : , 3 * i : 3 * ( i + 1 ) ] next_frame = clip [ : , : , 3 * ( i + 1 ) : 3 * ( i + 2 ) ] # noinspection PyTypeChecker diff += np . sum ( np . square ( next_frame - frame ) ) return diff