Docsity

AI Engineering Degree Ultimate Exam, Exams of Technology

Toggle sidebar
bg1
AI Engineering Degree Ultimate Exam
**Question 1.** Which matrix decomposition expresses a matrix A as U Σ Vᵀ,
where U and V are orthogonal and Σ is diagonal?
A) LU Decomposition
B) QR Decomposition
C) Singular Value Decomposition (SVD)
D) Eigenvalue Decomposition
Answer: C
Explanation: SVD factorises any real matrix A into U Σ Vᵀ, with U and V orthogonal
and Σ containing singular values.
**Question 2.** In the context of tensors, which operation reduces a 3-order
tensor 𝒯∈ℝ^{I×J×K} to a matrix by summing over the third mode?
A) Tensor unfolding
B) Tensor contraction
C) Tensor matricisation
D) Tensor slicing
Answer: B
Explanation: Contracting a tensor over a mode (here the third) aggregates that
dimension, yielding a matrix of size I×J.
**Question 3.** Which norm is defined as √(∑_{i=1}^n x_i²) for a vector x?
A) L₀ norm
B) L₁ norm
C) L₂ norm
D) Infinity norm
Answer: C
Explanation: The L₂ norm (Euclidean norm) computes the square root of the sum of
squared components.
**Question 4.** The gradient of a scalar function f(x,y) with respect to x and y is:
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32

Partial preview of the text

Download AI Engineering Degree Ultimate Exam and more Exams Technology in PDF only on Docsity!

Question 1. Which matrix decomposition expresses a matrix A as U Σ Vᵀ, where U and V are orthogonal and Σ is diagonal? A) LU Decomposition B) QR Decomposition C) Singular Value Decomposition (SVD) D) Eigenvalue Decomposition Answer: C Explanation: SVD factorises any real matrix A into U Σ Vᵀ, with U and V orthogonal and Σ containing singular values. Question 2. In the context of tensors, which operation reduces a 3-order tensor 𝒯∈ℝ^{I×J×K} to a matrix by summing over the third mode? A) Tensor unfolding B) Tensor contraction C) Tensor matricisation D) Tensor slicing Answer: B Explanation: Contracting a tensor over a mode (here the third) aggregates that dimension, yielding a matrix of size I×J. Question 3. Which norm is defined as √(∑_{i=1}^n x_i²) for a vector x? A) L₀ norm B) L₁ norm C) L₂ norm D) Infinity norm Answer: C Explanation: The L₂ norm (Euclidean norm) computes the square root of the sum of squared components. Question 4. The gradient of a scalar function f(x,y) with respect to x and y is:

A) A scalar B) A vector of partial derivatives C) A matrix of second-order derivatives D) A tensor of order three Answer: B Explanation: The gradient collects the first-order partial derivatives (∂f/∂x, ∂f/∂y) into a vector. Question 5. Which optimizer adapts learning rates per parameter based on first and second moments of gradients? A) Stochastic Gradient Descent (SGD) B) AdaGrad C) Adam D) Newton’s method Answer: C Explanation: Adam maintains moving averages of gradients (first moment) and squared gradients (second moment) to compute adaptive updates. Question 6. The Karush-Kuhn-Tucker (KKT) conditions are necessary for optimality in which type of problems? A) Unconstrained convex problems B) Linear programming only C) Non-convex problems without constraints D) Constrained optimization with differentiable objectives and constraints Answer: D Explanation: KKT generalises Lagrange multipliers to handle inequality constraints in differentiable optimization. Question 7. Which distribution is the conjugate prior for the Bernoulli likelihood? A) Gaussian B) Beta

Answer: B Explanation: By using kernel functions, SVMs compute inner products in the implicit feature space directly. Question 11. Which clustering algorithm can discover arbitrarily shaped clusters and does not require specifying the number of clusters beforehand? A) K-Means B) Hierarchical Agglomerative Clustering C) DBSCAN D) Gaussian Mixture Models Answer: C Explanation: DBSCAN groups points based on density, handling noise and non-convex shapes without a preset k. Question 12. t-SNE is primarily used for: A) Supervised classification B) Dimensionality reduction for visualisation of high-dimensional data C) Time-series forecasting D) Feature selection based on mutual information Answer: B Explanation: t-SNE maps high-dimensional points to 2- or 3-D while preserving local structure for visual inspection. Question 13. In a convolutional neural network, what is the purpose of a pooling layer? A) Increase the number of parameters B) Reduce spatial resolution, providing translation invariance C) Perform non-linear activation D) Convert 2-D data to 1-D vectors Answer: B Explanation: Pooling (e.g., max or average) downsamples feature maps, decreasing computation and adding invariance.

Question 14. Residual connections in ResNet help mitigate which problem in deep networks? A) Overfitting due to too many parameters B) Vanishing/exploding gradients C) Lack of non-linearity D) Insufficient training data Answer: B Explanation: Skip connections allow gradients to flow directly, alleviating vanishing/exploding issues in very deep nets. Question 15. Which recurrent architecture uses gating mechanisms to control information flow and mitigates the vanishing gradient problem? A) Simple RNN B) LSTM (Long Short-Term Memory) C) Feed-forward network D) Autoencoder Answer: B Explanation: LSTMs contain input, forget, and output gates that preserve long-range dependencies. Question 16. Variational Autoencoders differ from standard autoencoders because they: A) Use deterministic encodings only B) Learn a probability distribution over latent variables and optimise a variational lower bound C) Do not have a decoder network D) Are trained with reinforcement learning Answer: B Explanation: VAEs impose a prior on the latent space and optimise the ELBO, enabling generative sampling.

Question 20. Which tokenisation method builds a vocabulary based on the most frequent sub-word units? A) Character-level tokenisation B) Word-level tokenisation C) Byte-Pair Encoding (BPE) D) One-hot encoding Answer: C Explanation: BPE iteratively merges frequent character pairs, creating sub-word tokens that balance vocabulary size and coverage. Question 21. LoRA (Low-Rank Adaptation) fine-tunes large language models by: A) Adding full-size trainable layers B) Updating only the embeddings C) Injecting trainable low-rank matrices into attention weights, keeping the base model frozen D) Pruning 90 % of parameters Answer: C Explanation: LoRA inserts low-rank updates, drastically reducing fine-tuning compute while preserving performance. Question 22. Vision Transformers (ViT) first convert an image into a sequence of: A) Individual pixels B) Edge maps C) Fixed-size patches that are linearly projected to embeddings D) Histogram of oriented gradients Answer: C Explanation: ViT splits the image into patches (e.g., 16×16), flattens each, and projects them before feeding to the transformer. Question 23. In an ETL pipeline, the “Transform” stage typically includes:

A) Data ingestion from source systems B) Loading data into a data warehouse C) Data cleaning, enrichment, and aggregation D) Archiving raw logs Answer: C Explanation: Transformations reshape raw data into a usable format (e.g., type casting, joins, feature engineering). Question 24. Apache Kafka is best described as: A) A batch processing framework B) A distributed, fault-tolerant publish-subscribe messaging system for real-time streams C) A relational database D) A model-serving platform Answer: B Explanation: Kafka stores streams of records in topics, enabling high-throughput, low-latency data pipelines. Question 25. A data lakehouse combines which two architectural concepts? A) Data warehouse’s ACID guarantees with data lake’s ability to store raw files B) Real-time streaming with batch ETL only C) Graph databases and key-value stores D) Edge computing and IoT sensors Answer: A Explanation: Lakehouses aim to provide transactional semantics over the flexible storage of a lake. Question 26. Which feature-engineering technique is most appropriate for handling categorical variables with high cardinality? A) One-hot encoding B) Label encoding

Explanation: Quantisation maps 32-bit floats to 8-bit integers (or similar), shrinking model size and speeding up inference. Question 30. ONNX (Open Neural Network Exchange) enables: A) Training models on quantum computers B) Interoperability of models across different deep-learning frameworks for inference deployment C) Automatic hyperparameter optimisation D) Data versioning Answer: B Explanation: ONNX defines a common format to export/import models between PyTorch, TensorFlow, etc. Question 31. In Kubernetes, a Deployment object is used to: A) Store dataset versions B) Define a set of replica Pods and manage their lifecycle (rolling updates, scaling) C) Serve HTTP APIs directly D) Perform data preprocessing Answer: B Explanation: Deployments declaratively manage replicated Pods and handle rollouts. Question 32. Which API protocol typically provides lower latency and more efficient binary serialization compared to REST? A) SOAP B) GraphQL C) gRPC D) XML-RPC Answer: C Explanation: gRPC uses Protocol Buffers for compact binary messages and supports streaming, reducing latency.

Question 33. Concept drift refers to: A) Gradual changes in model architecture over time B) A shift in the statistical properties of the input data distribution that degrades model performance C) Overfitting to the training set D) The need to retrain models weekly by policy Answer: B Explanation: When the relationship between inputs and outputs changes, the model may become stale, requiring monitoring and adaptation. Question 34. Which CI/CD tool is specifically designed for machine-learning pipelines, tracking data, code, and model artifacts? A) Jenkins B) GitHub Actions C) DVC (Data Version Control) D) Travis CI Answer: C Explanation: DVC extends Git to version large data files and model binaries, facilitating reproducible ML workflows. Question 35. A/B testing in model deployment is used to: A) Compare two versions of a model on live traffic to measure performance differences statistically B) Generate synthetic data C) Encrypt model weights D) Perform hyperparameter grid search Answer: A Explanation: By routing a fraction of users to each model, practitioners can assess impact on key metrics before full rollout. Question 36. In Retrieval-Augmented Generation (RAG), the “retrieval” component typically returns:

A) Performs region proposal and classification in a single forward pass, enabling real-time detection B) Requires a separate segmentation head C) Uses recurrent layers for detection D) Operates only on grayscale images Answer: A Explanation: YOLO treats detection as a regression problem over a grid, eliminating the proposal stage. Question 40. Diffusion models generate images by: A) Directly mapping latent vectors to pixels via a GAN generator B) Iteratively denoising a random noise image using a learned reverse diffusion process C) Applying a deterministic Fourier transform D) Using a decision tree ensemble Answer: B Explanation: The model learns to reverse a forward noising process, gradually producing realistic samples. Question 41. Reinforcement Learning from Human Feedback (RLHF) typically uses which algorithm to fine-tune a language model? A) Q-Learning B) Proximal Policy Optimization (PPO) C) SARSA D) Monte Carlo Tree Search Answer: B Explanation: PPO updates the policy while keeping changes within a trust region, suitable for aligning LLMs with human preferences. Question 42. An adversarial example in computer vision is created by: A) Adding random Gaussian noise until the model misclassifies

B) Applying imperceptibly small perturbations crafted to cause a targeted misclassification C) Rotating the image by 90 degrees D) Changing the image format from PNG to JPEG Answer: B Explanation: Adversarial attacks compute gradients to find minimal perturbations that fool the model while remaining invisible to humans. Question 43. Demographic parity as a fairness metric requires that: A) True positive rates are equal across groups B) Predicted positive rates are equal across protected groups, regardless of ground-truth labels C) False negative rates are minimized D) Model accuracy is maximized for the majority group Answer: B Explanation: Demographic parity (statistical parity) demands equal selection rates across groups. Question 44. SHAP values explain model predictions by: A) Approximating feature contributions using local linear models only B) Computing exact Shapley values from game theory, attributing each feature’s marginal contribution averaged over all coalitions C) Measuring gradient magnitude D) Using decision rules from a tree ensemble only Answer: B Explanation: SHAP provides theoretically sound additive feature attributions based on Shapley values. Question 45. The EU AI Act classifies AI systems that pose “high risk” and therefore require: A) No regulation B) Mandatory conformity assessments, documentation, and post-market monitoring

C) A separate held-out test set only D) Cross-entropy loss on the training set Answer: B Explanation: OOB samples act as a built-in validation set, enabling unbiased error estimation without extra data. Question 49. Which regularisation technique adds a penalty proportional to the absolute value of the coefficients? A) L2 (Ridge) regularisation B) L1 (Lasso) regularisation C) Dropout D) Early stopping Answer: B Explanation: L1 regularisation encourages sparsity by penalising the sum of absolute coefficient values. Question 50. The Jacobian matrix of a vector-valued function f:ℝⁿ→ℝᵐ contains: A) Second-order partial derivatives only B) First-order partial derivatives ∂f_i/∂x_j arranged in an m×n matrix C) Eigenvalues of f D) The Hessian of f Answer: B Explanation: The Jacobian records all first-order partial derivatives, mapping input changes to output changes. Question 51. Which of the following is a common method to mitigate overfitting in deep neural networks? A) Increasing batch size indefinitely B) Adding dropout layers that randomly zero out activations during training C) Removing the activation functions D) Using only a single training epoch

Answer: B Explanation: Dropout prevents co-adaptation of neurons, improving generalisation. Question 52. In a multi-head attention layer with h heads, each head computes attention with dimension d_k. The concatenated output dimension before the final linear projection is: A) d_k B) h × d_k C) d_k / h D) √(h × d_k) Answer: B Explanation: Each head produces a d_k-dimensional vector; concatenating h heads yields h·d_k features. Question 53. Which loss function is commonly used to train Variational Autoencoders? A) Mean Absolute Error only B) Reconstruction loss (e.g., BCE) plus KL-divergence regularisation between posterior and prior C) Hinge loss D) Triplet loss Answer: B Explanation: The ELBO combines a reconstruction term and a KL term that forces the latent distribution towards the prior. Question 54. In the context of reinforcement learning, the Bellman equation expresses: A) The relationship between the policy gradient and the loss function B) The recursive definition of the value function V(s) or Q(s,a) in terms of expected future rewards C) The optimal hyperparameters for a given environment D) The probability of transitioning between states

Explanation: d-separation provides a graphical criterion to infer independence relations. Question 58. Which activation function mitigates the vanishing gradient problem by having a gradient close to 1 for positive inputs? A) Sigmoid B) Tanh C) ReLU (Rectified Linear Unit) D) Softmax Answer: C Explanation: ReLU outputs x for x>0, yielding a gradient of 1, thus preserving gradient magnitude for positive activations. Question 59. When deploying a model on edge devices, which technique is most effective for reducing model size while preserving accuracy? A) Increasing batch size during inference B) Knowledge distillation, training a smaller “student” model to mimic a larger “teacher” C) Using larger hidden layers D) Adding more dropout layers Answer: B Explanation: Distillation transfers knowledge from a high-capacity model to a compact one, often achieving comparable performance. Question 60. In a time-series forecasting pipeline, which transformation is commonly applied to achieve stationarity before using ARIMA models? A) One-hot encoding B) Logarithmic scaling only C) Differencing (subtracting previous observation) D) Principal Component Analysis Answer: C

Explanation: Differencing removes trends and seasonality, making the series stationary—a prerequisite for ARIMA. Question 61. Which of the following is a key advantage of using a graph database (e.g., Neo4j) for storing knowledge graphs in NLP applications? A) Faster matrix multiplication B) Native support for traversing relationships, enabling efficient entity-linking and path queries C) Automatic feature extraction for images D) Built-in gradient descent optimizer Answer: B Explanation: Graph databases excel at relationship-centric queries, crucial for semantic search and knowledge-graph reasoning. Question 62. The term “prompt engineering” in large language models refers to: A) Modifying model weights to improve performance B) Designing input text (prompts) that steer the model’s output toward desired behavior without changing parameters C) Changing the underlying transformer architecture D) Fine-tuning on a new dataset Answer: B Explanation: Prompt engineering leverages the model’s pre-trained knowledge by crafting instructions that elicit specific responses. Question 63. In the context of model monitoring, a “data drift” detector typically compares: A) Model training loss vs. validation loss B) Distribution of incoming feature values to a reference distribution using statistical tests (e.g., KS test) C) GPU utilisation over time D) Number of API calls per second Answer: B