Issue I am trying to setup a non-linear regression problem in Keras. I have two sets of data say X1 and X2 whose Y values have a similar mean and standard deviation. The following procedure was under taken: Combine the
Continue readingTag: neural-network
Error while training a basic network in caffe using ImageData layer
Issue I am trying to get started training a network for image classification using Caffe. I would like a solver to train a model using data of my own. I am using an “ImageData” layer and I prepared a ‘file_lists.txt’
Continue readingValueError: Cannot feed value of shape (128, 28, 28) for Tensor 'Placeholder:0', which has shape '(?, 784)'
Issue I am new to Tensorflow and Machine Learning and trying out CNN using Tensorflow with my custom input data. But I am getting the error attached below. The Data or Image Size is 28×28 with 15 Labels. I am
Continue readingRunning model in custom Data Set(2 classes) error in testing phase (MXNet framework)
Issue i am running a model for my own data set(the project was implemented for training/testing with ImageNet) with 2 classes. I have made all the changes (in config files etc) but after training finishes(successfully), i get the following error
Continue readingData sets for neural network training
Issue I am looking for some relatively simple data sets for testing and comparing different training methods for artificial neural networks. I would like data that won’t take too much pre-processing to turn it into my input format of a
Continue readingWhat's the purpose of nb_epoch in Keras's fit_generator?
Issue It seems like I could get the exact same result by making num_samples bigger and keeping nb_epoch=1. I thought the purpose of multiple epochs was to iterate over the same data multiple times, but Keras doesn’t reinstantiate the generator
Continue readingNeural Network Underfitting with Dogs and Cats
Issue Without necessarily getting into the code of it, but focusing more on the principles, I have a question about what I assume would be underfitting. If I am training a network that recognizes true or false as to whether
Continue readingEffect of learning rate on the neural network
Issue I have a dataset of about a 100 numeric values. I have set the learning rate of my neural network to 0.0001. I have successfully trained it on the dataset for over 1 million times. But my question is
Continue readingTensorboard bump in accuracy score
Issue I have been training my Inception ResNet V2 using Tensorflow, and logging the accuracy/loss etc. via TensorBoard. Now when I resumed training today, almost instantly (in a few global steps) my accuracy bumped from 86% to 97%, when resuming
Continue readingAvoiding overfitting while training a neural network with Tensorflow
Issue I am training a neural network using Tensorflow’s object detetction API to detect cars. I used the following youtube video to learn and execute the process. https://www.youtube.com/watch?v=srPndLNMMpk&t=65s Part 1 to 6 of his series. Now in his video, he
Continue readingScale training set by inverse standard deviation using python
Issue I am using python and have a training set of data that i need to ‘subtract the mean and scale by inverse standard deviation’. Subtracting the mean would just be subtracting the mean from each value in each column
Continue readingTorch – Using optim package with CNN
Issue I am trying to train a CNN using optim package. I am using this code, obtained from a video tutorial (see around 24:01), as a reference. This particular example uses a normal neural network. I also used this reference.
Continue readingDoes TensorFlow optimizer minimize API implemented mini-batch?
Issue Does Tensorflow minimize API for, say GradientDescentOptimizer implement mini-batch already when we feed the input tensor with a minibatch size of data? I was reading this bolg which indicated that the minibatch is not implemented in the minimize method,
Continue readingSimultaneous training and testing in Tensorflow
Issue I am trying to perform training and testing of a neural network in Tensorflow in the same script, same graph, same session. I read that it is possible, however when I look at the accuracy/loss results from the training
Continue readingHow to use a trained Neural Network?
Issue I’m trying to understand the logic behind the use of a trained Neural Network. If I’m right : we should save the weights from the previous training, then, reload them with the new input. For example, I have this
Continue readingwhat the bars in keras training show?
Issue I am using keras and part of my network and parameters are as follows: parser.add_argument(“–batch_size”, default=396, type=int, help=”batch size”) parser.add_argument(“–n_epochs”, default=10, type=int, help=”number of epoch”) parser.add_argument(“–epoch_steps”, default=10, type=int, help=”number of epoch step”) parser.add_argument(“–val_steps”, default=4, type=int, help=”number of valdation step”)
Continue readingAccuracy from sess.run(() is returning the value in bytes. How can I change to value?
Issue I am new to CNN and tried to train the CNN model. However when I try to print the accuracies returned from cnn it gives me results in bytes format like b’\n\x11\n\naccuracy_1\x15\x00\x00\x80<‘. However when I try to print the
Continue readingRearrange array into a form suitable for NN training
Issue I am working on a large dataset that I need to convert to a specific format for further processing. I am looking for advice in this regard. Sample input: A = [0.99 -0.99 1 -1 0.55 -0.55] Sample output:
Continue readingHow to fix hopfield library errors in python
Issue I have some code about hopfield network. I am trying to train some letters with hebbian training and then add noise and denoise them. However, I have problem with libraries. I did a search but I cant find the
Continue readingCorrect practice and approach for reporting the training and generalization performance
Issue I am trying to learn the correct procedure for training a neural network for classification. Many tutorials are there but they never explain how to report for the generalization performance. Can somebody please tell me if the following is
Continue readingHow to override a method and chose which one to call
Issue I am trying to implement Neural Network from scratch. By default, it works as i expected, however, now i am trying to add L2 regularization to my model. To do so, I need to change three methods- cost() #which
Continue readingHow to override a method and chose which one to call
Issue I am trying to implement Neural Network from scratch. By default, it works as i expected, however, now i am trying to add L2 regularization to my model. To do so, I need to change three methods- cost() #which
Continue readingThe dilemma of overfitting in NN training
Issue My question is in continuation to the one asked by another user: What's is the difference between train, validation and test set, in neural networks? Once learning is over by terminating when the minimum MSE is reached by looking
Continue readingSplit dataset into training and test by month
Issue I was not able to find the answer to this anywhere. I have data for three months, where I would like to split it into the first two months(‘Jan-19’, ‘Feb-19’) as training set and the last month as the
Continue readingwhy the `test process` is inside the epoch loop in deep learning?
Issue I am new to deep learning, here is the code I saw The code is fine, but I don’t understand the follow: for epoch in range(1, args.epochs + 1): train(epoch) test(epoch) with torch.no_grad(): sample = torch.randn(64, 20).to(device) sample =
Continue readinginitialization neural network model kfold
Issue I initialized the network model before the k-fold starts. Does that mean that the model trains for the first fold and this model with the trained weights is taken for the second fold and so on? What if the
Continue readingRelationship between training accuracy and validation accuracy
Issue During a CNN model training, I noticed various behaviour in between training and validation accuracy. I understand that ‘The training set is used to train the model, while the validation set is only used to evaluate the model’s performance…’,
Continue readingtensorflow: batches of variable-sized images
Issue When one passes to tf.train.batch, it looks like the shape of the element has to be strictly defined, else it would complain that All shapes must be fully defined if there exist Tensors with shape Dimension(None). How, then, does
Continue readingHow does training a neural network using a metaheuristic like PSO work?
Issue I want to learn a bit more about other approaches to training neural networks and I can find a fair bit of literature on GA training a network but not much on PSO training. How does that work? I
Continue readingtraining by batches leads to more over-fitting
Issue I’m training a sequence to sequence (seq2seq) model and I have different values to train on for the input_sequence_length. For values 10 and 15, I get acceptable results but when I try to train with 20, I get memory
Continue readingCan neural networks handle redundant inputs?
Issue I have a fully connected neural network with the following number of neurons in each layer [4, 20, 20, 20, …, 1]. I am using TensorFlow and the 4 real-valued inputs correspond to a particular point in space and
Continue readingWhy not optimize hyperparameters on train dataset?
Issue When developing a neural net one typically partitions training data into Train, Test, and Holdout datasets (many people call these Train, Validation, and Test respectively. Same things, different names). Many people advise selecting hyperparameters based on performance in the
Continue readingPyTorch DataLoader shuffle
Issue I did an experiment and I did not get the result I was expecting. For the first part, I am using trainloader = torch.utils.data.DataLoader(trainset, batch_size=128, shuffle=False, num_workers=0) I save trainloader.dataset.targets to the variable a, and trainloader.dataset.data to the variable
Continue readingInteresting results from LSTM RNN : lagged results for train and validation data
Issue As an introduction to RNN/LSTM (stateless) I’m training a model with sequences of 200 days of previous data (X), including things like daily price change, daily volume change, etc and for the labels/Y I have the % price change
Continue readingSyntaxError: invalid syntax when training a neural network model
Issue I am trying to train a model (https://github.com/bmild/nerf), and I am getting the error below when I run this code. The part of the code is: def recenter_poses(poses): poses_ = poses+0 bottom = np.reshape([0,0,0,1.], [1,4]) c2w = poses_avg(poses) c2w
Continue readingTypeError: 'int' object is not iterable while training a neural network
Issue I am trying to train NeRF (https://github.com/bmild/nerf), below is the error I am getting. I have tried to print the datatype of the of the variables. I do not know how to proceed next. Here is a code snippet:
Continue readingwhat does class_mode parameter in Keras image_gen.flow_from_directory() signify?
Issue train_image_gen = image_gen.flow_from_directory(‘/Users/harshpanwar/Desktop/Folder/train’, target_size=image_shape[:2], batch_size=batch_size, class_mode=’binary’) In the above code snippet what does class_mode=’binary’ signify. I think it is for the number of categories of images. I am using this code for training a image recognition classifier in Keras
Continue readingBinary classification not training correctly
Issue I’ve been working on a neural network that can classify two sets of astronomical data. I believe that my neural network is struggling because the two sets of data are quite similar, but even with significant changes to the
Continue readingWhy does a 50-50 train/test split work best for a data-set of 178 observations with this neural network?
Issue From what I’ve read, it appears that a split of around 80% training 20% va validation data is close to optimal. As the size of the testing dataset increases, the variance of the validation results should go down at
Continue readingpyTorch mat1 and mat2 cannot be multiplied
Issue I am getting the following error: RuntimeError: mat1 and mat2 shapes cannot be multiplied (32×33856 and 640000×256) I don’t understand how do I need to change the parameters of my net. I took the net created in this paper
Continue readingK-fold Cross-Validation – initialise network after each fold or not?
Issue I mostly understand how k-fold cross-validation works and have begun implementing it into my MATLAB scripts, however I have two questions. When using it to select network features (hidden units, weight decay prior and no. iterations in my case).
Continue readingPredictions become irrational after adding weights to the fit
Issue I have a model with several dense layers that behaves normally in all aspects. Then, I add weights to the training events (their values are between 0 and 1): w = mydata.Weight #… kfold = GroupKFold(n_splits=num_folds) for train, test
Continue readingPyTorch NN not training
Issue I have a bespoke NN model which works and wanted to move it to the PyTorch framework. However, the network is not training likely due to some misconfiguration. Please advise if you see something that is odd/wrong or could
Continue readingTrain Accuracy increases, Train loss is stable, Validation loss Increases, Validation Accuracy is low and increases
Issue My neural network trainign in pytorch is getting very wierd. I am training a known dataset that came splitted into train and validation. I’m shuffeling the data during training and do data augmentation on the fly. I have those
Continue readingSolving the parity 3 classification using functional link neural network?
Issue I am trying to solve the 3-bit parity problem using the functional link neural network (Pao,1988). I am performing backpropagation to update the weights and extended the input using the outerproduct model proposed by Pao, ie. x1,x1x2,x1x3,x2x3,x1x2x3 is the
Continue reading