fix random seed and get rid of numpy import