labels = np.load('data/np/np_real_str_labels_1d_v1.npy')
print(labels)
print(np.unique(labels))
print(labels.shape[0])
from collections import Counter
print(Counter(labels))
结果:
['Jogging' 'Jogging' 'Jogging' ... 'Sitting' 'Sitting' 'Sitting']
['Downstairs' 'Jogging' 'Sitting' 'Standing' 'Upstairs' 'Walking']
24403
Counter({'Walking': 9429, 'Jogging': 7605, 'Upstairs': 2733, 'Downstairs': 2228, 'Sitting': 1332, 'Standing': 1076})