Limit tensorflow version and add checks (#12494)
* Limit tensorflow version and add checks * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Moving check in export script * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
f400bba783
commit
a04b49f1aa
2 files changed
+6
-1
No files matched your search
@@ -397,6 +397,11 @@ def export_saved_model(model,
|
||||
from models.tf import TFModel
|
||||
|
||||
LOGGER.info(f'\n{prefix} starting export with tensorflow {tf.__version__}...')
|
||||
if tf.__version__ > '2.13.1':
|
||||
helper_url = 'https://github.com/ultralytics/yolov5/issues/12489'
|
||||
LOGGER.info(
|
||||
f'WARNING ⚠️ using Tensorflow {tf.__version__} > 2.13.1 might cause issue when exporting the model to tflite {helper_url}'
|
||||
) # handling issue https://github.com/ultralytics/yolov5/issues/12489
|
||||
f = str(file).replace('.pt', '_saved_model')
|
||||
batch_size, ch, *imgsz = list(im.shape) # BCHW
|
||||
|
||||
|
||||
Reference in new issue
Block a user