385 if (strcmp(tag,
"null") == 0) {
391 if (strcmp(tag,
"leaf") == 0) {
394 int old_idx = next_idx;
399 for (
int i = 0; i < n_pts; i++) {
400 in >> the_pidx[next_idx++];
403 return new ANNkd_leaf(n_pts, &the_pidx[old_idx]);
408 else if (strcmp(tag,
"split") == 0) {
410 in >> cd >> cv >> lb >> hb;
416 return new ANNkd_split(cd, cv, lb, hb, lc, hc);
421 else if (strcmp(tag,
"shrink") == 0) {
429 for (
int i = 0; i < n_bnds; i++) {
430 in >> cd >> cv >> sd;
438 return new ANNbd_shrink(n_bnds, bds, ic, oc);
static ANNkd_ptr annReadTree(istream &in, ANNtreeType tree_type, ANNidxArray the_pidx, int &next_idx)
void annError(const char *msg, ANNerr level)