Questions tagged [tensorflow]

TensorFlow is an open source library for machine learning and machine intelligence. TensorFlow uses data flow graphs with tensors flowing along edges. For details, see https://www.tensorflow.org. TensorFlow is released under an Apache 2.0 License.

0
votes
0answers
7 views

How to Do Label Smoothing when Legal Classes Change

Label smoothing often helps accuracy, but I'm modeling a game where only some of the possible move outputs can be legal at a time, so I think it makes sense to smooth the labels among currently legal ...
0
votes
1answer
18 views

in TensorFlow 2.0, what is the different between LSTM and LSTMCell objects?

I am trying to implement an RNN in TensorFlow 2.0 (beta1). Looking at the layer functions (inherited from Keras) I found: tf.keras.layers.LSTM and ...
0
votes
0answers
13 views

Precision of quantized MobileNet v1 224 on CPU and Edge TPU

I am using a quantized MobileNet model for inference tests. I use an Coral Edge TPU and my CPU. For the Edge TPU I use the class ClassificationEngine. For the CPU I use the tensorflow lite interpreter....
1
vote
1answer
26 views

Acurracy = 0 using tensorflow on tabular data

I am new to machine learning and trying to apply this tutorial to my tabular data. My input is a pandas dataframe containing the features (I encoded the categorical columns as floats) and a pandas ...
2
votes
4answers
45 views

How to get high accuracy in CNNs?

ML and Data Science world. I am a newbie to CNNs, but do possess a basic understanding of ML and Neural Networks. I wanted to create my own CNN that works on the Cats and Dogs Dataset. I ...
0
votes
0answers
13 views

keras custom metric function how to feed 2 model outputs to a single metric evaluation function

I have an CNN object detection model which has two heads(outputs) with tensor names 'classification' and 'regression'. I want ...
0
votes
1answer
14 views

How can I use different loss functions for images with different labels in tensorflow?

I have two types of images, meaning two different sets of possible labels. How can I use two different loss functions based on which image I am currently training on with a batch size of 1? Thanks !
0
votes
0answers
9 views

Finetuning BERT

Referring to the PyTorch port by huggingface of the native BERT library, I want to fine-tune the generated model on my personal dataset containing raw text. Could you please point out how this can be ...
0
votes
0answers
15 views

How to use list of words as input column for Tensorflow?

One of my input columns is an array of words. What feature_column should I use to convert it to a tensor? Thank you.
1
vote
1answer
28 views

is there a way to customize my loss function to increase recall in one class only?

First, thank you. I'm using Tensorflow 1.13 with Python 3. I'm trying to create a CNN classifier on data with 4 classes, one-hot encoded. However, the insights I need it to produce are really around ...
1
vote
0answers
17 views

Tensorflow unnecessary imports?

I am working through a tutorial on neural style transfer with tensorflow and am trying to understand the basic canonical imports. First, we are presented with: ...
0
votes
0answers
13 views

Semantic Similarity in Universal Sentence Encoder

I am currently using Universal Sentence Encoder to embed certain sentences which I would then feed to a deep learning model to do some prediction, but just to test whether the universal sentence ...
0
votes
0answers
10 views

Tensorflow “canned” estimators unable to “see” that signficant signal is the ratio of two columns

I have an appropriate dataset composed of X,Y and a LABEL to be used for binary classification. When fed to a Tensorflow canned estimator (tf.estimator.LinearClassifier, I tried both Linear and DNN) ...
1
vote
1answer
20 views

install_tensorflow() keeps overwriting virtualenv, making it impossible to install tensorflow and keras

I would like to use the Keras & Tensorflow package for R in RStudio. Everytime I use the command install_keras() or install_tensorflow(), I get the following error: ...
0
votes
0answers
9 views

Converting our model to other formats

I am using NVIDIA platform for running some medical imaging workflows. I came to know that NVIDIA accepts model only in the below formats a) graph def b) saved model c) trt plans d) caffe netdefs ...
0
votes
1answer
14 views

How to get weightage of each factor for a prediction in a neural network classifier?

I am working on a model to predict which employee is going to resign from a firm. The dataset has columns like Date of Birth, Date of Joining, Department, Gender, Marital Status, Years at company etc. ...
1
vote
0answers
15 views

Can't save save/export and load a keras model that uses eager execution

I'm following the RNN text-generation tutorial with eager execution pretty much line for line. I've trained the model with my own data set and have saved a low loss checkpoint. I'm able to load the ...
1
vote
1answer
30 views

Is Categorical Crossentropy Loss always bounded in the [0, 1] interval?

Is Categorical Crossentropy always bounded between 0 and 1, or is it possible that during training of a Neural Network it can get higher values? More specifically, I'm referring to the TensorFlow 2.0 ...
0
votes
0answers
11 views

DLL load failed: The specified module could not be found. import Keras using backend tensorflow

System details: Windows 8.1 64bit Already all types of DLL files present in system32 and systemWOW64 and all required environment set correctly. Command details: On anaconda prompt pip install ...
2
votes
2answers
45 views

Are mini batches sampled randomly in Keras' Sequential.fit method()

When you .fit a Keras Sequential() model, you can specify a batch_size parameter. I have ...
0
votes
0answers
20 views

Feature engineering keywords for keras network

I am building a multi-label classifier, using the keras sequential API. My goal is to take an input of keywords 'cat', 'dog', 'rabbit' and apply a custom label. My ...
0
votes
1answer
30 views

Why such a big difference in number between training error and validation error?

Question Why such a big difference between my 'Train loss' and 'Validation loss' as shown in the picture below? Is it a signal that my codes are wrong and my trained network is wrong as well? Some ...
0
votes
1answer
19 views

how to use multiple generator in keras fit_generator()

I want to train the multi-input model on a set of images. I use ImageDataGenerator.flow_from_directory() and fit_generator in ...
0
votes
0answers
19 views

Help with Tensorflow 2.0 beta not learning

Have a tabular data set and have done some graphical exploration with Orange 3. Attempted NN regression with Keras/TensorFlow 2.0 beta on Python 3.6.7. The problem is that TF 2.0 is not "learning" (...
0
votes
0answers
21 views

Keras InvalidArgumentError With Model.Fit()

I am trying to call model.fit() on a sequential Keras model, but get this error: ...
0
votes
0answers
14 views

Reference for Inception-v2

The "Rethinking" paper doesn't describe the actual implementation of the Inception-v3 model in Tensorflow: an accurate description is written in model.txt in the source files of the paper in the arXiv....
0
votes
1answer
7 views

Intermittent type error when running CNN inside Docker container

I've been working on a simple computer vision API with a few endpoints for grabbing useful information from ebay images. The API lives in a docker container that looks for the h5 files, downloads ...
1
vote
0answers
19 views

scikitlearn MLPRegression model conversion to TensorFlow Dnnregressor conversion

I implement custom Neural Network (prediction part only) based on ScikitLearn MLPRegressor model weights with sklearn.preprocessing.StandardScaler normalization of input features Can I convert it ...
0
votes
1answer
26 views

My network optimises for mean_squared_error, but the predictions are useless

After going through the tutorials of tensorflow I decided to do my own project. For this I did the following: I have scraped movie reviews from a polish site called filmweb. I got a dataset o 5400 ...
1
vote
0answers
21 views

TensorFlow: how to restore pre-trained meta model and pass it's weights and biases to the optimizer?

I trained a model on a specific dataset and saved it as a meta, I want to restore the model and use its weights and biases on another dataset the code isn't mine but I'm trying to restore the ...
0
votes
1answer
24 views

Saving a different model for every epoch Keras

As part of a project I am currently running a CNN for classifying images. Right now I am training with 50 epochs. I have noticed that after around 20-30 epochs I reach the highest accuracy and then ...
0
votes
0answers
22 views

Deep learning: How to write pseudo algorithm for network architecture

How do I write pseudo algorithm for any deep learning model? I was going through few deep learning papers on graph and there is pseudo algorithm for network architecture, Example : That is overall ...
0
votes
0answers
17 views

How to find the False Positives per Image when using the Tensorflow Object Detection API

I have trained a Faster-RCNN Model using the Tensorflow Object Detection API on a custom dataset consisting of 10 classes. I have evaluated its performance and obtained the mAP and AP for each class. ...
2
votes
1answer
29 views

Cat Dog classifier in tensorflow, fundamental problem!

I am trying to build an image classifier for a set of images containing cats and dogs. I am very new to the dark art of creating Neural Network models. I have had success building models with Keras in ...
0
votes
0answers
13 views

let tensorflow or a other tool find a sorting algorithm based on features

Currently, a human gets a list of data that has rows and multiple columns with values that have to be sorted in a specific way. The unknown problem is the way that the human sorts the data. So now, we ...
0
votes
0answers
30 views

Concatenate vector to image (different dimensions)

I am currently working on my bachelor thesis on Facial Expression Recognition (FER) and I want to reproduce the results of a paper I have found using Tensorflow and Keras. Now as far as I understood, ...
2
votes
1answer
31 views

Prediction with tensorflow keras

I'm trying to predict age from a given picture. I built the model below but the problem is that I'm getting very large loss value with low ...
0
votes
1answer
16 views

Loss and val loss too big

I have a random vector with known pdf x and i'm trying to predict some behaviour y. I created a dataset containing (X,y), where X is a vector of D realizations of the VA X and y = (y1,y2). That is, ...
1
vote
1answer
24 views

How L2 regularization use to penalize weights in tensorflow?

I know that L2 regularization technique to used to reduce over-fitting and penalize large weights. In more than one place I saw that it used like the code below in tensorflow library: ...
1
vote
0answers
27 views

Residual Neural Network with 2D input data in tensorflow

I have a simple feedforward network to approximate a function $f(x,y)$. I'm interested in adding skip-connections to my network (i.e. ResNet). In 1D, it's fairly straightforward. Here's a code snippet ...
1
vote
1answer
95 views

Tensorflow F-RCNN first stage input and output strides

Trying to optimize performances on Tensorflow's faster_rcnn_resnet50 (from the model zoo), I'm currently working on understanding the full .config file they provide, and I'm having a hard time with ...
0
votes
1answer
25 views

How is the loss between actual and predicted labels being calculated?

Quoting from this example of Predicting movie review with BERT and Tensorflow, ...
0
votes
0answers
15 views

Print/plot keras neural network model and its activated neurons

I would like to print and plot my model and its activated neurons depending on the input. Similar to this video. Is there a library that already does this with a keras model?
0
votes
0answers
13 views

How to find prediction probability in given CNN in tensor flow?

I am very new in tenser flow. Lets assume I already have a trained convolution neutral network, now I give one new data to this CNN, and I want to see whats the prediction probability in each class. (...
0
votes
1answer
45 views

How do I perform weighted loss in multiple outputs on a same model in Tensorflow?

How do I perform weighted loss in multiple outputs on a same model in Tensorflow? This means I am using a model that is intended to have 3 outputs. I did this ...
0
votes
0answers
12 views

Keras: stream data from file

I often work with the Keras generator functions to stream images. Now I would like to stream csv files in a similar manner. I know that there are options to do ...
0
votes
0answers
30 views

An epoch step is taking too much time on GPU!

I am trying to train a CNN on phoneme recognition. My dataset is composed up of 50 Million sample, each sample has 120 feature (signal parameters). My input's shape is (11,120) and the target is a ...
2
votes
1answer
27 views

Creating a Object Detection model from scratch using Keras

I have a dataset containing 330 images which contain guns. Along with the images, I have a text file associated with each image file which contains, The number of objects ( guns ) in the image. ...
1
vote
0answers
19 views

How does TensorFlow differentiate over Gaussian parameters?

When using variational autoencoders it is common to use stochastic tensors after the encoder that will have any value sampled from a distribution (Gaussian, Bernoulli, ...). How does Tensorflow ...
0
votes
0answers
28 views

tf.keras.experimental.export_saved_model error: __init__() missing 1 required positional argument: 'feature_columns

Objective: I am trying to save my model in a .pb or .pbtxt format using tf.keras.experimental.export_saved_model(model, saved_model_dir) as described in the ...