| import matplotlib.pyplot as plt |
| import numpy as np |
|
|
| |
| categories = ['DINO-B/8', 'DINO-B/16', 'SAM-B/16', 'SAM-L/16', 'DINOv2-B/14', 'DINOv2-L/14'] |
| x = np.arange(len(categories)) |
| OV_COCO = [42.0, 41.8, 42.6, 42.5, 43.3, 43.3] |
| VOC21 = [59.7, 61.5, 55.0, 58.9, 64.1, 62.8] |
| COCO_Obj = [31.2, 32.3, 25.8, 30.7, 38.7, 36.7] |
|
|
| |
| width = 0.25 |
|
|
| |
| fig, ax = plt.subplots(figsize=(12, 6)) |
|
|
| |
| bars1 = ax.bar(x - width, OV_COCO, width, label=r'OV-COCO (AP_novel)', color='#1f77b4', edgecolor='white', hatch='X') |
| bars2 = ax.bar(x, VOC21, width, label=r'VOC21 (mIoU)', color='#ff7f0e', edgecolor='white', hatch='X') |
| bars3 = ax.bar(x + width, COCO_Obj, width, label=r'COCO-Obj (mIoU)', color='#2ca02c', edgecolor='white', hatch='X') |
|
|
| |
| ax.set_xticks(x) |
| |
| ax.set_xticklabels(categories, fontsize=14, ha='center') |
|
|
| |
| ax.legend(fontsize=14, loc='best') |
|
|
| |
| ax.bar_label(bars1, fmt='%.2f', fontsize=12, padding=3) |
| ax.bar_label(bars2, fmt='%.2f', fontsize=12, padding=3) |
| ax.bar_label(bars3, fmt='%.2f', fontsize=12, padding=3) |
|
|
| |
| ax.spines['top'].set_visible(False) |
| ax.spines['right'].set_visible(False) |
|
|
| |
| plt.tight_layout() |
| plt.savefig('vfm_ablations.pdf', dpi=300) |