(points, epoch_freq, minibatch_markers, epoch_axis)
return x
Helper function to build x axis for points captured per epoch.

    Arguments:
        points (int): how many data points need a corresponding x axis points
        epoch_freq (int): are points once an epoch or once every n epochs?
        minibatch_markers (int array): cumulative number of minibatches complete at a given epoch
        epoch_axis (bool): whether to render epoch or minibatch as the integer step in the x axis
Helper function to build x axis for points captured per epoch.
Helper function to build x axis for points captured per epoch .
def create_epoch_x(points, epoch_freq, minibatch_markers, epoch_axis):
    """
    Helper function to build x axis for points captured per epoch.

    Arguments:
        points (int): how many data points need a corresponding x axis points
        epoch_freq (int): are points once an epoch or once every n epochs?
        minibatch_markers (int array): cumulative number of minibatches complete at a given epoch
        epoch_axis (bool): whether to render epoch or minibatch as the integer step in the x axis
    """

    if epoch_axis:
        x = np.zeros((points,))
        last_e = 0
        for e_idx, e in enumerate(minibatch_markers):
            e_minibatches = e - last_e
            if (e_idx + 1) % epoch_freq == 0:
                x[e_idx // epoch_freq] = e_idx + ((e_minibatches - 1) // e_minibatches)
            last_e = e
    else:
        x = minibatch_markers[(epoch_freq - 1)::epoch_freq] - 1

    return x
def create_epoch_x ( points , epoch_freq , minibatch_markers , epoch_axis ) : if epoch_axis : x = np . zeros ( ( points , ) ) last_e = 0 for e_idx , e in enumerate ( minibatch_markers ) : e_minibatches = e - last_e if ( e_idx + 1 ) % epoch_freq == 0 : x [ e_idx // epoch_freq ] = e_idx + ( ( e_minibatches - 1 ) // e_minibatches ) last_e = e else : x = minibatch_markers [ ( epoch_freq - 1 ) : : epoch_freq ] - 1 return x