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.
685 questions
0
votes
0
answers
64
views
TensorFlow + Gradio handwritten digit recognizer predicts incorrectly on Sketchpad input (but works on MNIST test set)
I'm building a handwritten digit recognition app using TensorFlow and Gradio. My model achieves ~97% accuracy on the MNIST test set. However, when I connect it to a Gradio Sketchpad interface to take ...
1
vote
1
answer
98
views
Improving loss but unchanging metrics in Transformer model
Setting:
I'm training a neural network for classification purposes. This neural network leverages a transformer-based architecture and leverages PU-learning. PU-learning is a setting where you solely ...
0
votes
0
answers
46
views
Recreating a CNN Architecture
I'm attempting to recreate a CNN architecture that predicts future trajectories based on historical paths. The implementation is defined in sections 2.3 and 2.4 of this paper. My data are sequences of ...
1
vote
0
answers
139
views
Which is better: tensorflow 2.3.0 with GPU or tensorflow 2.18.0 with only CPU? [closed]
What is the speed of running tensorflow 2.3.0 with GPU relative to tensorflow 2.18.0 with only CPU?
Hardware
Laptop: MacBook Pro 15-inch 2012 64-bit.
OS: Windows 10 Pro 22H2
Processor: Intel(R) Core(...
2
votes
1
answer
134
views
How to use differential-entropy as pre-processing?
I am currently working on implementing the model EEG_DMNet. For pre-processing it calls for using differential entropy like
$$
h(X) = -\int_{-\infty}^{\infty} p(x) \log p(x) \, dx
$$
Assuming the Data ...
1
vote
0
answers
55
views
Reproducing results from classic dropout paper [closed]
In the classic paper "Dropout: A Simple Way to Prevent Neural Networks from
Overfitting", there is a figure comparing the features learned by a one-layer autoencoder trained on MNIST with ...
1
vote
1
answer
552
views
The loss of VAE is negative. is it normal?
the function loss of VAE is :
...
0
votes
1
answer
159
views
Creating a CNN model for multi-output prediction where one target variable is categorical, and others are numeric
I want to create a simple CNN model for multi-output prediction. The predicted values are four numeric values (all between 0-1) and one categorical value (4 classes). When I try to create a model ...
0
votes
1
answer
518
views
Why not use input padding in the first attention block in transformer decoder
I was studying the transformer decoder code below in Keras/Tensorflow. It was not clear how they made making decisions.
In the first attention block below (self.attention_1), why did they use ...
1
vote
0
answers
48
views
Fluctuating validation accuracy with steady accuracy increase
I have four layers of CNN to predict Javanese script letter data. The training accuracy and loss monotonically increase and decrease respectively. But, my test accuracy starts to fluctuate wildly. I ...
1
vote
1
answer
143
views
How to use Activation Functions in Quantized Nerual Networks?
I want to understand how quantized networks can calculate activations like sigmoid and tanh. I stumbled over this question which mentions the implementation of TF-Lite Micro as an example. ...
0
votes
1
answer
312
views
RNN/LSTM networks on spectrograms underfitting massively - is the CNN encoder a prerequisite?
I am prototyping a pipeline on the FSDD dataset (audio/10-class classification); the audio data are loaded with librosa, 0-padded/trimmed to 0.5 sec (4000-dimensioned numpy vectors) each and converted ...
0
votes
1
answer
256
views
Best way to make an image classification model with dynamic image sizes
I'm working on a project where I need an image classification system, so I've decided to learn Tensorflow, and, after a week of study i've the following model:
...
1
vote
1
answer
2k
views
Single input - multiple outputs with different loss functions in Keras: how is the gradient computed?
I've implemented a neural network with single input - multiple outputs using Keras API. The general structure of the network is like in this figure:
Because each branch does a different task, I ...
0
votes
0
answers
137
views
Predict angle by linear loss
I'm trying to solve following nonlinear regression task: We got fixed point from which the bullet is released with some start speed v0 (value v0 changes each time). On the opposite side we generate ...
2
votes
1
answer
905
views
Threshold Tuning before or after parameter tuning?
My goal is to increase the F1 score of Class 1 by 1-2%.
I achieved this by changing the threshold from 0.5 to X using the precision recall curve when the dataset is imbalanced. I did this after I have ...
0
votes
0
answers
196
views
Is it possible to calculate an integral within a layer with tensorflow?
Is it possible to compute an integral within a layer in tensorflow and tensorflow probability? I have a simple MLP with a couple of dense layers and a concat layer.
...
2
votes
1
answer
86
views
How to classify unseen data as anomaly
I trained a CNN model with 6 different classes (labels are 0-5) and I am getting more than 90% accuracy out of it. It can correctly classify the classed. I am actually trying to detect anomaly with it....
1
vote
1
answer
1k
views
Predicting missing letters in a word
I am stuck with this machine learning problem.
For input, we have a word in which some letters are missing, e.g., word = 'in---m-nt'. Then we can make up to 6 guesses.
guess1 = 'e', then word = 'in--...
0
votes
2
answers
239
views
Understanding keras layer structure/notation
I am trying to understand the following keras model:
...
1
vote
0
answers
66
views
Data parallelism on multiple GPUs [closed]
I am trying to train a model using data parallelism on multiple GPUs. As I think, in data parallelism, we divide the data into batches, and then batches are deployed parallel. Afterward, the average ...
3
votes
1
answer
741
views
Best Loss Function for Shape Resemblance in Time Series
Basically, predicting future values step by step using past values and some covariates as a feature, using some LSTM, Conv layers from tensorflow. I started by using mean absolute percentage error as ...
0
votes
0
answers
209
views
why the local reparameterization trick only works only for fully connected networks?
i was reading this article on towarddatascience and at a certain point the author says
"An important difference is that local reparametrization works only for fully connected networks, while ...
1
vote
0
answers
255
views
Why does the CNN model accuracy vary too much when the dataset is the same?
I have been working on a project where I have a lot of time series data(3000 csv file) from 6 different devices and I am trying to convert those data to an image array so that I can use them in CNN to ...
2
votes
1
answer
3k
views
How should I train my CNN with a tiny dataset
I'm working on a problem where I aim to classify sections of a track made on the floor using tape, into either left turns, right turns or straight track.
I'm struggling creating a CNN that is not ...