diff options
author | tlatorre <tlatorre@uchicago.edu> | 2019-11-20 09:24:16 -0600 |
---|---|---|
committer | tlatorre <tlatorre@uchicago.edu> | 2019-11-20 09:24:16 -0600 |
commit | a705b482f1a97b17dca71b64f2e571c6db29f337 (patch) | |
tree | 670012f238fd9aeeb22bd0d0afd5b121c92b8e15 /utils | |
parent | 68040652eaa92774a168f559d6b45a28b30a9275 (diff) | |
download | sddm-a705b482f1a97b17dca71b64f2e571c6db29f337.tar.gz sddm-a705b482f1a97b17dca71b64f2e571c6db29f337.tar.bz2 sddm-a705b482f1a97b17dca71b64f2e571c6db29f337.zip |
fix small bug in cat-grid-jobs
This commit fixes a small bug in cat-grid-jobs which was causing it to print
the wrong filename when there was no git_sha1 attrs in the HDF5 file.
Diffstat (limited to 'utils')
-rwxr-xr-x | utils/cat-grid-jobs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/utils/cat-grid-jobs b/utils/cat-grid-jobs index 218c1b7..3873cd3 100755 --- a/utils/cat-grid-jobs +++ b/utils/cat-grid-jobs @@ -172,13 +172,13 @@ if __name__ == '__main__': with h5py.File(args.output,"a") as fout: total_events = fout['ev'].shape[0] for filename in glob.glob(join(args.directory,'*.hdf5')): + head, tail = split(filename) with h5py.File(filename) as f: if 'git_sha1' not in f.attrs: print_fail("No git sha1 found for %s. Skipping..." % tail) continue # Check to see if the git sha1 match if fout.attrs['git_sha1'] != f.attrs['git_sha1']: - head, tail = split(filename) print_warning_once("git_sha1 is %s for current version but %s for %s" % (fout.attrs['git_sha1'],f.attrs['git_sha1'],tail)) # get fits which match up with the events valid_fits = f['fits'][np.isin(f['fits'][:][['run','gtid']],fout['ev'][:][['run','gtid']])] |