Course contentsShow
← Machine Learning and Deep Learning
Lesson 2856 of 3,53861. Experiment Tracking and Model ManagementFree lesson

Documenting Computational Environments

Record hardware specs, driver versions, and environment details needed to recreate experimental conditions.

Documenting Computational Environments

You'll learn how to systematically record all hardware, software, and environment specifications needed to recreate your experimental conditions.

Why Documentation Matters

Imagine trying to bake a cake from a recipe that lists ingredients but omits oven temperature, altitude, and pan type. Similarly, publishing ML results without documenting your computational environment leaves critical gaps. Even when you've set random seeds and used Docker containers, subtle differences in hardware, driver versions, or system libraries can produce different results.

What to Document

Hardware Specifications:

  • CPU model and core count
  • GPU model(s), memory, and compute capability
  • Total RAM and disk type (SSD/HDD)
  • Network topology for distributed training

Software Stack:

  • Operating system version
  • CUDA and cuDNN versions
  • GPU driver version
  • Python version and all package versions (beyond just requirements.txt)
  • Compiler versions if building from source

Environment Details:

  • Environment variables (especially CUDA_VISIBLE_DEVICES, OMP_NUM_THREADS)
  • System locale and timezone
  • Any system-level optimizations or configurations

Practical Approach

Create an environment_info.txt file alongside your code:

GPU: NVIDIA A100 40GB (Driver 525.85.12, CUDA 11.8)
CPU: Intel Xeon Gold 6248R (48 cores)
RAM: 256GB DDR4
OS: Ubuntu 22.04.1 LTS
Python: 3.10.8
PyTorch: 2.0.0+cu118
NCCL: 2.17.1
cuDNN: 8.7.0

Automate this where possible using Python's platform module, torch.cuda properties, and system commands.

Key Takeaway: Comprehensive environment documentation is the final piece of reproducibility—without it, others (including future you) cannot reliably recreate your experimental results, even with perfect code and data versioning.