Skip to content

Commit 70185f3

Browse files
committed
Fix imports for Keras 2.2.2+
1 parent c197321 commit 70185f3

File tree

4 files changed

+6
-5
lines changed

4 files changed

+6
-5
lines changed

‎.idea/DenseNet.iml‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎.idea/misc.xml‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎densenet.py‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
from keras.utils.layer_utils import convert_all_kernels_in_model, convert_dense_weights_data_format
2222
from keras.utils.data_utils import get_file
2323
from keras.engine.topology import get_source_inputs
24-
from keras.applications.imagenet_utils import _obtain_input_shape
25-
from keras.applications.imagenet_utils import decode_predictions
24+
from keras_applications.imagenet_utils import _obtain_input_shape
25+
from keras_applications.imagenet_utils import decode_predictions
2626
import keras.backend as K
2727

2828
from subpixel import SubPixelUpscaling
@@ -797,4 +797,5 @@ def __create_fcn_dense_net(nb_classes, img_input, include_top, nb_dense_block=5,
797797
growth_rate=12, bottleneck=True, reduction=0.5, weights=None)
798798
model.summary()
799799

800+
from keras.callbacks import ModelCheckpoint, TensorBoard
800801
#plot_model(model, 'test.png', show_shapes=True)

‎subpixel.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
from keras import backend as K
44
from keras.engine import Layer
55
from keras.utils.generic_utils import get_custom_objects
6-
from keras.utils.conv_utils import normalize_data_format
6+
from keras.backend import normalize_data_format
77

88
if K.backend() == 'theano':
99
import theano_backend as K_BACKEND

0 commit comments

Comments
 (0)