From e63ab42b43db73e0c8345ae4cdd96bd94d40e68e Mon Sep 17 00:00:00 2001 From: Joao Diogo Costa Date: Thu, 9 Sep 2021 11:50:30 +0100 Subject: [PATCH] Make CONFIG_DIR configurable per environment variable --- utils/plots.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/plots.py b/utils/plots.py index 1ed88ea7c832..059bfabc83fe 100644 --- a/utils/plots.py +++ b/utils/plots.py @@ -4,6 +4,7 @@ """ import math +import os from copy import copy from pathlib import Path @@ -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', user_config_dir())) # Ultralytics settings dir matplotlib.rc('font', **{'size': 11}) matplotlib.use('Agg') # for writing to files only