Skip to content

Commit

Permalink
ValueError: Unexpectedly found an instance of type `<class 'keras.lay…
Browse files Browse the repository at this point in the history
…ers.convolutional.ZeroPadding2D'>`. Expected a symbolic tensor instance.
  • Loading branch information
cl0ver012 committed May 13, 2018
1 parent bab5f66 commit c6f3eb1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions model.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import keras.backend as K
from keras.layers import Conv2D, UpSampling2D, BatchNormalization, ZeroPadding2D, MaxPooling2D
from keras.layers import Input, Conv2D, UpSampling2D, BatchNormalization, ZeroPadding2D, MaxPooling2D
from keras.models import Model


def create_model(img_rows, img_cols, channel=4):
# Encoder
input_tensor = ZeroPadding2D((1, 1), input_shape=(img_rows, img_cols, channel), name='input')
x = Conv2D(64, (3, 3), activation='relu', name='conv1_1')(input_tensor)
input_tensor = Input(shape=(img_rows, img_cols, channel), name='input')
x = ZeroPadding2D((1, 1))(input_tensor)
x = Conv2D(64, (3, 3), activation='relu', name='conv1_1')(x)
x = ZeroPadding2D((1, 1))(x)
x = Conv2D(64, (3, 3), activation='relu', name='conv1_2')(x)
x = MaxPooling2D((2, 2), strides=(2, 2))(x)
Expand Down

0 comments on commit c6f3eb1

Please sign in to comment.