📗 [1 points] (F21FQ11) Part of the computation performed by LogisticRegression for multi-class prediction involves finding the position of the largest number in each row of a matrix M. How can this be done? M.argmax(axis = 1) M.argmax(axis = 0) M.max(axis = 1) M.max(axis = 0)
📗 [1 points] (F21FQ22) If you want to randomly split your data into train and test, but you don't want your results to change if you re-run your notebook, what should you pass to train_test_split? random_state = 50 test_size = 0.5 test_size = 50 random.seed(50)
📗 [1 points] (F22FQ13) If M is a numpy matrix representing a color image, how can you slice it to get one corner of the image to display with plt.imshow (or skimage.io.imshow as in the lectures)? M[0:10,0:10,0:3] M[0:100,0:3] M[0:10,0:10,0] M[0:100,0]
📗 [1 points] (new) There are 4 documents, and 2 of these documents contain the token "Groot". In document 1, there are 10 tokens in total, and 3 of them are "Groot". What is the bag of words feature (without normalization) of document 1 feature "Groot"? 3 6 1 10
📗 [1 points] (new) There are 4 documents, and 2 of these documents contain the token "Groot". In document 1, there are 10 tokens in total, and 3 of them are "Groot". What is the TF-IDF feature of document 1 feature "Groot" (use the IDF formula in the lectures)? 3/10 log(5/3) 2/4 log(4/11) 3/10 log(3/5) 2/4 log(11/4)
📗 [1 points] (new) Which of the following convolution filters blurs the image? Note: the other three filters highlight the edge pixels in the image. skimage.filters.gaussian skimage.filters.sobel skimage.filters.roberts skimage.filters.prewitt