Python Octree Implementation