Questions tagged [tensorflow]

A Python library for deep learning developed by Google. Use this tag for any on-topic question that (a) involves tensorflow either as a critical part of the question or expected answer, & (b) is not just about how to use tensorflow.

Filter by
Sorted by
Tagged with
0
votes
0answers
5 views

Does TensorFlow's Object Detection API models look at the whole image or only the bounded target?

I was wondering if CNNs, specifically the models/feature extractors offered in Tensorflow's Object Detection API, only train on the bounded box of the target image or if it considers the entire image ...
0
votes
0answers
5 views

How to get reproducible weights initializaiton in Keras? [migrated]

I set both numpy and tensorflow random seeds as suggested Generate some data - this part is reproducible, gives same results always Create a simple network and make a prediction (without training, ...
0
votes
0answers
14 views

Does the order matters for an LSTM? [closed]

working on a project where I have many observations with lagged values but the order of all the data is the following X1, X2, X3 , ... , Xn, X1(t-1), X1(t-2), X1(t-n),..., X2(t-1),X2(t-2) and so on, ...
0
votes
0answers
4 views

A2C in tensorflow not converging [closed]

There is clearly something wrong with my implementation of A2C. Here's a colab notebook that contains all the code below. I run the code past 1,000,000 frames and the reward does not change ~= -20 / -...
0
votes
0answers
14 views

Add k-means layer to Keras model

I'm using a GAN to generate pixel-art images. The structure follow the Tensorflow tutorial on how to do GAN closely. My network outputs gradient-rich images, which look like down-scaled photos rather ...
0
votes
0answers
6 views

Keras “index_array” referenced before assignment [closed]

I'm trying to make a DCGAN with Keras, but I'm running into an error when I try to train a combined model: ...
3
votes
1answer
31 views

correcting for extremely downsampled data: keras class_weight is hurting my model

I have an extremely imbalanced dataset (millions of times more negatives) for a binary classification NN model. I am aggressively downsampling solely for the purpose of making training time manageable,...
0
votes
1answer
23 views

Can I use the mse loss function along with a sigmoid activation in my VAE?

I have implemented a VAE with a mse loss for the reconstruction loss and a sigmoid activation in my last layer of the decoder. For my use-case the reconstructed images seemed fair. Most examples on ...
3
votes
1answer
53 views

accuracy decreases with number of folds in x-validation

I am running a Sequential model in Tensorflow for binary classification. I cross-validate it using sklearn's KFold with 50 folds. The strange thing is that the binary accuracy has a trend of ...
0
votes
0answers
8 views

How to reduce losses simultaneously in keras models with multiple outputs

I'm building a regression neural network with one input and two outputs. During the training process, I find there is a trade-off between the validation MAE the two outputs and it is difficult to ...
0
votes
0answers
4 views

Can the scale Struct2depth be recovered given the real focal length?

Recently I read a great paper, struct2depth. But as I noticed that the scale is normalized in this paper, I wonder: if one can recover the actual ...
1
vote
0answers
14 views

Transfer learning from pretrained NN model for non image sequential data

I have a standard numeric dataset where the predictors are sequential much like an NLP task (not sequenced longitudinally for RNN implementation) with multi-class response to build a classification ...
1
vote
1answer
22 views

What do the individual parts of the full name mean when something like ResNet-FasterRCNN is mentioned?

What i mean by the title is as follows: Say I went into Tensorflows Object Detection Model zoo and picked some model like, Faster R-CNN ResNet101 V1 1024x1024. My question is, what is the architecture ...
0
votes
0answers
10 views

Interpretation of Precision and Recall from Object detection API?

In given picture I have precision and recall value -1.000. What does this signify? Could someone please help me to interpret this results? Furthermore Can I calculate F1 score for this average ...
3
votes
0answers
42 views

Designing an ML model for solving nonograms

The Problem I am trying to create a model to solve nonograms. I want to solve nonograms of any size $N\times N$ where $ \mathbb{N} \ni N\leq 10$. (but actualy I will be happy with a fixed size for ...
0
votes
0answers
6 views

About a result of ms ssim

The above formula is from https://ieeexplore.ieee.org/document/1292216, the paper of ms-ssim. I calculated ms-ssim between two dummy images with this code: ...
0
votes
0answers
11 views

neural network for circle detection

I'm new to Neural Networks and I would appreciate any advice. I'm working with the raw data which can be visualized in the form of the image (32 pixels in the x direction and 128 pixels in the y ...
0
votes
0answers
6 views

Dice score Validation accuracy higher than training accuracy

I am using the unet model for fascia segmentation in tensorflow as: ...
2
votes
0answers
32 views

LSTM architecture for anomaly detection

I'm testing out different implementation of LSTM autoencoder on anomaly detection on 2D input. My question is not about the code itself but about understanding the underlying behavior of each network. ...
1
vote
1answer
21 views

definition of an epoch in the fit method in keras

I understand that one epoch is one pass through the training data. I'm training a CNN using the following lines of code ...
0
votes
0answers
10 views

How to predict integer sequence from multi feature real input of time series with lstm seq2seq

I’ve been struggling with the seq2seq problem for a while. I have multi feature input of timeseries, about 10 features(less after PCA, but it is not in main focus of the question) and I need to ...
0
votes
1answer
15 views

How to build a model for multistep prediction when input sequence length and target sequence length are not equal?

I want to input a sequence of length 60 (time steps) and I would like to use it for predicting a sequence of length 20. So, I built the following model: ...
0
votes
0answers
13 views

Machine learning methods for filtering noisy data

I have my data (hear beat) cleaned up with the appropriate filter, however, they are still noisy and need to extract a clean pattern. Which is the best algorithm for this purpose? I have also clean ...
0
votes
0answers
18 views

Model and CV setup for structural timeseries forecast

I'm attempting to use tensorflow-probability's structural timeseries forecast tools, but I'm running into memory allocation problems and the trainings seem to last quite long, so I'd like to check if ...
0
votes
0answers
31 views

model.evaluate result differs from tf.keras.losses.MSE when using tf.data.Dataset

I am training the following RNN for univariate time series forecasting. Data are obtained from a pandas dataframe and converted into a tf.data.Dataset structure, ...
0
votes
0answers
13 views

How to cluster similar images with tensorflow?

I have a set of photographs and I would like to cluster based on their similarity in order to identify the ones that look alike and eventually select the best one among each cluster. I would like to ...
0
votes
0answers
9 views

Improving the performance of a machine learning model on examples it has not been trained on

I'm working on generating 3D representations of objects based on images of said objects. So far I've trained 3 models with an adapted version of this code. Each model was trained on a distinct dataset ...
0
votes
1answer
65 views

Finding the perplexity of multiple examples

I am trying to find a way to calculate perplexity of a language model of multiple 3-word examples from my test set, or perplexity of the corpus of the test set. As the test set, I have a paragraph ...
0
votes
0answers
11 views

How are activation functions calculated in quantized Neural Networks

I seem to be missing how activation functions are calculated in a fully integer quantized Neural network. I understand that when performing inference, the input tensor is scaled to the closest ...
0
votes
0answers
8 views

What can I do against oscillating validation accuracy in CNN?

I'm training a convolutional neural network and am seeing the issue that my validation accuracy is oscillating a lot. I'm seeing some oscillating on the training accuracy too but by far not as much. ...
0
votes
1answer
29 views

How does Tensorflow compute SparseCategoricalCrossentropy?

The expression for categorical cross-entropy loss can be obtained via the negative log likelihood. In particular, let $C$ be the number of mutually exclusive classes in a multi-class classification ...
0
votes
0answers
20 views

Model Architectures for functional graph or data series type data regression problems using PyTorch, FastAi or TensorFlow

For a university assignment, I am currently trying to build an optical sensor to supervise chemical reactions in pipes. Two sensors are installed in the pipe, around 1mm apart from each other, and ...
6
votes
1answer
232 views

On solving ode/pde with Neural Networks

Recently, I watched this video on YouTube on the solution of ode/pde with neural network and it motivated me to write a short code in Keras. Also, I believe the video is referencing this paper found ...
0
votes
0answers
47 views

Using pretrained LSTM and Bert Models in CPU Only Environment - How to speed up Predictions?

I have trained two text classification models using GPU on Azure. The models are the following Bert (ktrain) Lstm Word2Vec (tensorflow) Exaples of the code can be found here: NLP I saved the models ...
0
votes
0answers
14 views

latency not decreased tf-lite post training quantization

I am using efficient-net to classify images. I have trained model successfully and wanted to quantize it using tf-lite. I tried all the methods available in tf-lite quantization to check accuracy, ...
3
votes
1answer
31 views

Padding a time series for neural networks during cross validation

I am trying to train a neural network on some time series data and decided to implement cross validation for my model. The cross validation method I'm trying to implement is the Day Forward-Chaining ...
1
vote
1answer
36 views

LSTM input and output parameter (not time series, not NLP)

I have asked this question on stackoverflow but nobody answers. So I come here in the hope that somebody could help me solve it. Thank you! Here is my question: I am a little bit confusing about how ...
0
votes
3answers
72 views

What is the ppf of the truncated normal distribution?

What is the percent point function (ppf), or inverse cdf, of the truncated normal distribution? The distribution and cdf is defined here: https://en.wikipedia.org/wiki/Truncated_normal_distribution $$...
2
votes
0answers
95 views

High resolution in style transfer

I'm investigating a bit about neural style transfer and its practical applications and I've encountered a major issue. Are there methods for high resolution style transfer? I mean, the original Gatys' ...
0
votes
0answers
17 views

Why an increasing validation loss and validation accuracy signifies overfitting?

When I train a neural network, I observe an increasing validation loss, while at the same time, the validation accuracy is also increased. I have read explanations related to the phenomenon, and it ...
0
votes
0answers
26 views

Actions to take to improve validation accuracy [duplicate]

I am training a CNN model which takes input of 128x128x3 color images and is trained to predict the coordinates of ...
1
vote
1answer
32 views

NLP Emotion Detection - Model fails to learn to recognize negations

I am working on a nlp emotion detection project. The emotions that I try to predict are 'joy', 'fear', 'anger', 'sadness'. I used some publicly available labeled datasets to train my model e.g. ISEAR, ...
2
votes
1answer
46 views

how is tensorflow reduce_sum finding the intersection in the below code for dice coefficient?

In the below code I am not able to grasp how multiplying y_true and y_pred and putting reduce_sum on it gives the intersection between the two ...
0
votes
0answers
13 views

DL model for solving a multi-class classification problem works fine for the first class and then the performance gradually drops for other classes

I designed an AE shaped deep neural network to perform a multi-label class classification. The classes are not mutually exclusive. The last layer has n neurons; one responsible for each class. I pass ...
0
votes
0answers
22 views

multi-label classification in keras with huge number of classes

I have a training data of shape (100000,1200) and associated classes of size 3000. i.e, each sample has 1200 features and has to be mapped to one of the 3000 classes. How many hidden layers are ...
0
votes
0answers
48 views

Tensorflow Hidden Markov model

A decoding HMM has 3 parameters. But I am bit confused in tensorflow's HMM parameters and I'm not clear with docs https://www.tensorflow.org/probability/api_docs/python/tfp/distributions/...
0
votes
0answers
11 views

How to use tensorflow's module HiddenMarkovModel in pos tagging?

I want to do part-of-speech tagging using HMM. I want to use tensorflow module for viterbi algorithm. I know HMM takes 3 parameters Initial distribution, transition and emission matrix. But don't know ...
0
votes
0answers
13 views

How to implement text autoencoder for outlier detection?

I have a imbalanced text dataset, with distribution of the classes like this: ...
1
vote
1answer
27 views

Why does my Deep Learning Network converge to mean value of series when trying to fitting & predicting a time series?

There's a task requiring me to predict selling price of a product with provided external data containing historical purchasing prices and selling prices of competitors(positive correlated). ...
0
votes
0answers
9 views

How to construct input dependent convolutional filter (kernel)?

I am constructing a convolutional variational autoencoder for images, starting out with mnist digits. Typically I would specify convolutional layers in the following way: ...

1
2 3 4 5
13