# Compute patterns step by step algorithm
To get help on inputs add -h to script name.

# Step 1: Map - find points to discard (may omit this step)
Update run_dp.sh to point to the correct dataset folder and set your `runid`.

Run `sbatch ./run_dp.sh`

By default results are stored in `./jobs_out/<runid>`.

# Step 2: Reduce - combine discarded points
Aggregate the results of step 1. Make sure to update dataset folder and set your `runid`.

Run `python3 ../code/run_dp_reduce.py -v ./iris_2d_ns iris_2d_ns`

By default results are stored in `./reduce_out/<runid>`. The result is X, Y, Y1 np arrays with discarded points placed first.

By default figures are stored in `./figures/<runid>`

# Step 3: Run algorithm to compute patterns

Set your `runid`. By default input directory is `./reduce_out/<runid>`.

Run `python3 ../code/run_get_patterns.py -v iris_2d_ns`.

By default results are stored in `./patterns_out/`.
To change input directory run `python3 ../code/run_get_patterns.py -v -d ./datasets iris_2d_ns`.