New answers tagged

0 votes

Moving from macbook (without GPU) to linux system with Titan V, only getting a 4x speedup, what am I doing wrong?

This Medium article goes into some surprising performance benchmarking between an M1 and a Titan. M1 systems are very powerful. https://medium.com/macoclock/apple-neural-engine-in-m1-soc-shows-...
user avatar
0 votes

How to find the size of a tensor in bytes?

To do this in a line of code, use: size_in_bytes = encoding.nelement() * encoding.element_size() This multiplies the number of elements in your tensor by the size ...
user avatar
1 vote
Accepted

Reproduce Keras training results in Jupyter Notebook

Did you set the same random seed at each step? The seed works well for the first function, but then it is lost in the next ones because NumPy applies a global seed reset automatically. For example, ...
user avatar
1 vote

Features and LSTM

Did you normalize your data with a min-max scaler? LSTM is a complex neuron, and its size should be adapted enough to your data: very simple models could under-perform because LSTMs are not suited for ...
user avatar
0 votes

Odd error when training neural network with Keras - Error occurred when finalizing GeneratorDataset iterator

If it stops always after 36 epochs, it could be due to the data in input. You should check if the generated data has always the same dimension and same format, without any outlier (like an empty ...
user avatar
1 vote

Loss decreases, but Validation Loss just fluctuates

You have 250 images as training set, and you are using a model with millions of parameters... I'm pretty sure that your model is just memorizing the training set, aka you are overfitting. At this ...
user avatar
2 votes

How to stop deep learning speech model to not recognize stranger voice?

98% is too high: Your model might overfit actually. Did you apply a drop out of 0.1 or 0.2? On the other hand, is your model trained on stranger voices? Otherwise, if there is no existing training for ...
user avatar
2 votes
Accepted

Loss decreases, but Validation Loss just fluctuates

It looks like your model is overfitting: it's learning from the training dataset, but this learning doesn't apply to the test dataset. You can try to reduce the complexity of the model by simplifying ...
user avatar
  • 489
0 votes

Small difference in metrics in KERAS for the same model

I found explanation here: https://github.com/tensorflow/tensorflow/issues/29964 https://stackoverflow.com/questions/59118430/keras-model-evaluate-on-training-and-val-set-differ-from-the-acc-and-val-...
user avatar
1 vote

AttributeError: module 'tensorflow.python.keras.utils' has no attribute 'to_categorical'

As of tensorflow version 2.9.2, the correct import is: from tensorflow.python.keras.utils.np_utils import to_categorical
user avatar
0 votes

find the number of classes in Cifar-10 dataset

#number of classes len(np.unique(y_train))
user avatar
1 vote

How to further improve on overfitting?

This was an issue I was struggling with for over a week but the eventual problem seemed to be perhaps something in the way the function was done; Initially I used ...
user avatar
  • 111
2 votes
Accepted

Why can't I reproduce my results in keras using random seed?

Are you using a CPU or a GPU? If you are using a GPU, there is an additional source of randomness. To confirm this point, you can try to use TensorFlow with CPU only, or disable Cuda DNN but the model ...
user avatar
1 vote
Accepted

Would writing a decision tree algorithm in Pytorch or Tensorflow be faster than with Numpy?

Not directly, mostly because the structure of a decision tree doesn't lend itself to GPU parallelisation, and is better suited to CPUs. Even the most established decision tree algorithms use CPUs. ...
user avatar
  • 274
0 votes

How to serve deep learning model using tensorflow lite

First you need to convert you image to bitmap. Then covert your bitmap into a bytebuffer ...
user avatar
  • 1
0 votes

LSTM RNN regression: validation loss erratic during training

Try using a 'relu' activation function, it might help. Other than that, increase the batch size to check if the loss descent is smoother or not. Even though the graph is erratic, the overall trend of ...
user avatar
0 votes

Why do I get an OOM error although my model is not that large?

Coming here as this is a top google result for this issue, and reducing the batch size problem didn't help in my case. Here's my advice: If you are having this problem during training, my suggestion ...
user avatar
0 votes

Sub labelling of an object

Sounds like face segmentation is what you are looking for. This one looks pretty promising at first glance: https://github.com/zllrunning/face-parsing.PyTorch Does it improve inference efficiency? ...
user avatar
  • 2,319
1 vote

Tensorflow gpu not available for jupyter notebook

The nvidia-smi is not likely to show any usage of the GPU until you actually load something into it in your notebook. There are many reasons why the gpu is not detected in keras. The easiest solution ...
user avatar
0 votes

How to examine effect of variable not used in training a neural network

If you have df the dataset with all the columns df_train and df_test the datasets for train ...
user avatar
  • 489

Top 50 recent answers are included