Closed cvJie closed 5 years ago
我猜代码是 Train.py 里面是 import Architecture as cifar10 Architecture.py 里面是 import data_train as cifar10_input
我猜代码是 Train.py 里面是 import Architecture as cifar10 Architecture.py 里面是 import data_train as cifar10_input
只需要导入train_data就好了。cifar10,需要全部换掉。
我猜你是中国人
因为刚开始的时候,不能导入cifar10和cifar10_input。所以我下载了tensorflow_models, 下载链接:https://github.com/tensorflow/models 并且在Train.py添加了下面两行代码: from tensorflow.models.tutorials.image.cifar10 import cifar10 from tensorflow.models.tutorials.image.cifar10 import cifar10_input 这个时候那两个模块可以导入,但是又出现了下面的错误,并且确实在cifar10.py文件里面没有这个函数。
File "Train.py", line 37, in train images, labels, _, sizes, slabels = cifar10.distorted_inputsB(1) AttributeError: module 'tensorflow.models.tutorials.image.cifar10.cifar10' has no attribute 'distorted_inputsB'
并且,我查看了几乎所有tensorflow_models的子版本号,但还是没能找到distorted_inputsB这个函数。 请问,你这个函数是从哪里来的呢? 谢谢
你好,我发现您给的链接下已经没有tutorials了已经,这个问题怎么解决呢?
我猜代码是 Train.py 里面是 import Architecture as cifar10 Architecture.py 里面是 import data_train as cifar10_input
只需要导入train_data就好了。cifar10,需要全部换掉。
现在在TensorFlow下面找不到tutorials了已经, 您意思直接用train_data就行了?
我猜你是中国人
因为刚开始的时候,不能导入cifar10和cifar10_input。所以我下载了tensorflow_models, 下载链接:https://github.com/tensorflow/models 并且在Train.py添加了下面两行代码: from tensorflow.models.tutorials.image.cifar10 import cifar10 from tensorflow.models.tutorials.image.cifar10 import cifar10_input 这个时候那两个模块可以导入,但是又出现了下面的错误,并且确实在cifar10.py文件里面没有这个函数。
File "Train.py", line 37, in train images, labels, _, sizes, slabels = cifar10.distorted_inputsB(1) AttributeError: module 'tensorflow.models.tutorials.image.cifar10.cifar10' has no attribute 'distorted_inputsB'
并且,我查看了几乎所有tensorflow_models的子版本号,但还是没能找到distorted_inputsB这个函数。 请问,你这个函数是从哪里来的呢? 谢谢