Skip to content

Commit

Permalink
Make CONFIG_DIR configurable per environment variable (ultralytics#4727)
Browse files Browse the repository at this point in the history
  • Loading branch information
joaodiogocosta authored Sep 9, 2021
1 parent bded191 commit c414f76
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion utils/plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"""

import math
import os
from copy import copy
from pathlib import Path

Expand All @@ -20,7 +21,7 @@
from utils.metrics import fitness

# Settings
CONFIG_DIR = user_config_dir() # Ultralytics settings dir
CONFIG_DIR = Path(os.getenv('YOLOV5_CONFIG_DIR') or user_config_dir()) # Ultralytics settings dir
matplotlib.rc('font', **{'size': 11})
matplotlib.use('Agg') # for writing to files only

Expand Down

0 comments on commit c414f76

Please sign in to comment.