Skip to content

Utilities

utils

Utility functions for the gwmock_pop package.

Functions

get_version_information

get_version_information() -> str

Get the version information.

Returns:

Name Type Description
str str

Version information.

setup_logger

setup_logger(outdir: str = '.', filename: str | None = None, log_level: LoggingLevel | str | int = 'INFO', print_version: bool = False) -> None

Set up logging output: call at the start of the script to use.

Parameters:

Name Type Description Default
outdir str

Output directory for log file.

'.'
filename str | None

Name of the log file. If None, no log file is created.

None
log_level LoggingLevel | str | int

Logging level as string or integer.

'INFO'
print_version bool

Whether to print version information to the log.

False