#!/bin/bash

set -e

bazel build -c opt vision/detection/tools:run_sliding_window

MODEL="/tmp/snapshot_cascade_v1_exp1_14__iter_500000.caffemodel"
#IMAGE="$HOME/data/kitti/object/training/image_2/002509.png"
#IMAGE="$HOME/data/kitti/object/training/image_2/000509.png"
#IMAGE="$HOME/data/kitti/object/training/image_2/002108.png"
IMAGE="$HOME/data/kitti/object/training/image_2/006139.png"
./bazel-bin/vision/detection/tools/run_sliding_window \
    --model=experimental/james/cascade_v1/exp1/deploy.pbtxt \
    --params="$MODEL" \
    --image="$IMAGE" \
    --threshold=0.5 \
    --output=debug.png \
    --patch_width=20 \
    --patch_height=50 \
    --step_horiz=5 \
    --step_vert=10 \
    --num_scales=6
