#!/usr/bin/env bash # SUM Parts - point the cfg's data_root at the downloaded dataset # # cfgs/sumv2_triangle/default.yaml sets: # data_root: ../../data/sumv2_tri_texpcl/ # That path is resolved from the *working directory* of main.py, which is # examples/segmentation. So ../../ is PointNeXt_bundle, NOT the repo root -- # the dataset has to be reachable at PointNeXt_bundle/data/. # # download_data.sh puts the data in /data, so link the two. set -euo pipefail REPO_DATA="$HOME/sum-parts/data" BUNDLE="$HOME/sum-parts/semantic_segmentation/PointNeXt_bundle" if [ ! -d "$REPO_DATA" ]; then echo "error: $REPO_DATA missing -- run download_data.sh first" >&2 exit 1 fi if [ -e "$BUNDLE/data" ] && [ ! -L "$BUNDLE/data" ]; then echo "error: $BUNDLE/data exists and is not a symlink; refusing to replace" >&2 ls -la "$BUNDLE/data" >&2 exit 1 fi ln -sfn "$REPO_DATA" "$BUNDLE/data" echo "linked: $BUNDLE/data -> $REPO_DATA" echo "=== resolution check (as main.py sees it) ===" cd "$BUNDLE/examples/segmentation" for track in sumv2_tri_texpcl sumv2_tex_texpcl; do for split in train val test; do d="../../data/$track/$split" n=$(find "$d" -name '*.ply' 2>/dev/null | wc -l) printf '%-18s %-6s %s ply\n' "$track" "$split" "$n" done done echo "LINK DONE"