Why do sometimes CNN models predict just one class out of all others?

I am relatively new to the deep learning landscape, so please don’t be as mean as Reddit! It seems like a general question so I won’t be giving my code here as it doesn’t seem necessary (if it is, …

Bounding box detection for characters / digits

I have images, which look like the following: I want to find the bounding boxes for the 8 digits. My first try was to use cv2 with the following code: import cv2 import matplotlib.pyplot as plt …

converting xavier to glorot in tensorflow code

I am trying to convert xavier initializer in a tensorflow code to glorot initializer. I am not sure which one of the following (or other options) is correct? #initializer = tf.contrib.layers….

Keras my_layer.output returning KerasTensor object instead of Tensor object (in custom loss function)

I’m trying to build a custom loss function in Keras v2.4.3: (as explained in this answer) def vae_loss(x: tf.Tensor, x_decoded_mean: tf.Tensor, original_dim=original_dim): z_mean = …

ValueError when using vae.fit in Keras

I am creating a vae model over the mnist dataset with hopes of plotting the loss function against the epochs. However I am experiencing some issues and was unable to find a solution online. During my …

Neural Network loss is significantly changing for same set of weights – Keras

model = keras.Sequential([ layers.Dense(10, activation = ‘relu’, weights=[zero_weights, zero_bias]), layers.Dense(24, activation = ‘relu’, weights=[one_weights, one_bias]), layers.Dense(12, …

Building wheel for neural-renderer-pytorch (setup.py) …installing multiperson and neural mesh renderer doesn’t work for pytorch 1.6

I am trying to install a github repo named multiperson for PyTorch 1.6 and I get the following error. How can I make it work for PyTorch 1.6? (base) mona@mona:~/research$ cd phosa/ (base) mona@mona:~/…

ValueError: You have to specify either decoder_input_ids or decoder_inputs_embeds

Trying to convert a question-generation t5 model to torchscript model, while doing that Running into this error ValueError: You have to specify either decoder_input_ids or decoder_inputs_embeds here’s …

Tensorflow 2.3, Tensorflow dataset, TypeError: () takes 1 positional argument but 4 were given

I use tf.data.TextLineDataset to read 4 large files and I use tf.data.Dataset.zip to zip these 4 files and create “dataset”. However, I can not pass “dataset” to dataset.map to use …

Ensemble with voting in deep learning models

I am working on a multimodal deep learning classifiers with RGB-D images. i have developed two seperate models for each case. The first one is a LSTM with CNN in the begining for the RGB images with …