a1 = lambda df: df.apply(lambda x: ','.join(x.values), axis=1)
gb = df2.swaplevel(0, 1, 1).sort_index(1).groupby(level=0, axis=1)
gb.apply(a1)
Pandas dataframe combine duplicate columns into one- separate data by comma