diff --git a/mclahe/core.py b/mclahe/core.py index 6afc9a6..b3be70d 100644 --- a/mclahe/core.py +++ b/mclahe/core.py @@ -40,7 +40,7 @@ def mclahe(x, kernel_size=None, n_bins=128, clip_limit=0.01, adaptive_hist_range x_hist_padded = np.pad(x, padding_hist, 'symmetric') # Set up tf graph - with tf.variable_scope("clahe") as scope: + with tf.compat.v1.variable_scope("clahe") as scope: tf_x_hist_padded_init = tf.placeholder(tf.float32, shape=x_hist_padded.shape) tf_x_hist_padded = tf.Variable(tf_x_hist_padded_init) tf_x_padded = tf.slice(tf_x_hist_padded, kernel_size // 2, x_shape + padding_x_length) @@ -191,4 +191,4 @@ def mclahe(x, kernel_size=None, n_bins=128, clip_limit=0.01, adaptive_hist_range # Get result result = sess.run(tf_res_cropped) - return result \ No newline at end of file + return result