Hipace
|
Functions | |
def | evaluate_checksum (test_name, file_name, rtol=1.e-9, atol=1.e-40, do_fields=True, do_particles=True, skip_dict={}) |
def | reset_benchmark (test_name, file_name, do_fields=True, do_particles=True) |
def | reset_all_benchmarks (path_to_all_file_names) |
Variables | |
parser = argparse.ArgumentParser() | |
dest | |
action | |
default | |
False | |
help | |
type | |
str | |
required | |
True | |
literal_eval | |
float | |
args = parser.parse_args() | |
do_fields | |
do_particles | |
file_name | |
rtol | |
atol | |
skip_dict | |
def checksum.checksumAPI.evaluate_checksum | ( | test_name, | |
file_name, | |||
rtol = 1.e-9 , |
|||
atol = 1.e-40 , |
|||
do_fields = True , |
|||
do_particles = True , |
|||
skip_dict = {} |
|||
) |
Compare IO file checksum with benchmark. Read checksum from input file_name, read benchmark corresponding to test_name, and assert their equality. @param test_name Name of test, as found between [] in .ini file. @param file_name IO file from which the checksum is computed. @param rtol Relative tolerance for the comparison. @param atol Absolute tolerance for the comparison. @param do_fields Whether to compare fields in the checksum. @param do_particles Whether to compare particles in the checksum.
def checksum.checksumAPI.reset_all_benchmarks | ( | path_to_all_file_names | ) |
Update all benchmarks (overwrites reference json files) found in path_to_all_file_names @param path_to_all_file_names Path to all IO files for which the benchmarks are to be reset. The IO files should be named <test_name>_plt, which is what regression_testing.regtests.py does, provided we're careful enough.
def checksum.checksumAPI.reset_benchmark | ( | test_name, | |
file_name, | |||
do_fields = True , |
|||
do_particles = True |
|||
) |
Update the benchmark (overwrites reference json file). Overwrite value of benchmark corresponding to test_name with checksum read from input IO file. @param test_name Name of test, as found between [] in .ini file. @param file_name IO file from which the checksum is computed. @param do_fields Whether to write field checksums in the benchmark. @param do_particles Whether to write particles checksums in the benchmark.
checksum.checksumAPI.action |
checksum.checksumAPI.args = parser.parse_args() |
checksum.checksumAPI.atol |
checksum.checksumAPI.default |
checksum.checksumAPI.dest |
checksum.checksumAPI.do_fields |
checksum.checksumAPI.do_particles |
checksum.checksumAPI.False |
checksum.checksumAPI.file_name |
checksum.checksumAPI.float |
checksum.checksumAPI.help |
checksum.checksumAPI.literal_eval |
checksum.checksumAPI.parser = argparse.ArgumentParser() |
checksum.checksumAPI.required |
checksum.checksumAPI.rtol |
checksum.checksumAPI.skip_dict |
checksum.checksumAPI.str |
checksum.checksumAPI.True |
checksum.checksumAPI.type |