我已成功安装了Tensorflow绑定和python.但是当我尝试导入Tensorflow时,我得到了以下错误.
ImportError: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.17' not found (required by /usr/local/lib/python2.7/dist-packages/tensorflow/python/_pywrap_tensorflow.so)
Run Code Online (Sandbox Code Playgroud)
我试图将GLIBC_2.15更新为2.17,但没有运气.
import tensorflow as tf
import numpy as np
import os
from PIL import Image
cur_dir = os.getcwd()
def modify_image(image):
#resized = tf.image.resize_images(image, 180, 180, 3)
image.set_shape([32,32,3])
flipped_images = tf.image.flip_up_down(image)
return flipped_images
def read_image(filename_queue):
reader = tf.WholeFileReader()
key,value = reader.read(filename_queue)
image = tf.image.decode_jpeg(value)
return key,image
def inputs():
filenames = ['standard_1.jpg', 'standard_2.jpg' ]
filename_queue = tf.train.string_input_producer(filenames)
filename,read_input = read_image(filename_queue)
reshaped_image = modify_image(read_input)
reshaped_image = tf.cast(reshaped_image, tf.float32)
label=tf.constant([1])
return reshaped_image,label
def weight_variable(shape):
initial = tf.truncated_normal(shape, stddev=0.1)
return tf.Variable(initial)
def bias_variable(shape):
initial = tf.constant(0.1, …Run Code Online (Sandbox Code Playgroud) 我试图将这个超长的下标移到下面的行,因为它太长了。代码是
\mathop{\mathbb{E}}_{x \in p_{data}(x), z \in p_{z}(z)}
表达式如下:
我希望字符 z 开始换行,同时作为 E 的下标。
谢谢!