ultralytics 8.0.82 docs updates and fixes (#2098)

Co-authored-by: Ayush Chaurasia <ayush.chaurarsia@gmail.com>
Co-authored-by: Aurelio Losquiño Muñoz <38859113+aurelm95@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Paula Derrenger <107626595+pderrenger@users.noreply.github.com>
Co-authored-by: Laughing <61612323+Laughing-q@users.noreply.github.com>
This commit is contained in:
Glenn Jocher
2023-04-18 16:15:14 +02:00
committed by GitHub
parent a38f227672
commit 55a03ad85f
15 changed files with 174 additions and 50 deletions

View File

@ -350,7 +350,6 @@ class YOLO:
if any(kwargs):
LOGGER.warning('WARNING ⚠️ using HUB training arguments, ignoring local training arguments.')
kwargs = self.session.train_args
self.session.check_disk_space()
check_pip_update_available()
overrides = self.overrides.copy()
overrides.update(kwargs)

View File

@ -290,9 +290,9 @@ class Results(SimpleClass):
line += (conf, ) * save_conf + (() if id is None else (id, ))
texts.append(('%g ' * len(line)).rstrip() % line)
with open(txt_file, 'a') as f:
for text in texts:
f.write(text + '\n')
if texts:
with open(txt_file, 'a') as f:
f.writelines(text + '\n' for text in texts)
def save_crop(self, save_dir, file_name=Path('im.jpg')):
"""