import sys
sys.path.append("./")
import matplotlib.pyplot as plt
plt.rcParams['figure.figsize'] = [8, 8]

from lib.test.analysis.plot_results import plot_results, print_results, print_per_sequence_results
from lib.test.evaluation import get_dataset, trackerlist

trackers = []
dataset_name = 'otb'                 # for finding dataset.py in evaluation tools
run_id = "OTB100"                         # we use `run_id` to set the dataset name, the saving path should be like `results/<run_id>/<name>/<parameter_name>/`

trackers.extend(trackerlist(name="samite", parameter_name="samite_tiny", dataset_name=dataset_name, run_ids=run_id, display_name='SAMITE T'))
trackers.extend(trackerlist(name="samite", parameter_name="samite_small", dataset_name=dataset_name, run_ids=run_id, display_name='SAMITE S'))
trackers.extend(trackerlist(name="samite", parameter_name="samite_base_plus", dataset_name=dataset_name, run_ids=run_id, display_name='SAMITE B'))
trackers.extend(trackerlist(name="samite", parameter_name="samite_large", dataset_name=dataset_name, run_ids=run_id, display_name='SAMITE L'))

dataset = get_dataset(dataset_name)
print_results(trackers, dataset, dataset_name, merge_results=True, plot_types=('success', 'norm_prec', 'prec'))
