Skip to content

StefFashka/Agent

Repository files navigation

Requirements

  • Java JDK (test with javac) — Java 8+ recommended (Java 17+ preferred).
  • Python 3.8+ (with standard libraries; no external dependencies required unless your tester.py needs them).
  • A terminal / command prompt.

Project layout (expected)

project_root/
├── src/
│   ├── Astar.java
│   ├── Backtracking.java
│   ├── tester.py
│   ├── tests_bundleV1.json
│   └── tests_bundleV2.json
├── bin/                      # compiled class files will be placed here
│   ├── astar/
│   └── backtracking/
└── analysis/
    └── imported/
        ├── astar_import_summary.txt
        └── backtracking_import_summary.txt

Make sure the files listed above are placed inside the src/ folder before building or running.


Build (compile Java)

Open a terminal and change directory to the src/ folder:

cd path/to/project_root/src

Compile the Java implementations (run these commands from inside src/):

# Compile A* implementation and place classes in bin/astar
javac -d bin/astar Astar.java

# Compile Backtracking implementation and place classes in bin/backtracking
javac -d bin/backtracking Backtracking.java

javac -d will create the output directories under bin/ if they do not already exist.


Run tests (Python tester)

From the same src/ folder, run the tester script to evaluate either algorithm on either test bundle.

A* (both variants)

python tester.py --suite-in tests_bundleV1.json --algo astar
python tester.py --suite-in tests_bundleV2.json --algo astar

Backtracking (both variants)

python tester.py --suite-in tests_bundleV1.json --algo backtracking
python tester.py --suite-in tests_bundleV2.json --algo backtracking

Replace python with python3 if needed by your environment.


Output location

After each run, the tester writes a summary file into:

analysis/imported/astar_import_summary.txt
analysis/imported/backtracking_import_summary.txt

Each summary contains aggregated statistics such as:

  • total — number of test maps processed
  • wins — number of successful runs (path found)
  • losses — number of failed runs (no path found)
  • runtime_mean, runtime_median, runtime_mode, runtime_std — runtime metrics (in seconds)

Just tell me which you prefer.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors