toil.lib.resources

Module Contents

Functions

get_total_cpu_time_and_memory_usage()

Gives the total cpu time of itself and all its children, and the maximum RSS memory usage of

get_total_cpu_time()

Gives the total cpu time, including the children.

glob(glob_pattern, directoryname)

Walks through a directory and its subdirectories looking for files matching

toil.lib.resources.get_total_cpu_time_and_memory_usage()[source]

Gives the total cpu time of itself and all its children, and the maximum RSS memory usage of itself and its single largest child.

Return type:

Tuple[float, int]

toil.lib.resources.get_total_cpu_time()[source]

Gives the total cpu time, including the children.

Return type:

float

toil.lib.resources.glob(glob_pattern, directoryname)[source]

Walks through a directory and its subdirectories looking for files matching the glob_pattern and returns a list=[].

Parameters:
  • directoryname (str) – Any accessible folder name on the filesystem.

  • glob_pattern (str) – A string like *.txt, which would find all text files.

Returns:

A list=[] of absolute filepaths matching the glob pattern.

Return type:

List[str]