def merge_bed(discordants_pd):
    """Function that takes as input a bed file and returns a pandas dataframe indicating if files should be merged. This
    function will merge everything that is overlapping by at least 1bp"""
    overlap = (discordants_pd.start - discordants_pd.shift().end - 1).lt(0)
    chr_overlap = discordants_pd.chrom == discordants_pd.shift().chrom
    return (overlap * 1 + chr_overlap * 1).lt(2).cumsum()
