diff --git a/model/classes/model/pix2code.py b/model/classes/model/pix2code.py index e8b2bcd..65758f4 100644 --- a/model/classes/model/pix2code.py +++ b/model/classes/model/pix2code.py @@ -1,12 +1,12 @@ from __future__ import absolute_import __author__ = 'Tony Beltramelli - www.tonybeltramelli.com' -from keras.layers import Input, Dense, Dropout, \ +from tensorflow.keras.layers import Input, Dense, Dropout, \ RepeatVector, LSTM, concatenate, \ Conv2D, MaxPooling2D, Flatten -from keras.models import Sequential, Model -from keras.optimizers import RMSprop -from keras import * +from tensorflow.keras.models import Sequential, Model +from tensorflow.keras.optimizers import RMSprop +from tensorflow.keras import * from .Config import * from .AModel import * diff --git a/model/sample.py b/model/sample.py index aedfe11..68bc281 100755 --- a/model/sample.py +++ b/model/sample.py @@ -22,7 +22,7 @@ output_path = argv[3] search_method = "greedy" if len(argv) < 5 else argv[4] -meta_dataset = np.load("{}/meta_dataset.npy".format(trained_weights_path)) +meta_dataset = np.load("{}/meta_dataset.npy".format(trained_weights_path),allow_pickle=True) input_shape = meta_dataset[0] output_size = meta_dataset[1] diff --git a/model/train.py b/model/train.py index afa4424..32f896a 100755 --- a/model/train.py +++ b/model/train.py @@ -4,7 +4,7 @@ __author__ = 'Tony Beltramelli - www.tonybeltramelli.com' import tensorflow as tf -sess = tf.Session(config=tf.ConfigProto(log_device_placement=True)) +#sess = tf.Session(config=tf.ConfigProto(log_device_placement=True)) import sys diff --git a/requirements.txt b/requirements.txt index 3071c5e..7c7da45 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,5 @@ Keras==2.1.2 numpy==1.13.3 -opencv-python==3.3.0.10 +opencv-python==3.4.0.14 h5py==2.7.1 -tensorflow==1.4.0 +tensorflow==2.7.1