sc2_datasets.utils.dataset_utils

Functions

load_replaypack_information(→ tuple[list[dict], dict, ...)

Helper function that loads replaypack information from a standard directory structure.

Module Contents

load_replaypack_information(replaypack_path: pathlib.Path) tuple[list[dict], dict, dict, dict]

Helper function that loads replaypack information from a standard directory structure.

Parameters:

replaypack_path (str) – Specifies the path to the extracted replaypack.

Returns:

Returns loaded summary information that was generated when extracting the data from replays, mapping information that specifies what was the directory structure pre-extraction, and log file which contaions how many files were successfully extracted.

Return type:

tuple[list[dict], dict, dict, dict]

Examples

The use of this method is intended to download a .zip replaypack of SC2 games and unpack the downloaded files to the folder.

May help you to download and unpack downloaded files.

The parameters should be set as in the example below.

>>> from pathlib import Path
>>> load_replaypack_information_object = load_replaypack_information(
...        replaypack_name="replaypack_name",
...        replaypack_path=Path("replaypack_path"),
...    )
>>> assert isinstance(replaypack_name, str)
>>> assert isinstance(replaypack_path, Path)