Skip to content

Commit

Permalink
Adjusted README
Browse files Browse the repository at this point in the history
  • Loading branch information
Kaszanas committed Nov 16, 2024
1 parent 443ba15 commit 7dbb026
Showing 1 changed file with 21 additions and 16 deletions.
37 changes: 21 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,25 @@

A tool meant to allow for quick data extraction from StarCraft 2 replay files ".SC2Replay".

## Usage
## Example Usage

The easiest way to run this tool is to use the provided Docker image:
The easiest way to run this tool is to use the provided Docker image release. Please note that the `maps` directory can be mounted to see what map files are downloaded, and what map files were pre-seeded with the Docker Image. Other command line options are described in [CLI Options](#cli-options). Command below showcases the exampe usage of the tool.

```sh
docker run -it --rm \
-v /path/to/your/replays:/app/replays/input \
-v /path/to/your/output:/app/replays/output \
ghcr.io/kaszanas/sc2infoextractorgo:latest [OPTIONS]
-v </path/to/your/replays>:/app/replays/input \
-v </path/to/your/output>:/app/replays/output \
-v </path/to/your/maps>:/app/maps \
sc2infoextractorgo:latest -help
```

> [!NOTE]
> If you wish to see other files that are generated by the tool, you will have to mount the appropriate directories. The tool generates logs in the `logs` directory.
Alternatively, you can [compile the tool from source](#build-from-source) and run it directly on your machine.

## CLI Options

The following flags are available:

```
Expand Down Expand Up @@ -73,30 +79,29 @@ The following flags are available:

### Minimal Example

1. Place ```.SC2Replay``` files in ```./DEMOS/Input```
2. Run ```SC2InfoExtractorGo.exe``` with default flags.
3. Verify the output in ```./DEMOS/Output```
1. Place ```.SC2Replay``` files in ```./replays/input```
2. Run ```SC2InfoExtractorGo.exe``` as follows:

```bash
SC2InfoExtractorGo.exe -input ./replays/input -output ./replays/output
```

3. Verify the output in ```./replays/output```
4. If The output packages do not contain any processed replays, proceed to verify ```./logs/```.

### Dataset Preparation

If You have a pack of replays with nested directories and You would like to automatically flatten the directory structure, We have published a tool that can be used for that, please see SC2DatasetPreparator: https://doi.org/10.5281/zenodo.5296664

Two scripts contained within that software can:
1. Flatten directory structure of Your collected replays by looking for ```.SC2Replay``` files.
2. Running Python multiprocessing package on multiple directories containing replays by calling them with ```-with-multiprocessing=false``` flag. This allows to have one package per directory created and speed up the processing.

### Anonymization
### Anonymization (Optional)

In order to anonymize the replays please make sure to download and run our open-source implementation of an anonymization server the SC2AnonServerPy: https://doi.org/10.5281/zenodo.5138313

This is required because of the multiprocessing nature of our code that needs to perform synchronization with an existing database of unique toons (player IDs) that are mapped to arbitrary incrementing integer.

### Map Translation Support

If the provided file ```output.json``` does not support map names that You require, You will have to either find it online or within the game documents. We are close to publishing a tool that will allow You to download StarCraft maps.

If You already have a set of StarCraft II maps that You would like to create a ```.json``` file to be included within Our software, use Your own solution or SC2MapLocaleExtractor: https://doi.org/10.5281/zenodo.4733264
Existing implementation downloads the maps from the Blizzard servers. This is to normalize the map names to English language. When there is no internet connection available, our tool should fallback to reading the map names from the files placed in the ```./maps``` directory.

### Filtering Capabilities

Expand Down

0 comments on commit 7dbb026

Please sign in to comment.