Category "deep-learning"

How to do gradient clipping in pytorch?

What is the correct way to perform gradient clipping in pytorch? I have an exploding gradients problem.

When using padding in sequence models, is Keras validation accuracy valid/ reliable?

I have a group of non zero sequences with different lengths and I am using Keras LSTM to model these sequences. I use Keras Tokenizer to tokenize (tokens start

One box object detection

I am using a faster rcnn model to predict one object in an image. There can only be one object in each image. Is it possible to force Faster Rcnn to train and p

Continual pre-training vs. Fine-tuning a language model with MLM

I have some custom data I want to use to further pre-train the BERT model. I’ve tried the two following approaches so far: Starting with a pre-trained BER

AWS Lambda running tensorflow packages exceed limit 250 MB

I need to do a segmentation prediction for a tensorflow-keras model. My idea was to upload an image into an S3 bucket, and with the AWS Lambda service, trigger

UnimplementedError: Graph execution error: running nn on tensorflow

I have been having this error, and I don't know why, especially since I am following someone's code exactly and the person had no error when running this img_sh

tensorflow model.evaluate and model.predict very different results

I am building a simple CNN for binary image classification, and the AUC obtained from model.evaluate() is much higher than AUC obtained from model.predict() + r

How to save the model weights after running train_detector in mmdetection?

cfg.optimizer.lr = 0.02 / 8 cfg.lr_config.warmup = None cfg.log_config.interval = 600 # Change the evaluation metric since we use customized dataset. cfg.evalua

keras.utils importError in Colab cannot import name "to_categorical"

I'm using Google's Colab to run the Deep Learning codes from the Book " Deep Learning with python" by François Chollet. The 1st exercise is to use the mn

Reshape the input for BatchDataset trained model

I trained my tensorflow model on images after convert it to BatchDataset IMG_size = 224 INPUT_SHAPE = [None, IMG_size, IMG_size, 3] # 4D input model.fit(

What and where am I going wrong in this code for pytorch based object detection?

I am using Yolov5 for this project Here is my code import numpy as np import cv2 import torch import torch.backends.cudnn as cudnn from models.experimental impo

Interpreting loss and metric curve

I am trying to train Unet model with the following parameters: droput_: 0.2, activation_: sigmoid, activation_inner_: relu, learning_rate_: 0.0001, epsilon_: 1

A `Concatenate` layer requires inputs with matching shapes except for the concatenation axis. Received: input_shape=[(None, 28), (None, 28, 28)]

""" Defining two sets of inputs Input_A: input from the features Input_B: input from images my train_features has (792,192) shape my train_images has (792,28,28

input_image_meta shape error while using pixellib custom trainig on images

I am using pixellib fot training custom image instance segmentation. I have created a dataset whiche can be seen below in link. Dataset:https://drive.google.com

How to decorate a function that takes a tf.variable as a parameter with tf.function and most importantly using input signature

I have a problem where I need to modify a variable inside a Tensorflow function. Then I need to convert this function to a tensorflow graph. The problem is that

How do I remove nonsensical or incomplete words from a corpus?

I am using some text for some NLP analyses. I have cleaned the text taking steps to remove non-alphanumeric characters, blanks, duplicate words and stopwords, a

CNN model accuracy fluctuates

Tensorflow/Keras I have developed a CNN model to classify images as circle, triangle or square. However, my accuracy values have wide fluctuations. Is it someth

How i can extracte x_train and y_train from train_generator?

In my CNN model I want to extract X_train and y_train from train_generator. I want to use ensemble learning, bagging and boosting to evaluate the model. the mai

How to use the output of a CNN as the input of another in an autonomous vehicle

I am developing a mini autonomous car using 3 CNNs and a camera sensor using this approach. One of the CNNs detects lanes on the images and outputs images wit

ValueError: Please initialize `TimeDistributed` layer with a `Layer` instance

I'm trying to build a model which can be trained on both audio and video samples but I get this error ValueError: Please initialize `TimeDistributed` layer with