neural-network

Deploying a Tensorflow model, getting an error

断了今生、忘了曾经 提交于 2019-12-24 17:17:22
问题 I am importing my trained Tensorflow model to android. I saved my input and output tensors, namely "input" and "y_", respectively. This is my code in Android Studio: private static ActivityInference activityInferenceInstance; private TensorFlowInferenceInterface inferenceInterface; private static final String MODEL_FILE = "file:///android_asset/optimized_har.pb"; private static final String INPUT_NODE = "input"; private static final String[] OUTPUT_NODES = {"y_"}; private static final String

Neural Network sigmoid function

女生的网名这么多〃 提交于 2019-12-24 17:14:13
问题 I'm trying to make a neural network and I have a couple of questions: My sigmoid function is like some s = 1/(1+(2.7183**(-self.values))) if s > self.weight: self.value = 1 else: self.value = 0 The self.values is a array of the connected nodes, for instance the HNs(hidden nodes) in the HL(hidden layer) 1 is connected to all input nodes, so it's self.values is sum(inputnodes.values). The HNs in the HL2 is connected to all HNs in HL1, and it's self.values is sum(HL.values) The problem is, every

How many images can you pass to Caffe at a time?

流过昼夜 提交于 2019-12-24 17:04:18
问题 I noticed how the Caffe MNIST example prototxt file allows for up to 64 images to be passed to the network at a time. Is there a limit for how high I can set this number? Could I (for example) set this number to 200 or even 500 so that I can accept up to 200/500 images at a time without it impacting the predictions negatively? 回答1: The only limit is your machine's memory: When caffe loads the model it allocates memory for all the parameters and all the intermediate data blobs. The more images

Neural Network for regression

好久不见. 提交于 2019-12-24 16:37:06
问题 The way I understand regression for neural networks is weights being added to each x-input from the dataset. I want something slightly different. I want weights added to the function that computes each x-input we'll call these s-inputs The function to compute the x-inputs is a summation function of all s-inputs I want each s-input to have its own weight So I say regression because I want the end result to be a beautiful continuous function between the mapping x -> y ...but that is

Neural Network for regression

扶醉桌前 提交于 2019-12-24 16:36:01
问题 The way I understand regression for neural networks is weights being added to each x-input from the dataset. I want something slightly different. I want weights added to the function that computes each x-input we'll call these s-inputs The function to compute the x-inputs is a summation function of all s-inputs I want each s-input to have its own weight So I say regression because I want the end result to be a beautiful continuous function between the mapping x -> y ...but that is

Hand written character recognition using neural network

穿精又带淫゛_ 提交于 2019-12-24 15:24:17
问题 i need some guide lines and help to develop this ANN. i don't have any past experience with neural networks and this is little bit hard for me. i want to recognize handwriting using this.. any help would be nice.. :-| 回答1: This is an open source c# OCR: http://neurondotnet.freehostia.com/samples/ocr.html 来源: https://stackoverflow.com/questions/6403287/hand-written-character-recognition-using-neural-network

Error check in Feedforward Neural Network

好久不见. 提交于 2019-12-24 14:38:57
问题 Is it possible that the error for my network decreases, then increase again? Just wanna check if i'm coding the right way. 回答1: Yes, it is possible for the error to temporarily increase. This is because you aren't testing one input and expected output all the time (and you shouldn't, because then the network will be specialized for that particular input-output set). The neural network does not implicitly "know" that it is going in the right direction. You are basically traversing the error

Keras: 2D input -> 2D output?

风格不统一 提交于 2019-12-24 13:29:56
问题 I want to build a neural network to learn a set of standard feature vectors. The set is thus of shape (N,100), where N is the number of samples. However, set of labels is of shape (Nx18) (e.g. each "label" is another array of 18 elements). I'm quite new to keras and neural nets, and I only know how to deal with the label when it is one dimensional (e.g. 0 or 1 in binary classification). How do I can deal with multi-dimensional output? Thanks! 回答1: Maybe I don't completely understand the

Encoding large numbers of categorical variables as input data

▼魔方 西西 提交于 2019-12-24 12:44:21
问题 One hot encoding doesn't sound like a great idea when you're dealing with hundreds of categories e.g. a data set where one of the columns is "first name". What's the best approach to go about encoding this sort of data? 回答1: I recommend the hashing trick: https://en.wikipedia.org/wiki/Feature_hashing#Feature_vectorization_using_the_hashing_trick It's cheap to compute, easy to use, allows you to specify the dimensionality, and often serves as a very good basis for classification. For your

Neural network doesn't return values below 0.5 with logsig

白昼怎懂夜的黑 提交于 2019-12-24 12:35:13
问题 I want to classify two classes with a neural network. Since outputs are 0 or 1, I am using (or trying t use) 'logsig' for the output function. My problem is that when I do that, my simulations end up being between 0.5 and 1. As if everything entering the logsig function was positive. PS: My training set and my testing set are composed of normalized values. Here is what I do: t = [0.8*ones(1,50) 0.2*ones(1,50)]; %define net net = newff(trainSet,t,n,{'tansig','logsig'},'trainscg'); net