Repository navigation
Fix/review f35 parameterize release coverage #38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
GernotMaier
merged 3 commits into
main
from
fix/review-f35-parameterize-release-coverage
Oct 4, 2026
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,32 +1,29 @@ | ||
| #!/bin/bash | ||
| # testing lookup tables by analysis | ||
| # a run and see if the table tests are | ||
| # survived at the start of the run | ||
| # (look at the log files for the lines after | ||
| # " lookup table file sanity check" | ||
| # | ||
|
|
||
| VERSION=$(cat $VERITAS_EVNDISP_AUX_DIR/IRFVERSION) | ||
|
|
||
| TFV6=$(find $VERITAS_EVNDISP_AUX_DIR/Tables/ -name "*.root") | ||
|
|
||
| TESTFILE="$VERITAS_USER_DATA_DIR/analysis/Results/${VERSION}/Crab/evndisp/64080.root" | ||
|
|
||
| for T in ${TFV6} | ||
| do | ||
| echo "Running mscw analysis for $T" | ||
| TB=$(basename $T .root) | ||
|
|
||
| ODIR="$VERITAS_USER_DATA_DIR/analysis/Results/${VERSION}/table-tests/" | ||
| mkdir -p ${ODIR} | ||
| OFIL="test.$TB.mscw" | ||
|
|
||
| echo $TB $OFIL $ODIR | ||
|
|
||
| rm -f ${ODIR}/${OFIL}.log | ||
| ${EVNDISPSYS}/bin/mscw_energy -tablesfile ${T} -noshorttree -maxnevents=10 -arrayrecid=0 \ | ||
| -inputfile ${TESTFILE} \ | ||
| -writeReconstructedEventsOnly=1 -outputfile ${ODIR}/${OFIL}.root > ${ODIR}/${OFIL}.log | ||
| # (not interested in the root file with events) | ||
| rm -f ${ODIR}/${OFIL}.root | ||
| # Supply a reference observation matched to the tables under test. | ||
| VERSION=$(cat "$VERITAS_EVNDISP_AUX_DIR/IRFVERSION") || exit 1 | ||
| TESTFILE=${1:-${TESTFILE:-}} | ||
| [[ -s $TESTFILE ]] || { echo "Usage: $0 <reference evndisp ROOT file> (or set TESTFILE)" >&2; exit 1; } | ||
| ODIR="$VERITAS_USER_DATA_DIR/analysis/Results/$VERSION/table-tests" | ||
| mkdir -p "$ODIR" || exit 1 | ||
| mapfile -t TABLES < <(find "$VERITAS_EVNDISP_AUX_DIR/Tables" -type f -name "${TABLE_PATTERN:-*.root}") | ||
| ((${#TABLES[@]})) || { echo "No lookup tables found" >&2; exit 1; } | ||
| failed=0 | ||
| for T in "${TABLES[@]}"; do | ||
| TB=$(basename "$T" .root) | ||
| OFIL="$ODIR/test.$TB.mscw" | ||
| echo "TEST reference=$TESTFILE table=$T" | ||
| rm -f "$OFIL.root" | ||
| if ! "$EVNDISPSYS/bin/mscw_energy" -tablesfile "$T" -noshorttree -maxnevents=10 -arrayrecid=0 \ | ||
| -inputfile "$TESTFILE" -writeReconstructedEventsOnly=1 -outputfile "$OFIL.root" > "$OFIL.log" 2>&1; then | ||
| echo "FAILED executable: $T" >&2 | ||
| failed=$((failed+1)) | ||
| elif [[ ! -s $OFIL.root ]] || ! grep -q 'survived test of table file!' "$OFIL.log"; then | ||
| echo "FAILED missing output/sanity marker: $T" >&2 | ||
| failed=$((failed+1)) | ||
| else | ||
| echo "PASSED table sanity: $T" | ||
| rm -f "$OFIL.root" | ||
| fi | ||
| done | ||
| echo "Lookup coverage: ${#TABLES[@]} tested; $failed failed" | ||
| ((failed == 0)) | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.