Questions tagged [tf-slim]

TF-Slim is a lightweight library for defining, training and evaluating complex models in TensorFlow.

0
votes
0answers
10 views

InceptionV3 quantization aware training and inference

I've set up quantization aware training for Inception-V3 using tf-slimfrom scratch on imagenet. I see Fake Quantization ops inserted in the network on Tensorboard. I'm using default scripts provided ...
0
votes
0answers
9 views

TF-slim cannot squeeze while calculating sparse_softmax_cross_entropy_loss of two concatenated models

I'm trying to concatenate outputs of two concurrent Slim ResNet-v1-101 models with last layer (logits) removed. My goal is to 'grab' the outputs from last blocks of each branch, concatenate it and ...
0
votes
0answers
20 views

Initializing two copies of the same Slim ResNet-v1-101 with the same pre-trained model

I'm trying to use TF Slim ResNet-v1-101 pre-trained model to initialize two input branches of model, with different inputs (RGB features[0] and depth map features[1] respectively) to further combine ...
0
votes
1answer
38 views

Unexpected behavior in model validation with tf.slim and inception_v1

I am trying to use the inception_v1 module written in tf.slim provided here to train the model on CIFAR 10 dataset. The code to train and evaluate the model on the dataset is below. # test_data = (...
0
votes
0answers
28 views

Tensorflow Research Slim Nets - input to Resnet V1 (and others)

I would like to clarify some points on the input to tensorflow models/research/slim nets api. Regarding Resnet V1: The preprocessing_factory points to vgg_preprocessing. This seems to take as input ...
0
votes
0answers
31 views

how to get rid of tensorflow dataset iterator and preprocessing function from tensorflow graph

I followed the link fine tune vgg16 to train a mobilenetV1, the training looks good. I then froze the graph and looked at the graph on tensorboard, I found that the graph will include the dataset ...
0
votes
0answers
32 views

VGG16 on State Farm Dataset

I was trying to fine tune vgg model of tensorflow slim using state farm driver distracted dataset. Currently, I have set the fine tune parameters as: checkpoint_exclude_scopes=vgg_16/fc8 \ ...
0
votes
1answer
214 views

Using model optimizer for tensorflow slim models

I am aiming to inference tensorflow slim model with Intel OpenVINO optimizer. Using open vino docs and slides for inference and tf slim docs for training model. It's a multi-class classification ...
0
votes
0answers
29 views

Why model predictions are always the same when training Inception v1 from scratch?

I try to train the Inception v1 model (provided by TensorFlow-Slim) from scratch with a custom dataset. My dataset is about 10k samples. This dataset contains two classes (binary classification) and ...
0
votes
1answer
251 views

Implementing mixed precision training in tf-slim

I am trying to use mixed-precision training with tf-slim in order to speed up the training of networks and make use of the tensorcores available on my GPUs. I also want to make use of multiple network ...
0
votes
0answers
421 views

How to retrain the last fully connected layer for a ssd mobilenet v2 model

I currently retrained an ssd mobile net v2 model using the tutorial. I ran the following in command line to execute the retraining. It retrained the entire model. (tensorflow) c:\models-master\...
0
votes
0answers
17 views

TF-slim can not produce the same results on different server

I suffer from a server breakdown several days ago and lost all my data on the server. However the code is luckily preserved on my own computer. After uploading my code on another server, I found ...
3
votes
1answer
2k views

Geting ERROR: Config value cuda is not defined in any .rc file when trying to train mobilenet in tensorflow

I'm trying to run MobileNet_v1 on ImageNet and for that I'm using the official Tensorflow Model repository and following their guide. However when I actually tried to run the training for MobileNet_v1 ...
5
votes
1answer
479 views

tf-slim batch norm: different behaviour between training/inference mode

I'm attempting to train a tensorflow model based on the popular slim implementation of mobilenet_v2 and am observing behaviour I cannot explain related (I think) to batch normalization. Problem ...
0
votes
0answers
17 views

How to feed the tf.train.batch with self-defined generator?

Is it possible to define the slim input pipleline using self-defined generator, like keras imagedatagenerator?
0
votes
0answers
148 views

Inference with modified pretrained TensorFlow Slim networks

I am running ImageNet 2012 validation data through networks pretrained on ImageNet - specifically, the networks included in TensorFlow Slim. For downloaded and unmodified networks and checkpoints, ...
0
votes
0answers
79 views

create graph from network code file and checkpoint file in Tensorflow-slim

I am trying to create the graph of VGG-16 architecture from pretrained models provided in tensorflow-slim-research. I want to add some custom layers. As far as I know we can create a graph with either ...
0
votes
0answers
172 views

TF Slim: Fine Tune mobilenet v2 on exclude scope

I have two questions: refer to: TF Slim: Fine Tune mobilenet v2 on custom dataset The answer requires to exclude scopes: --checkpoint_exclude_scopes=MobilenetV2/Logits,MobilenetV2/Predictions,...
0
votes
1answer
193 views

Unable to achieve same performance training with vanilla Tensorflow code compared to training using TF-slim

The following code that uses the TF-Slim library to load a model and finetune it achieves a performance of 90% in a classification task (I omitted loading the data and preprocessing): with slim....
1
vote
0answers
331 views

Tensorflow - Load pre-trained inception_v3 to use with tf.estimator

I am using tf.estimator.Estimator to train my model. I would now like to try a pre-trained inception_v3 in place of my current model. I stumbled upon this repository that seems to have all the models ...
0
votes
0answers
79 views

TFslim “evaluation” final_op session initialization?

I have a tfslim evaluation loop as follows(part of a regression problem): slim.evaluation.evaluation_loop( '', FLAGS.checkpoint_dir, FLAGS.log_dir, ...
-3
votes
1answer
136 views

Transfer learning tersoflow

I'm trying to follow this tutorial enter link description hereon transfer learning, I used my own dataset , and I'm trying to use MobileNet instead to inception , the problem is in the MobileNet ...
1
vote
1answer
974 views

how to log validation loss and accuracy using tfslim

Is there any way that I can log the validaton loss and accuracy to tensorboard when using tf-slim? When I was using keras, the following code can do this for me: model.fit_generator(generator=...
1
vote
1answer
627 views

Is it possible to use mobilenet_v2 from tf-slim with anaconda and jupyter notebook?

I have an assignment that leverages tf-slim for inception. We are supposed to train a new model using a predefined architecture and pretrained weights. The example code looks like the following. ...
1
vote
1answer
374 views

Issue with fine-tuning inceptionv3 in slim tensorflow and tf record batches

I am trying to fine-tune inceptionv3 model using slim tensorflow library. I am unable to understand certain things while writing the code for it. I tried to read source code (no proper documentation) ...
1
vote
0answers
254 views

Compatibility of tf.estimator high level API with tf.slim network definition

I use nasnet.py from tf.slim with the High Level API of tf.estimator. The problem is that the allow growth parameter is not respected, i.e. the entire GPU memory is used Here is a condensed version ...
0
votes
2answers
164 views

how to load saved checkpoint in Tf SLIM

I am using TF-slim to train my own dataset. According to the tutorial, in the finetune_inception_v1_on_flowers.sh, I set the checkpoint path as ./inception_resnet_v2.ckpt, and get lots of new ...
0
votes
1answer
238 views

why do I have to reshape `inputs` from `tf.train.batch()` to use with `slim.fully_connected()?

Why do I get this error for slim.fully_connected()? ValueError: Input 0 of layer fc1 is incompatible with the layer: : expected min_ndim=2, found ndim=1. Full shape received: [32] my input is Tensor(...
1
vote
0answers
222 views

Reproducing results for CIFAR-10 with the TF-Slim NASNet model

I want to reproduce the results for the NASNet models on CIFAR-10 for some benchmarking purposes, using the TF-Slim implementation in https://github.com/tensorflow/models/tree/master/research/slim. In ...
1
vote
1answer
1k views

How do you run a validation loop during `slim.learning.train()`

I'm looking at this answer for running evaluation metrics during training: How to use evaluation_loop with train_loop in tf-slim and it seems like overriding train_step_fn=train_step_fn is the ...
1
vote
0answers
332 views

Inception_v3 finetuning : Running model failed: Not found: FeedInputs: unable to find feed output input

I am trying to fine tune inception_v3 model for reduced number of custom classes. I followed example script finetune_inception_v3_on_flowers.sh to retrain the model. Retraining script generated list ...
2
votes
0answers
160 views

Does tf_debug truly support slim?

I have written the following code: tf.contrib.slim.learning.train( ... ... session_wrapper=tensorflow.python.debug.LocalCLIDebugWrapperSession, ...) While running the code, it ...
1
vote
1answer
166 views

variables_to_train flag in Tf-slim

I am fine-tuning my model from a pretrained model using TF-Slim. When I used the create_train_op, I found that it has a parameter that is variables_to_train. In some tutorial, it used the flag as ...
2
votes
0answers
254 views

Performance comparison among Keras/Tf-slim and native Tensorflow?

I have a network and I am selecting the framework to implement: Keras, Tf-Slim or Tensorflow. My question is that does the performance (accuracy) decrease when we use Keras/Tf-slim instead of native ...
0
votes
2answers
192 views

Confusion matrix order in tensorflow

I have 6 classes and I used tf-slim in Tensorflow to obtained the confusion matrix such as [[41 2 0 0 0 0] [ 1 11 4 1 0 0] [ 0 1 12 0 0 0] [ 0 0 0 22 1 0] [ 0 0 0 0 7 0] [ ...
1
vote
1answer
392 views

How to add slim.batch_norm after custom ops/layer in tensorflow?

I have a function that aims to build an architecture as Input(x) -> o=My_ops(x,128) -> o=slim.batch_norm(o) So, my function is def _build_block(self, x, name, is_training=True): with tf....
1
vote
2answers
481 views

Why does `optimizer.minimize()` not return loss with `tf.slim.learning.train()`?

I'm using tf-slim to finetune a network, vgg16. I'd like to manually manipulate the gradients by applying a different learning rate to the last layer. But when I try to use opt.minimize(), or tf....
0
votes
2answers
444 views

resizing JPGs before creating `TFRecord` files?

I'm building a model to use with tf.slim which will run against the AVA dataset –– 32GB in size for about 256K JPG images. Against the full-res images, I created 20 sharded TFRecord files for ...
3
votes
1answer
267 views

Modifying shape of tensor in tensorflow checkpoint

I have a tensorflow checkpoint that I'm able to load after redefining the graph corresponding to it with the regular routine tf.train.Saver() and saver.restore(session, 'my_checkpoint.ckpt'). However,...
1
vote
1answer
815 views

Distributed training using multiple GPUs with tensorflow.slim.learning

I understand that TensorFlow supports distributed training. I find num_clones in train_image_classifier.py so that I can use multiple GPUs locally. python $TF_MODEL_HOME/slim/train_image_classifier....
0
votes
0answers
497 views

Parsing serialized string examples using TF-SLIM

I am new to tensorflow and I am currently trying to learn how can I parse my data using the TF-SLIM dataset classes. The problem is that I am currently combining two images into a 640x480x6 numpy ...
0
votes
1answer
593 views

How to print predictions in TF-Slim's eval_image_classifier.py?

from __future__ import absolute_import from __future__ import division from __future__ import print_function import math import tensorflow as tf from datasets import dataset_factory from nets import ...
1
vote
2answers
1k views

How can I run a Tensorflow file on GPUs?

Do you have any idea how can I run "eval_image_classifier.py" on GPUs? Should I change any functions or do any modifications? Or whether there exist any other specific functions for evaluation on GPUs?...
1
vote
1answer
294 views

Tensorflow: why inception_v3 predictions are Nan in evaluation?

I have a part of my model that is an inception_v3: logits, end_points = inception.inception_v3(input, num_classes=num_classes, is_training=trainable) predictions = end_points['...
2
votes
2answers
1k views

How periodicaly evaluate the Performance of Models in TF-Slim?

I am trying to use DensNet for regression problem with TF-Slim. My data contains 60000 jpeg images with 37 float labels for each image. I divided my data into three different tfrecords files of a ...
4
votes
2answers
3k views

Decoding tfrecord with tfslim

I use Python 2.7.13 and Tensorflow 1.3.0 on CPU. I want to use DensNet( https://github.com/pudae/tensorflow-densenet ) for regression problem. My data contains 60000 jpeg images with 37 float labels ...
2
votes
1answer
429 views

Why use “slim = tf.contrib.slim” instead of import slim normally?

In most tensorflow slim tutorials, slim module is loaded using, slim = tf.contrib.slim it does not seem making any difference (am I missing anything?), if I do from tensorflow.contrib import slim ...
0
votes
1answer
483 views

Fine-tuning a pre-trained VGG16 model on my own data using TF-Slim

I am trying to fine-tune the VGG-16 pretrained model using TF-Slim however, i am having trouble at the beginning (when attempting to preprocess the data i.e converting images from tiff to jpeg and ...
1
vote
1answer
1k views

Where is Github tf - slim pre-trained model zoo? The page returns 404

A well known place to download many pretrained model weights for tensorflow slim is this page https://github.com/tensorflow/models/tree/master/slim. This page is also referenced by lots of links(now ...
0
votes
1answer
357 views

TF Slim and inception prediction probabilities

I've trained the final layers of inception v4 using tf slim (v1.3) and I'm trying to integrate processing into an existing tool but I'm having trouble figuring out how to generate predictions. I want ...

http://mssss.yulina-kosm.ru