Documentation

metadata

Environment metadata collection for benchmark reproducibility.

Functions

function
collect_environment() TestEnvironment

Collect test environment information from the current system.

Collect test environment information from the current system. Returns: TestEnvironment with hardware and software information
function
create_run_directory(base_dir: Path, prefix: str = '') Path

Create a timestamped directory for benchmark results.

Create a timestamped directory for benchmark results. Args: base_dir: Base directory for results prefix: Optional prefix for the directory name Returns: Path to created directory
Parameters
  • base_dir: Path
  • prefix: str= ''
function
format_environment_summary(env: TestEnvironment) str

Format environment as a human-readable summary.

Format environment as a human-readable summary. Args: env: TestEnvironment to format Returns: Formatted string summary
Parameters
  • env: TestEnvironment
function
load_environment(input_path: Path) TestEnvironment

Load environment metadata from a JSON file.

Load environment metadata from a JSON file. Args: input_path: Path to input JSON file Returns: TestEnvironment loaded from file
Parameters
  • input_path: Path
function
save_environment(env: TestEnvironment, output_path: Path) None

Save environment metadata to a JSON file.

Save environment metadata to a JSON file. Args: env: TestEnvironment to save output_path: Path to output JSON file
Parameters
  • env: TestEnvironment
  • output_path: Path