num_iterations = int(sys.argv[2]) loop = 20 per_loop = int(math.ceil((num_iterations+0.0) / loop)) for c in range(loop): a = time.time() mcmc.MH(per_loop) b = time.time() print("finished iteration: " + str((c+1)*per_loop) + " in " + str(int(b-a)) + " seconds") end = time.time() print("Finished burnin and " + str(num_iterations) + " iterations in " + str(int(end-start)) + " seconds.") folder = "plots_" + fname #plotting samples will also load the MAP estimates mcmc.plot_samples(folder + "/", str(num_iterations) + '_iterations') #load up test data and run predictions model.load_test_split(Xtest, Ptest) pred = model.get_predictions() num = model.get_num_predictions() mast = model.get_mastery() err = pred - Xtest rmse = np.sqrt(np.sum(err**2)/num) errl = np.zeros(num) predl = np.zeros(num) mastl = np.zeros(num) xtestl = np.zeros(num) i = 0