sorry,the title may be confusing,
the thing is , I have trained two network.
one is to classify the gender of gorilla
another one is to classify the gender of human
Then,I want to train another network to classify the gender of primate animals.
So, how can I make up a new network from those two existed networks?
because as we know,human and gorilla are one kind of primate animals.
this new network must know further semantic meaning of gender based on those two existed networks
is it fine that just simply input gorilla data and human data to train this new network? or it is a dumb way?
Thank you, any response is good for newbie :)
Since both human and gorilla are primates, their data is suitable for the training of a network for classifying genders of primates. However, as mentioned at http://neuralnetworksanddeeplearning.com too much similar data may lead to low prediction rates for other data.
Related
I am working on a text classification problem for which I cant think of or find a solution. Essentially I am classifying a private complaint database which has custom categories per municipality this because some municipalities have other issues than others.
Example:
Mun. Issue Class
London Street lights are off Street-lighting
New York Street lights are off lighting
As you can see, I want to classify the issue based on the municipality, thus based on the first column select only the specific categories of that municipality and then choose the one which is classified by the issue. Currently I created superclasses which contains similar classes but now I want to be more specific. I have a big dataset and every municipality has around 10 classes.
You can use a normal classification algorithm with a neural net. steps would be:
1. Create the corpus into One hot vector
2. Train the neural network as multiclass classification
I think any normal neural network with a sufficient number of neurons can provide the results.
Am trying to solve the question:
A person might or might not like steaks, but that statistically depends on the person's age, ethnicity, gender, etc. A steak loving person might like their steaks from 0% cooked to 100% cooked, and seasoned with an arbitrary amount of salt. All these also depends on the person's age, ethnicity, gender, etc.
I want ML to predict the following:
Given a person's age, ethnicity, gender, etc, whether this person will like steaks or not. And if they like steaks, how they want their steaks to be cooked, and how much salt they will like to put on their steak.
I realize I can break this problem down into two neural networks, one binary classification and one multidimensional regression.
The first network will answer if the person likes steaks or not. If the person doesn't like steaks at all, there is no point generating outputs for the second network. But if the answer is yes, I can feed the subset of the dataset to the second network, then it will answer the whats.
However, what I don't understand is:
Is it possible to chain the two networks together to form a single network? In a sense the output contains a Yes/No answer plus the answers for the regression network.
If answer is yes, is it faster than running two separate networks considering the dataset to the second network might be smaller?
Again, if answer is yes, how do I go about to implement this? Using 2 hidden layers with different loss functions? How many nodes for each layer? What is the activation function for each layer?
I haven't tried that myself yet, but you can try and let us know if it is going to work.
As meat can cooked from 0% to 100% (although not sure who would eat steak raw) but I would use regression to estimate steak with from -1 to 100, where -1 means does not like steak at all and all other numbers how much they want it cooked
Hmmm, Interesting problem.
This is not a two classification + regression problem, it is a classification + optimisation model.
You need to build a model which will be able to predict if he likes the steak or not. Then you will try to maximum the probability of he liking steak by using the above machine learning as function you by tuning variables(cooking level, spice etc). This can be a generic brute force or a proper optimisation problem.
To answer to you questions:
You should better use a pipeline in your case, with two algorithms : a binary classification algorithm first, and then a prediction algorithm. Splitting a problem into two distinct parts, when possible, is good practice, and provide better results.
Several points to mark here :
First of all, neural networks do NOT work for every machine learning problem. Here for example you should better use other algorithms.
For the binary classification (i.e. like or does not like steaks), I would not use neural networks but rather SVM or Logistic Regression (SVM is good for binary classification).
For the second part, you need to find values (i.e. how much salt people use, what percentage of cooking they prefer), so you should use a prediction algorithm, and not neural network, which is a classification one. Try to apply Linear Regression here.
For more information see the ML course on Coursera here, see Week5 and Week9.
Suppose we want to make a neural network to predict the outcome of a race between some number of participants.
Each participant in the race has various statistics: Engine Power, Max Speed, Driver Experience, etc.
Now imagine we have been asked to build a system which can handle any number of participants from 2 to 400 participants (just to pick a concrete number).
From what I have learned about "traditional" Neural Nets so far, our choices are:
Build many different neural nets for each number of participants: n = 2, 3, 4, 5, ... , 400.
Train one neural network taking input from 400 participants. When a piece of data refers to a race with less that 400 participants (this will be a large percentage of the data) just set all remaining statistic inputs to 0.
Assuming this would work, is there any reason to expect one method to perform better than the other?
The former is more specialized, but you have much less training data per net, so my guess is that it would work out roughly the same?
Is there a standard way to approach problems similar to this?
We could imagine (simplistically) that the neural network first classifies the strength of each participant, and therefore, each time a new participant is added, it needs to apply this same analysis to these new inputs, potentially hinting that there might be a "smart" way to reduce the total amount of work required.
Is this just screaming for a convolutional neural network?
Between your two options, option 1 would involve repeating a lot of effort to train for different sizes, and would probably be very slow to train as a result.
Option 2 is a bit more workable, but the network would need extra training on different sized inputs.
Another option, which I think would be the most likely to work, would be to only train a neural net to choose a winner between two participants, and use this to create a ranking via many comparisons between pairs. Such an approach is described here.
We could imagine (simplistically) that the neural network first classifies the strength of each participant, and therefore, each time a new participant is added, it needs to apply this same analysis to these new inputs, potentially hinting that there might be a "smart" way to reduce the total amount of work required.
I think you've got the key idea here. Since we want to perform exactly the same analysis on each participants (assuming it makes no difference whether they're participant 1 or participant 400), this is an ideal problem for Weight Sharing. This means that the weights on the neurons doing the initial analysis on a participant are identical for each participant. When these weights change for one participant, they change for all participants.
While CNNs do use weight sharing, we don't need to use a CNN to use this technique. The details of how you'd go about doing this would depend on your framework.
I’m very new to machine learning.
I have a dataset with data given me by a f1 race. User is playing this game and is giving me this dataset.
With machine learning, I have to work with this data and when a user (I know they are 10) plays a game I have to recognize who’s playing.
The data consists of datagram packet occurred in 1/10 second freq, the packets contains the following Time, laptime, lapdistance, totaldistance, speed, car position, traction control, last lap time, fuel, gear,..
I’ve thought to use a kmeans used in a supervised way.
Which algorithm could be better?
The task must be a multiclass classification. The very first step in any machine learning activity is to define a score metric (https://machinelearningmastery.com/classification-accuracy-is-not-enough-more-performance-measures-you-can-use/). That allows you to compare models between themselves and decide which is better. Then build a base model with random forest or/and logistic regression as suggested in another answer - they perform well out-of-the-box. Then try to play with features and understand which of them are more informative. And don't forget about a visualizations - they give many hints for data wrangling, etc.
this is somewhat a broad question, so I'll try my best
kmeans is unsupervised algorithm meaning it will find the classes itself and it best used when you know there are multiple classes but you don't know what exactly they are... using it with labeled data just means you will compute the distance of new vector v to each vector in the dataset and pick the one (or ones using majority vote) which give the min distance , this is not considered as machine learning
in this case when you do have the labels, supervised approach will yield much better results
I suggest try random forest and logistic regression at first, those are the most basic and common algorithms and they give pretty good results
if you haven't achieve the desired accuracy you can use deep learning and build a neural network with input layer as big as your packet's values and output layer of the number of classes, in between you can use one or multiple hidden layers with various nodes, but this is advanced approach and you better pick up some experience in machine learning field before pursue it
Note: the data is a time series, meaning that every driver has it's own behaviour of driving a car, so data should be considered as bulks of points, with this you can apply pattern matching technics, also there are a several neural networks build exactly for this data (like RNN) but this is far far advanced and much more difficult to implement
I was trying to create a convolution neural network for the recognition of animals, vehicles, buildings, trees, plants from a large data-set having the combination of these objects.
At the time of training I got a doubt about the way in which the network should be trained. My doubt is that whether I could train the network with the data-set of whole animals as a single attribute or train each animals separately?
Means, one group for lions, one for tigers, one for elephants etc and at the time of testing I can code it to output the result as animal if any one of its subcategory is satisfied.
I got this doubt since I have read that there should be a correct pattern in the data-set for the efficient detection and there should be a pattern only if we are training with the subcategory of objects than the vast data-set.
I have attached a figure showing the sample dataset(only logically correct). I want to know whether there should be separate data-set or single data-set.
Training on a separate data-set or a single data-set will depend on a variety of factors. If you want to classify the images in your test dataset using the Convolution Neural Network into just animals and not further subdivide them, then training on a single-data should be done. However, if you plan to further sub classify the images into tigers and lions, then the training needs to be done on separate datasets of tigers and lions.
The type of the dataset that you use for training will highly depend on your requirements of classification on the test dataset.
Moreover, you have to make sure that you normalize the images before you use it for training.