def plotTrack(crossSections,centerPoints): fig = plt.figure() ax = fig.add_subplot(111, projection='3d') for index in range(len(xArr1)): zArr1.append(EdgeFinder.getHeight(xArr1[index],yArr1[index],centerPoints)*HEIGHT_SCALE) zArr2.append(EdgeFinder.getHeight(xArr2[index],yArr2[index],centerPoints)*HEIGHT_SCALE) t = np.linspace(0, 1, len(zArr1)) t2 = np.linspace(0, 1, len(zArr1)) x12 = np.interp(t2, t, xArr1) y12 = np.interp(t2, t, yArr1) z12 = np.interp(t2, t, zArr1) x22 = np.interp(t2, t, xArr2) y22 = np.interp(t2, t, yArr2) z22 = np.interp(t2, t, zArr2) sigma = 2 x13 = gaussian_filter1d(x12, sigma) y13 = gaussian_filter1d(y12, sigma) z13 = gaussian_filter1d(z12, sigma) x23 = gaussian_filter1d(x22, sigma) y23 = gaussian_filter1d(y22, sigma) z23 = gaussian_filter1d(z22, sigma) ax.plot(z13,y13,x13,color = 'b') ax.plot(z23,y23,x23,color = 'b') plt.show()