Prepare and test your skills

Prepare and test your skills

Free sample question with answers and detailed explanation below. The Professional Machine Learning Engineer practice bank has an additional 974 practice questions.Try 10 free realistic questions: instant score, no credit card, and no account required.
You are prototyping a PyTorch transformer model in an Agent Platform Workbench notebook on a Cloud TPU host inside a VPC Service Controls perimeter, reading large shards from Cloud Storage. Telemetry from tpumonitoring shows low duty_cycle_pct, high HBM traffic from eager dispatches, and storage I/O stalls.
Your prototyping workflow must meet these requirements:
FSDP2/DTensor scaling.Which combination of tools and configurations should you use?
cloud_profiler plugin with tf.keras.callbacks.TensorBoard to capture TPU traces, and mount the Cloud Storage bucket using standard Cloud Storage FUSE on Persistent Disk without Local SSD caching.PyTorch/XLA is the legacy lazy-tensor bridge for running PyTorch on TPUs by recording computation graphs and requiring explicit code annotations to mark compilable regions. The cloud_profiler plugin combined with tf.keras.callbacks.TensorBoard is a profiling integration built for TensorFlow/Keras training loops, and standard Cloud Storage FUSE mounts object buckets as POSIX file systems.
tf.keras.callbacks.TensorBoard is a Keras callback designed for TensorFlow model.fit() loops rather than native PyTorch torch.profiler and XProf Roofline Analysis.tpu_dist (FSDP2/DTensor).duty_cycle_pct.You were maintaining a legacy TensorFlow/Keras custom training job on Agent Platform Managed Training using tf.keras.callbacks.TensorBoard and cloud_profiler for small datasets that fit comfortably in host memory.
Enabling Local SSD backing for Cloud Storage FUSE file caching—or adopting the dedicated Cloud Storage PyTorch connector—is essential when streaming large training shards and writing large checkpoints.
@jax.jit and Pathways for single-controller execution, profile with XProf HLO Op Profile, and ingest the Cloud Storage shards through a bigframes.ml.pipeline.Pipeline connected via bigframes-default-connection.JAX and Flax form a compiler-first functional deep learning stack using @jax.jit for XLA compilation and Pathways as a single-controller distributed runtime across multiple TPU Pods. Separately, bigframes.ml.pipeline.Pipeline is a BigQuery DataFrames module that assembles scikit-learn-style preprocessing transforms and estimators executed inside BigQuery.
torch.compile, and FSDP2/DTensor primitives rather than optimizing the existing PyTorch workflow.bigframes.ml.pipeline.Pipeline is built for tabular SQL-backed analytics and in-database or remote ML models in BigQuery, not high-throughput streaming of deep learning training shards from Cloud Storage into TPU device memory.bigframes-default-connection requires elevated Project IAM Admin permissions and BigQuery Connection API workflows that are unnecessary for reading Cloud Storage shards in a PyTorch notebook.tpu_dist.bigframes.ml mirrors scikit-learn APIs (train_test_split, KFold, Pipeline) pushed down to BigQuery.You were starting a greenfield foundation model in JAX/Flax (using Grain and Orbax for Cloud Storage shard loading) or building a tabular BigQuery DataFrames preprocessing and classification pipeline rather than optimizing a PyTorch transformer.
Even when using JAX, deterministic Cloud Storage data loading relies on Grain rather than BigQuery DataFrames.
torch_tpu) with DeferAndFuse eager mode or torch.compile(backend="tpu") and the tpu_dist backend, profile traces with torch.profiler and XProf (including Roofline Analysis), and stream shards via the Cloud Storage PyTorch connector or Cloud Storage FUSE with Local SSD file caching.TorchTPU (torch_tpu) is a PyTorch-native device backend for Cloud TPU that preserves standard one-process-per-device semantics, tensor views, and in-place mutations while integrating directly with OpenXLA, StableHLO, and XProf. Paired with high-throughput Cloud Storage connectors and local caching, it provides an end-to-end prototyping and scaling stack inside Agent Platform Workbench.
DeferAndFuse fuses sequences of operators to cut high-bandwidth memory (HBM) traffic, while torch.compile(backend="tpu") captures graphs with TorchDynamo and compiles cached executables via OpenXLA and StableHLO. The tpu_dist process group natively supports DistributedDataParallel (DDP), FSDP2, and DTensor across slices.torch.profiler and XProf enables Trace Viewer timelines and Roofline Analysis (with under 1% hardware overhead) to pinpoint whether ops are compute-bound or memory-bound. Meanwhile, the Cloud Storage PyTorch connector or Cloud Storage FUSE with Local SSD file caching eliminates remote object-fetch stalls.torch.compile(backend="tpu") caches compiled TPU graphs across processes, hosts, and job restarts.torch.tpu.distributed.topology_aware_mesh maps parallelism dimensions onto physical TPU interconnects.Unlike legacy PyTorch/XLA or full framework rewrites, this stack solves both HBM dispatch overhead and Cloud Storage I/O bottlenecks while keeping PyTorch interactive and immediately ready for multi-slice FSDP2 scaling.
Debug eager mode for operator fusion, launch profiler.start_server after the training script exits to inspect XProf metrics, and stream training batches from Cloud Storage through Dataflow MLTransform.TorchTPU provides three eager execution modes (Strict, Debug, and DeferAndFuse), XProf supports on-demand capture via profiler.start_server, and Dataflow MLTransform wraps Apache Beam transforms (such as scaling or vocabulary computation) for batch and streaming data preparation.
Debug mode executes operations synchronously with tensor bounds checking, which adds synchronization overhead instead of reducing HBM traffic. Operator fusion during eager execution requires DeferAndFuse mode (or full-graph compilation with torch.compile).profiler.start_server starts an in-process XProf server that listens for on-demand capture triggers while the workload is running; launching it after the training script exits captures no training steps.MLTransform is an asynchronous Apache Beam ETL preprocessing service for generating transformed datasets, not an in-host high-throughput tensor loader for feeding active TPU training loops.Strict dispatches operators asynchronously; Debug enforces synchronous bounds checking; only DeferAndFuse fuses eager operator sequences to cut HBM traffic.profiler.start_server capture must execute during active training steps (writing .xplane.pb files to local disk or Cloud Storage).iter_torch_batches.You were diagnosing numerical correctness bugs (Debug mode), preprocessing raw datasets offline in Apache Beam (MLTransform), and running tensorboard --logdir after training to inspect previously captured XProf .xplane.pb files.
Answer them yourself and get your score the moment you finish. No account needed.
Full access includes
Keep the momentum going with these hand-picked practice scenarios
Last updated Validated