提交 9a6af0a4 编写于 作者: A A. Unique TensorFlower 提交者: TF Object Detection Team

Update imports from Keras applications

PiperOrigin-RevId: 486136890
上级 3afd339f
......@@ -18,17 +18,13 @@
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from keras.applications import resnet
import tensorflow.compat.v1 as tf
from object_detection.core import freezable_batch_norm
from object_detection.models.keras_models import model_utils
try:
from keras.applications import resnet # pylint:disable=g-import-not-at-top
except ImportError:
from tensorflow.python.keras.applications import resnet # pylint:disable=g-import-not-at-top
def _fixed_padding(inputs, kernel_size, rate=1): # pylint: disable=invalid-name
"""Pads the input along the spatial dimensions independently of input size.
......
......@@ -19,16 +19,17 @@ from __future__ import division
from __future__ import print_function
from absl import logging
from keras import backend as keras_backend
from six.moves import range
from six.moves import zip
import tensorflow.compat.v2 as tf
from tensorflow.python.keras import backend as keras_backend
from object_detection.meta_architectures import ssd_meta_arch
from object_detection.models import bidirectional_feature_pyramid_generators as bifpn_generators
from object_detection.utils import ops
from object_detection.utils import shape_utils
from object_detection.utils import tf_version
# pylint: disable=g-import-not-at-top
if tf_version.is_tf2():
try:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册