C = np.append(C, np.asarray(np.where(S[ind])).reshape(-1)) # np.where()返回S[ind]的非0下标。
l = np.argwhere(y == Cl).reshape(-1)
diferenca = S - np.matlib.repmat(aux, Nl, 1) # np.matlib.repmat(a, m,n) 将a沿着纵轴复制m次,横轴复制n次
D = sklearn.metrics.pairwise.pairwise_distances(X_l, X_m)
Tqdm 是 Python 进度条库,可以在 Python 长循环中添加一个进度提示信息用法:tqdm(iterator)
from tqdm import tqdm
for i in tqdm(range(100)):
time.sleep(0.01)