Machine Learning week 7 quiz: Unsupervised Learning
Unsupervised Learning
5?試題
1.?For which of the following tasks might K-means clustering be a suitable algorithm? Select all that apply.
Given historical weather records, predict if tomorrow's weather will be sunny or rainy.
Given many emails, you want to determine if they are Spam or Non-Spam emails.
Given a set of news articles from many different news websites, find out what are the main topics covered.
From the user usage patterns on a website, figure out what different groups of users exist.
2.?Suppose we have three cluster centroids?μ1=[12],?μ2=[?30]?and?μ3=[42]. Furthermore, we have a training example?x(i)=[?12]. After a cluster assignment step, what will?c(i)?be?
c(i)=3
c(i)=1
c(i)=2
c(i)?is not assigned
3.?K-means is an iterative algorithm, and two of the following steps are repeatedly carried out in its inner-loop. Which two?
The cluster assignment step, where the parameters?c(i)?are updated.
Move the cluster centroids, where the centroids?μk?are updated.
Move each cluster centroid?μk, by setting it to be equal to the closest training example?x(i)
The cluster centroid assignment step, where each cluster centroid?μi?is assigned (by setting?c(i)) to the closest training example?x(i).
4.?Suppose you have an unlabeled dataset?{x(1),…,x(m)}. You run K-means with 50 different random
initializations, and obtain 50 different clusterings of the
data. What is the recommended way for choosing which one of
these 50 clusterings to use?
Plot the data and the cluster centroids, and pick the clustering that gives the most "coherent" cluster centroids.
Use the elbow method.
Manually examine the clusterings, and pick the best one.
Compute the distortion function?J(c(1),…,c(m),μ1,…,μk), and pick the one that minimizes this.
5.?Which of the following statements are true? Select all that apply.
Once an example has been assigned to a particular centroid, it will never be reassigned to another different centroid
K-Means will always give the same results regardless of the initialization of the centroids.
A good way to initialize K-means is to select K (distinct) examples from the training set and set the cluster centroids equal to these selected examples.
On every iteration of K-means, the cost function?J(c(1),…,c(m),μ1,…,μk)?(the distortion function) should either stay the same or decrease; in particular, it should not increase.
總結
以上是生活随笔為你收集整理的Machine Learning week 7 quiz: Unsupervised Learning的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Machine Learning wee
- 下一篇: Machine Learning wee