for me the problem related to “numpy” not “torch”. setting seed by the following code solved the problem.
np.random.seed(15)

setting seed for “random” package if it is imported is also necessary:
import random

random.seed(15)