dim_z += 1 ## ## ## # Define EnKF #xTrue = np.array(h_iTrue) #xTrue1 = np.array(h_iTrue1) x = np.array(h_i) u = np.array(u_i) P = np.eye(nodesInZ * numberOfGrids) * stdState * stdState f = EnKF(x=x, u=u, P=P, dim_z=dim_z, N=N) f.R *= std_noise_R**2 f.Q *= std_noise_Q**2 ensemble = f.initialize(x=x, P=P) # Generating lists for data collection and for plots thetaList = [] ThetaListOne = [] ThetaListAll = [] ThetaU = [] ThetaUR = [] ThetaListMeanU = [] measurementListTPlot = [] measurementListTCal = [] measurementListF = [] measurementSensorList = [] ThetaListMeanUForPlot = [] ThetaListMeanUAllForPlot = []