CI: compare only COLSPOT's columns of SPOT.XDS across file layouts

IDXREF writes the h,k,l it assigns back into SPOT.XDS, and its choice of basis is not deterministic
(sign flips between runs), so an md5 of the whole file could differ between layouts holding the same
pixels and finding the same spots. Compare x, y, frame and intensity only - what a read plugin
actually determines.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SVmAWnzCmRKAXVUCdc4iNi
This commit is contained in:
2026-10-08 18:34:04 +02:00
co-authored by Claude Opus 5.5
parent 7c9a6c7d11
commit 7a3bf6c5cb
+5 -3
View File
@@ -666,8 +666,9 @@ jobs:
# wrote -- which is what the first case of two of these jobs used to risk.
# Indexing must succeed, not just run: a first IDXREF refinement above 2 px is a false
# minimum (Durin fell into one at 6 px while XDS.INP started 7 px off the beam centre). And
# SPOT.XDS, which is deterministic, is kept per layout: a plugin must find the same spots in
# every layout, since they all hold the same pixels.
# SPOT.XDS is kept per layout: a plugin must find the same spots in every layout, since they
# all hold the same pixels. Only COLSPOT's columns (x, y, frame, intensity) are compared:
# IDXREF writes its h,k,l back into the file, and its choice of basis is not deterministic.
xds_case() { # <dir> <layout> <jfjoch_hdf5_test flags...>
local dir=$1 layout=$2; shift 2
cd "tests/$dir"
@@ -683,7 +684,8 @@ jobs:
same_spots() { # <dir> <layouts...>: every layout gave the same SPOT.XDS
local dir=$1 first=$2; shift 2
for l in "$@"; do
[ "$(md5sum < "tests/$dir/SPOT.XDS.$first")" = "$(md5sum < "tests/$dir/SPOT.XDS.$l")" ] \
[ "$(awk '{print $1, $2, $3, $4}' "tests/$dir/SPOT.XDS.$first" | md5sum)" = \
"$(awk '{print $1, $2, $3, $4}' "tests/$dir/SPOT.XDS.$l" | md5sum)" ] \
|| { echo "$dir: SPOT.XDS of $l differs from $first"; return 1; }
done
}