eliminate all shared_ptr, naive KDTree