def segmentDebrisWallManual(point1, point2):

    p1, p2 = point1, point2

    d = DebugData()
    d.addSphere(p1, radius=0.01)
    d.addSphere(p2, radius=0.01)
    d.addLine(p1, p2)
    edgeObj = updatePolyData(d.getPolyData(), 'debris plane edge', visible=True)
    edgeObj.points = [p1, p2]

    xaxis = p2 - p1
    xaxis /= np.linalg.norm(xaxis)
    zaxis = np.array([0.0, 0.0, 1.0])
    yaxis = np.cross(zaxis, xaxis)

    t = getTransformFromAxes(xaxis, yaxis, zaxis)
    t.PostMultiply()
    t.Translate(p1)

    updateFrame(t, 'debris plane frame', parent=edgeObj, visible=False)

    refFrame = vtk.vtkTransform()
    refFrame.PostMultiply()
    refFrame.SetMatrix(t.GetMatrix())
    refFrame.Translate(-xaxis + yaxis + zaxis*20.0)
    updateFrame(refFrame, 'debris reference frame', parent=edgeObj, visible=False)
dataset/ETHPy150Open RobotLocomotion/director/src/python/director/segmentation.py/segmentDebrisWallManual/original