Apply Ruff 0.9.0 (#18622)

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
Co-authored-by: UltralyticsAssistant <web@ultralytics.com>
This commit is contained in:
Glenn Jocher 2025-01-10 00:05:09 +01:00 committed by GitHub
parent cc1e77138c
commit 3902e740cf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
22 changed files with 69 additions and 65 deletions

View file

@ -72,7 +72,7 @@ def on_train_end(trainer):
final=True,
)
session.alive = False # stop heartbeats
LOGGER.info(f"{PREFIX}Done ✅\n" f"{PREFIX}View model at {session.model_url} 🚀")
LOGGER.info(f"{PREFIX}Done ✅\n{PREFIX}View model at {session.model_url} 🚀")
def on_train_start(trainer):

View file

@ -84,7 +84,7 @@ def on_pretrain_routine_end(trainer):
LOGGER.info(f"{PREFIX}disable with 'yolo settings mlflow=False'")
mlflow.log_params(dict(trainer.args))
except Exception as e:
LOGGER.warning(f"{PREFIX}WARNING ⚠️ Failed to initialize: {e}\n" f"{PREFIX}WARNING ⚠️ Not tracking this run")
LOGGER.warning(f"{PREFIX}WARNING ⚠️ Failed to initialize: {e}\n{PREFIX}WARNING ⚠️ Not tracking this run")
def on_train_epoch_end(trainer):