w_truncate
w_truncate
removes all iterations after a certain point
Overview
Usage:
w_truncate [-h] [-r RCFILE] [--quiet | --verbose | --debug] [--version]
[-n N_ITER] [-W WEST_H5FILE]
Remove all iterations after a certain point in a
Command-Line Options
See the command-line tool index <command_line_tool_index> for more information on the general options.
Iteration Options
-n N_ITER, --iter N_ITER
Truncate this iteration and those following.
-W WEST_H5FILE, --west-data WEST_H5FILE
PATH of H5 file to truncate. By default, it will read from the RCFILE (e.g., west.cfg).
This option will have override whatever's provided in the RCFILE.
Examples
Running the following will remove iteration 50 and all iterations after 50 from multi.h5.
w_truncate -n 50 -W multi.h5
westpa.cli.core.w_truncate module
- class westpa.cli.core.w_truncate.ArgumentParser(prog=None, usage=None, description=None, epilog=None, parents=[], formatter_class=<class 'argparse.HelpFormatter'>, prefix_chars='-', fromfile_prefix_chars=None, argument_default=None, conflict_handler='error', add_help=True, allow_abbrev=True, exit_on_error=True)
Bases:
_AttributeHolder
,_ActionsContainer
Object for parsing command line strings into Python objects.
- Keyword Arguments:
(default (- usage -- A usage message) –
os.path.basename(sys.argv[0])
)(default – auto-generated from arguments)
does (- description -- A description of what the program)
descriptions (- epilog -- Text following the argument)
one (- parents -- Parsers whose arguments should be copied into this)
messages (- formatter_class -- HelpFormatter class for printing help)
arguments (- argument_default -- The default value for all)
containing (- fromfile_prefix_chars -- Characters that prefix files) – additional arguments
arguments
conflicts (- conflict_handler -- String indicating how to handle)
option (- add_help -- Add a -h/-help)
unambiguously (- allow_abbrev -- Allow long options to be abbreviated)
with (- exit_on_error -- Determines whether or not ArgumentParser exits) – error info when an error occurs
- add_subparsers(**kwargs)
- convert_arg_line_to_args(arg_line)
- error(message: string)
Prints a usage message incorporating the message to stderr and exits.
If you override this in a subclass, it should not return – it should either exit or raise an exception.
- exit(status=0, message=None)
- format_help()
- format_usage()
- parse_args(args=None, namespace=None)
- parse_intermixed_args(args=None, namespace=None)
- parse_known_args(args=None, namespace=None)
- parse_known_intermixed_args(args=None, namespace=None)
- print_help(file=None)
- print_usage(file=None)
- westpa.cli.core.w_truncate.entry_point()