Tensorflow: Cannot interpret feed_dict key as Tensor

前端 未结 7 1069
清歌不尽
清歌不尽 2020-12-08 14:27

I am trying to build a neural network model with one hidden layer (1024 nodes). The hidden layer is nothing but a relu unit. I am also processing the input data in batches o

7条回答
  •  悲&欢浪女
    2020-12-08 14:57

    This worked for me

    from keras import backend as K
    

    and after predicting my data i inserted this part of code then i had again loaded the model.

    K.clear_session()
    

    i faced this problem in production server, but in my pc it was running fine

    ...........

    from keras import backend as K
    
    #Before prediction
    K.clear_session()
    
    #After prediction
    K.clear_session()
    

提交回复
热议问题