imagenet

TensorFlow/Keras - expected global_average_pooling2d_1_input to have shape (1, 1, 2048) but got array with shape (7, 7, 2048)

大兔子大兔子 提交于 2019-12-13 03:48:15
问题 I'm fairly new to TensorFlow and Image Classification, so I may be missing key knowledge and is probably why I'm facing this issue. I've built a ResNet50 model in TensorFlow for the purpose of image classification of Dog Breeds using the ImageNet library and I have successfully trained a neural network which can detect various Dog Breeds. I'm now at the point in which I would like to pass a random image of a dog to my model for it to spit out an output on what it thinks the dog breed is.

Got confused after I extracted weights from Trained caffenet

无人久伴 提交于 2019-12-13 03:39:46
问题 So basically this are the dimensions of the weights from trained caffenet: conv1: (96,3,11,11) conv2: (256,48,5,5) conv3:(384,256,3,3) conv4: (384,192,3,3) conv5:(256, 192, 3 , 3) I am confused that although conv1 gives 96 channels as output why does conv2 only considers 48 while convolution? Am I missing something? 回答1: Yes, you missed the parameter 'group'. The convolution_param defined in the conv2 layer is given below.You can find out that parameter group is set to 2 as grouping the

Test accuracy cannot improve when learning ZFNet on ILSVRC12

岁酱吖の 提交于 2019-12-12 03:35:02
问题 I've implemented a home-brewed ZFNet (prototxt) for my research. After 20k iterations with the definition, the test accuracy stays at ~0.001 (i.e., 1/1000), the test loss at ~6.9, and training loss at ~6.9, which seems that the net keeps playing guessing games among the 1k classes. I've thoroughly checked the whole definition and tried to change some of the hyper-parameters to start a new training, but of no avail, same results' shown on the screen.... Could anyone show me some light? Thanks

Tensorflow Lite: ResNet example model gave VERY poor result during validation with ImageNet

折月煮酒 提交于 2019-12-12 01:16:27
问题 I am studying tensorflow lite. I downloaded the ResNet frozen graph ResNet_V2_101 from https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/g3doc/models.md#image-classification-float-models . And then I followed https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/tutorials/post_training_quant.ipynb to convert this frozen graph to both Lite model and quantized lite model. import tensorflow as tf import pathlib import sys import tensorflow as tf from tensorflow

Self-training with Noisy Student improves ImageNet classification阅读笔记

主宰稳场 提交于 2019-12-11 07:08:15
论文地址: https://arxiv.org/pdf/1911.04252v1.pdf 这篇文章实现了自训练方法,使用部分带标签数据进行训练,在ImageNet上top-1为87.4%。 方法 : 1. 为有标签和无标签的图片。 2. 使用有标签的数据、标准交叉熵损失训练了一个EfficientNet作为教师网络。 3. 用这个教师网络,在无标签数据上生成伪标签,伪标签可以是soft label(持续分布),或者hard label(one-hot分布)。文章说软标签效果更好。 4. 在有标签和无标签数据下,使用交叉熵训练一个学生网络。 5. 通过把学生网络视为教师网络,迭代以上步骤,生成新的伪标签,并训练学生网络。 软标签和硬标签,举个例子,比如图片A,输入一个分5类的网络。软标签[0.7, 0.3, 0, 0, 0],硬标签[1, 0, 0, 0, 0]。 算法如下: 算法基于半监督学习,主要的困难在于:训练学生网络的时候添加更多的噪声,在教师网络生成标签时把这些噪声移除。使用的噪声有:dropout,随机深度,数据增广。如果使用数据增广,学生必须保证被转换的图片和未转换的图片有相同的标签。如果使用dropout,教师表现更像模型集成(生成伪标签时不使用dropout),学生表现更像单一模型。 对于Noisy Student,为了更好的效果,学生模型必须足够大以适应更多的数据

Distributed tensorflow parameter server and workers

*爱你&永不变心* 提交于 2019-12-10 10:08:19
问题 I was closely following the Imagenet distributed TF train example. I am not able to understand how distribution of data takes place when this example is being run on 2 different workers? In theory, different workers should see the different part of the data. Also, what part of the code tells the parameters to pass on the parameter server? Like in the multi-gpu example, there is explicit section for the 'cpu:0'. 回答1: The different workers see different parts of the data by virtue of dequeuing

动手学PyTorch | (23) AlexNet

孤人 提交于 2019-12-08 14:46:53
在LeNet提出后的将近20年里,神经⽹络⼀度被其他机器学习⽅法超越,如支持向量机。虽然LeNet可以在早期的⼩数据集上取得好的成绩,但是在更大的真实数据集上的表现并不尽如人意。⼀⽅面,神经⽹络计算复杂。虽然20世纪90年代也有过⼀一些针对神经网络的加速硬件,但并没有像之后GPU那样⼤量普及。因此,训练⼀个多通道、多层和有大量参数的卷积神经网络在当年很难完成。另⼀方面,当年研究者还没有⼤量深⼊研究参数初始化和⾮凸优化算法等诸多领域,导致复杂的神经网络的训练通常较困难。 我们在上一节看到,神经网络可以直接基于图像的原始像素进行分类。这种称为端到端(end-to- end)的⽅法节省了很多中间步骤。然而,在很长⼀段时间里更流行的是研究者通过勤劳与智慧所设计并⽣成的⼿工特征(特征工程)。这类图像分类研究的主要流程是: 1)获取图像数据集 2)使用已有的特征提取函数生成图像的特征 3)使用机器学习模型对图像的特征分类 当时认为的机器学习部分仅限最后这一步。如果那时候跟机器学习研究者交谈,他们会认为机器学习既􏰁重要又优美。优雅的定理证明了许多分类器的性质。机器学习领域生机勃勃、严谨⽽且极其有用。然而,如果跟计算机视觉研究者交谈,则是另外⼀一幅景象。他们会告诉你图像识别⾥“不可告⼈”的现实是:计算机视觉流程中真正􏰁重要的是数据和特征。也就是说,使用较⼲净的数据集和较有效的特征甚⾄

Inception retraining issue “Nan in summary histogram for: HistogramSummary”

半世苍凉 提交于 2019-12-08 03:17:19
问题 I'm trying to retrain inceptionV3 on my RPi3. I'm getting this histogram error message. python /home/pi/Tensorflow/tensorflow/tensorflow/examples/image_retraining/retrain.py --bottleneck_dir=/home/pi/Documents/Machine\ Learning/Inception/tf_files/bottlenecks --how_many_training_steps 500 --model_dir=/home/pi/Documents/Machine\ Learning/Inception/tf_files/inception --output_graph=/home/pi/Documents/Machine\ Learning/Inception/tf_files/retrained_graph.pb --output_labels=/home/pi/Documents

Get ImageNet label for a specific index in the 1000-dimensional output tensor in torch

守給你的承諾、 提交于 2019-12-08 01:50:51
问题 I have the output Tensor of a forward pass for a Facebook implementation of the ResNet model with a cat image. That is a 1000-dimensional Tensor with the classification probabilities. Using torch.topk I can obtain the top-5 probabilities and their indexes in the output tensor. Now I want to see the human-readable labels for those most-probable indexes. I searched online for the list of labels (which apparently are also called sysnets) and only found this: http://image-net.org/challenges/LSVRC

How do I get ILSVRC12 data in image format or how to create ilsvrc12_val_lmdb?

假如想象 提交于 2019-12-06 14:03:44
问题 I am trying to run imagenet example in Caffe. In this(https://github.com/BVLC/caffe/tree/master/examples/imagenet) page they say We assume that you already have downloaded the ImageNet training data and validation data, and they are stored on your disk like: /path/to/imagenet/train/n01440764/n01440764_10026.JPEG /path/to/imagenet/val/ILSVRC2012_val_00000001.JPEG Where do I find this data? 回答1: It's a bit of a process. 1. Got to imagenet's download page and select "Download Image URLs". 2.