Skip to content

Commit

Permalink
Remove Matplotlib agg backend (#499)
Browse files Browse the repository at this point in the history
  • Loading branch information
JingxianKe committed Jul 31, 2023
1 parent 12809ca commit a2790eb
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions yolort/v5/utils/plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@
# Settings
CONFIG_DIR = user_config_dir() # Ultralytics settings dir
RANK = int(os.getenv("RANK", -1))
matplotlib.rc("font", **{"size": 11})
matplotlib.use("Agg") # for writing to files only


class Colors:
Expand Down Expand Up @@ -446,7 +444,6 @@ def plot_labels(labels, names=(), save_dir=Path("")):
ax[a].spines[s].set_visible(False)

plt.savefig(save_dir / "labels.jpg", dpi=200)
matplotlib.use("Agg")
plt.close()


Expand Down

0 comments on commit a2790eb

Please sign in to comment.