深層学習エンジニアリング

損失、正則化、CNN / 系列、最適化、評価指標まで、モデルを設計・訓練する側の英語四択。クラウドサービスの名前は出さない。

同梱問題集の公開抜粋です。最初は問題と選択肢だけ出します。正解と解説は各問の「正解と解説を見る」を開くまで見えません。作者の既定表示は Ultra Practicebook、ライセンスは MIT です。試験団体の過去問や市販問題集の転載ではありません。

この問題集の位置づけ

AWS セットがサービスの選び方なのに対し、このセットはクラウドに依存しない学習理論とネットワークの部品です。loss が重みを直接更新するわけではない、k-NN の k は近傍数であってクラスタ数ではない、といった取り違えを残しています。

E資格セットとテーマは重なりますが、言語と問いの粒度が違います。E資格は日本語で数式・手順の説明が長く、こちらは英語の短い定義確認です。同じ週に両方やるなら、間違えた概念だけを横断して復習してください。クラウドのサービス名は AWS セットへ回し、ここでは損失と正則化の語彙を残します。誤答は隣接する正しい概念なので、捨てた選択肢の定義も解説で一言残してください。

学習目標

過学習と正則化、勾配法の学習率、アンサンブルの bagging / boosting、CNN の局所性など、実装枠組みが変わっても残る概念を、短い定義で取り違えないようにする。

対象者

大学の機械学習の後半や、業務でネットワークを組む人。SageMaker のインスタンス名より先に、損失と最適化の語彙が必要な人。

学習方法

各問の誤答が「隣接する正しい概念」になっているので、誤答側の定義も解説で確認する。決定木の教科書と、同じ週に「分岐の理論」と「ニューラルの最適化」を混ぜすぎない。

問題

先に自分で選んでから、折りたたみを開いてください。解説は正解の言い換えだけでなく、隣の選択肢が文に入らない理由や、一緒に覚える連語を書いています。番号だけ暗記せず、解説の文を一度声に出してから次へ進んでください。

問 1

What is the main purpose of a loss function in machine learning?

  1. To measure prediction error
  2. To update weights directly
  3. To preprocess data
  4. To reduce model size
正解と解説を見る

正解: To measure prediction error

A loss function quantifies the difference between predicted values and true values, guiding the optimization process. The stem asks: What is the main purpose of a loss function in machine learning?. The keyed answer is 1. Options: To measure prediction error; To update weights directly; To preprocess data; To reduce model size. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 2

What does overfitting mean?

  1. Model fits training data too well and generalizes poorly
  2. Model is too simple
  3. Model cannot learn
  4. Training data is insufficient
正解と解説を見る

正解: Model fits training data too well and generalizes poorly

Overfitting occurs when a model captures noise instead of general patterns, reducing performance on unseen data. The stem asks: What does overfitting mean?. The keyed answer is 1. Options: Model fits training data too well and generalizes poorly; Model is too simple; Model cannot learn; Training data is insufficient. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 3

What is the role of regularization?

  1. To prevent overfitting
  2. To increase model complexity
  3. To speed up inference
  4. To normalize data
正解と解説を見る

正解: To prevent overfitting

Regularization adds constraints or penalties to reduce model complexity and improve generalization. The stem asks: What is the role of regularization?. The keyed answer is 1. Options: To prevent overfitting; To increase model complexity; To speed up inference; To normalize data. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 4

Which algorithm is mainly used for classification?

  1. Logistic Regression
  2. Linear Regression
  3. K-means
  4. PCA
正解と解説を見る

正解: Logistic Regression

Logistic regression models the probability of class membership and is widely used for classification tasks. The stem asks: Which algorithm is mainly used for classification?. The keyed answer is 1. Options: Logistic Regression; Linear Regression; K-means; PCA. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 5

What does k in k-NN represent?

  1. Number of neighbors
  2. Number of clusters
  3. Learning rate
  4. Feature count
正解と解説を見る

正解: Number of neighbors

k determines how many nearby data points are considered when making a prediction. The stem asks: What does k in k-NN represent?. The keyed answer is 1. Options: Number of neighbors; Number of clusters; Learning rate; Feature count. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 6

What is the main idea of Support Vector Machines?

  1. Maximize margin between classes
  2. Minimize data size
  3. Increase depth
  4. Reduce features
正解と解説を見る

正解: Maximize margin between classes

SVM seeks a decision boundary that maximizes the margin between different classes. The stem asks: What is the main idea of Support Vector Machines?. The keyed answer is 1. Options: Maximize margin between classes; Minimize data size; Increase depth; Reduce features. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 7

What is a key advantage of decision trees?

  1. Interpretability
  2. High accuracy always
  3. Low memory usage
  4. Continuous optimization
正解と解説を見る

正解: Interpretability

Decision trees are easy to understand and visualize, making them highly interpretable. The stem asks: What is a key advantage of decision trees?. The keyed answer is 1. Options: Interpretability; High accuracy always; Low memory usage; Continuous optimization. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 8

What does ensemble learning aim to do?

  1. Combine multiple models
  2. Reduce dataset size
  3. Eliminate features
  4. Speed up labeling
正解と解説を見る

正解: Combine multiple models

Ensemble methods improve performance by aggregating predictions from multiple models. The stem asks: What does ensemble learning aim to do?. The keyed answer is 1. Options: Combine multiple models; Reduce dataset size; Eliminate features; Speed up labeling. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 9

What is bagging mainly used for?

  1. Reducing variance
  2. Reducing bias
  3. Feature selection
  4. Dimensionality reduction
正解と解説を見る

正解: Reducing variance

Bagging stabilizes predictions by training models on different bootstrap samples. The stem asks: What is bagging mainly used for?. The keyed answer is 1. Options: Reducing variance; Reducing bias; Feature selection; Dimensionality reduction. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 10

What is boosting designed to improve?

  1. Bias and variance
  2. Only variance
  3. Only bias
  4. Data quality
正解と解説を見る

正解: Bias and variance

Boosting focuses on hard examples to progressively improve model performance. The stem asks: What is boosting designed to improve?. The keyed answer is 1. Options: Bias and variance; Only variance; Only bias; Data quality. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 11

What does gradient descent optimize?

  1. Loss function
  2. Dataset size
  3. Feature count
  4. Model depth
正解と解説を見る

正解: Loss function

Gradient descent iteratively updates parameters to minimize the loss function. The stem asks: What does gradient descent optimize?. The keyed answer is 1. Options: Loss function; Dataset size; Feature count; Model depth. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 12

What happens if the learning rate is too small?

  1. Slow convergence
  2. Divergence
  3. Overfitting
  4. No gradients
正解と解説を見る

正解: Slow convergence

A very small learning rate makes training extremely slow. The stem asks: What happens if the learning rate is too small?. The keyed answer is 1. Options: Slow convergence; Divergence; Overfitting; No gradients. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 13

What is the purpose of feature scaling?

  1. Stabilize optimization
  2. Increase data size
  3. Remove noise
  4. Encode labels
正解と解説を見る

正解: Stabilize optimization

Scaling ensures features contribute equally during optimization. The stem asks: What is the purpose of feature scaling?. The keyed answer is 1. Options: Stabilize optimization; Increase data size; Remove noise; Encode labels. Keep this in the Preprocessing bucket, and reject the neighbor term that solves a different job.

問 14

What is normalization?

  1. Scaling values to a fixed range
  2. Removing outliers
  3. Encoding categories
  4. Reducing dimensions
正解と解説を見る

正解: Scaling values to a fixed range

Normalization typically rescales data into a range such as 0 to 1. The stem asks: What is normalization?. The keyed answer is 1. Options: Scaling values to a fixed range; Removing outliers; Encoding categories; Reducing dimensions. Keep this in the Preprocessing bucket, and reject the neighbor term that solves a different job.

問 15

What is standardization?

  1. Mean 0 and variance 1
  2. 0 to 1 scaling
  3. Log transformation
  4. Discretization
正解と解説を見る

正解: Mean 0 and variance 1

Standardization centers data and scales it by standard deviation. The stem asks: What is standardization?. The keyed answer is 1. Options: Mean 0 and variance 1; 0 to 1 scaling; Log transformation; Discretization. Keep this in the Preprocessing bucket, and reject the neighbor term that solves a different job.

問 16

What is PCA mainly used for?

  1. Dimensionality reduction
  2. Classification
  3. Regression
  4. Clustering
正解と解説を見る

正解: Dimensionality reduction

PCA reduces dimensions while preserving maximum variance. The stem asks: What is PCA mainly used for?. The keyed answer is 1. Options: Dimensionality reduction; Classification; Regression; Clustering. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 17

What is the main risk of high-dimensional data?

  1. Curse of dimensionality
  2. Over-regularization
  3. Underfitting
  4. Label noise
正解と解説を見る

正解: Curse of dimensionality

High dimensions increase sparsity and degrade model performance. The stem asks: What is the main risk of high-dimensional data?. The keyed answer is 1. Options: Curse of dimensionality; Over-regularization; Underfitting; Label noise. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 18

What does a confusion matrix show?

  1. Prediction results by class
  2. Loss curve
  3. Feature importance
  4. Model structure
正解と解説を見る

正解: Prediction results by class

It summarizes correct and incorrect predictions for each class. The stem asks: What does a confusion matrix show?. The keyed answer is 1. Options: Prediction results by class; Loss curve; Feature importance; Model structure. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 19

What does precision measure?

  1. Correct positive predictions ratio
  2. All correct predictions
  3. Error rate
  4. Recall
正解と解説を見る

正解: Correct positive predictions ratio

Precision evaluates how many predicted positives are actually correct. The stem asks: What does precision measure?. The keyed answer is 1. Options: Correct positive predictions ratio; All correct predictions; Error rate; Recall. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.

問 20

What does recall measure?

  1. Detected positives ratio
  2. Prediction confidence
  3. Accuracy
  4. Loss
正解と解説を見る

正解: Detected positives ratio

Recall measures how many actual positives were correctly identified. The stem asks: What does recall measure?. The keyed answer is 1. Options: Detected positives ratio; Prediction confidence; Accuracy; Loss. Keep this in the MachineLearning bucket, and reject the neighbor term that solves a different job.