python 重复采样,不重复采样
不重复采样c = range(10)N = 30index1 = random.sample(c, N)index2 = random.sample(c, N)print(index1)print(index2)可重复采样:import numpy as npchoices = np.random.choice(c, size=30, replace=True)print(choices)