日々精進

新しく学んだことを書き留めていきます

2016-09-28から1日間の記事一覧

InceptionResNetV2のlayersをSequentialクラスに渡すと「ValueError: Input 0 of layer conv2d_6 is incompatible with the layer」エラー

AI

原因はよく分からないが、Sequential APIでなく、Functional APIを使うと直った。 サンプルコードは以下。 base_model = tf.keras.applications.inception_resnet_v2.InceptionResNetV2(weights='imagenet', include_top=False, input_shape=(WIDTH, HEIGHT,…