Add `datetime` to exported model metadata (#3694)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
single_channel
Yonghye Kwon 1 year ago committed by GitHub
parent 395cc47c53
commit cfcae388f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -55,6 +55,7 @@ import subprocess
import time import time
import warnings import warnings
from copy import deepcopy from copy import deepcopy
from datetime import datetime
from pathlib import Path from pathlib import Path
import torch import torch
@ -219,6 +220,7 @@ class Exporter:
'description': description, 'description': description,
'author': 'Ultralytics', 'author': 'Ultralytics',
'license': 'AGPL-3.0 https://ultralytics.com/license', 'license': 'AGPL-3.0 https://ultralytics.com/license',
'date': datetime.now().isoformat(),
'version': __version__, 'version': __version__,
'stride': int(max(model.stride)), 'stride': int(max(model.stride)),
'task': model.task, 'task': model.task,

Loading…
Cancel
Save