def get_conv_outsize(in_size, ker_size, stride, pad):
    """
    Calculate output size of conv operation.
    Kalculate for either height or width each. 

    Parameters
    ----------
    in_size: int    input size
    ker_size: int   kernel size
    stride: int     stride
    pad: int        padding
    """
    return (in_size + pad * 2 - ker_size) // stride + 1