Python : Getting the Row which has the max value in groups using groupby,df[df['count'] == df.groupby(['Mt'])['count'].transform(max)]