Loading src/scripts/scale_model.py +17 −17 Original line number Diff line number Diff line Loading @@ -67,11 +67,11 @@ def main(): print(ex) errors += 1 elif (config['mode'] == 'geom'): #try: try: errors += scale_legacy_geom(config) #except Exception as ex: # print(ex) # errors += 1 except Exception as ex: print(ex) errors += 1 else: print("ERROR: unknown mode \"%s\" (options are edfb|geom)"%(config['mode'])) errors += 1 Loading @@ -82,8 +82,8 @@ def main(): # The script behaviour can be modified through a set of mandatory and optional # arguments. Mandatory arguments are those required to execute a meaningful # parsing and they are limited to the names of the files that need to be read # and written. The other arguments affect the format and the data fields that # are sought for. # and the operational mode ("edfb" for scattering model file, "geom" for # geometry model file). # # \returns config: `dict` A dictionary containing the script configuration. def parse_arguments(): Loading Loading @@ -259,12 +259,12 @@ def print_help(): print(" ") print("Scale model input files by multiplicative factor. ") print(" ") print("Usage: \"./scale_model.py --in INPUT --out OUTPUT [OPTIONS]\"") print("Usage: \"./scale_model.py --in INPUT --mode=MODE [--out OUTPUT] [OPTIONS]\"") print(" ") print("Valid options are: ") print("--in INPUT Original model to be scaled (mandatory). ") print("--out OUTPUT Name for the rescaled model (optional). ") print("--mode=[edfb|geom] Type of input file to be processed (mandatory)") print("--mode=[edfb|geom] Type of input to be processed (mandatory). ") print("--scale=SCALE Scale to be applied (optional, default is 1). ") print("--help Print this help and exit. ") print(" ") Loading Loading
src/scripts/scale_model.py +17 −17 Original line number Diff line number Diff line Loading @@ -67,11 +67,11 @@ def main(): print(ex) errors += 1 elif (config['mode'] == 'geom'): #try: try: errors += scale_legacy_geom(config) #except Exception as ex: # print(ex) # errors += 1 except Exception as ex: print(ex) errors += 1 else: print("ERROR: unknown mode \"%s\" (options are edfb|geom)"%(config['mode'])) errors += 1 Loading @@ -82,8 +82,8 @@ def main(): # The script behaviour can be modified through a set of mandatory and optional # arguments. Mandatory arguments are those required to execute a meaningful # parsing and they are limited to the names of the files that need to be read # and written. The other arguments affect the format and the data fields that # are sought for. # and the operational mode ("edfb" for scattering model file, "geom" for # geometry model file). # # \returns config: `dict` A dictionary containing the script configuration. def parse_arguments(): Loading Loading @@ -259,12 +259,12 @@ def print_help(): print(" ") print("Scale model input files by multiplicative factor. ") print(" ") print("Usage: \"./scale_model.py --in INPUT --out OUTPUT [OPTIONS]\"") print("Usage: \"./scale_model.py --in INPUT --mode=MODE [--out OUTPUT] [OPTIONS]\"") print(" ") print("Valid options are: ") print("--in INPUT Original model to be scaled (mandatory). ") print("--out OUTPUT Name for the rescaled model (optional). ") print("--mode=[edfb|geom] Type of input file to be processed (mandatory)") print("--mode=[edfb|geom] Type of input to be processed (mandatory). ") print("--scale=SCALE Scale to be applied (optional, default is 1). ") print("--help Print this help and exit. ") print(" ") Loading