Redesigned experiment configuration

Open
#339 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
python
Domain
backend, cli, data

Research direction

Start by reading the configuration loader, experiment invocation CLI, and output directory handling; the issue does not name their files. Trace how an experiment type is selected and where execution results are written, then identify the tests covering configuration loading and invocation. Done means named experiments can be selected individually or with --all, overrides follow the listed precedence, each run gets its own directory, and postprocessing accepts --run-dir.

Written by the indexing model from the issue text.

Description

Based on the feedback of @lijiaheng09 - to be discussed.

Currently, SeBS has multiple independent experiment configurations, but does not allow to have multiple configurations for the same experiment. SeBS should support multiple configurations of the same experiment type, loading experiments from different configuration files, and storing each execution in its own results directory. The current example.json includes settings for all experiment types, although the loader already allows unused type-specific sections to be omitted. Output handling creates another problem: experiments append a fixed directory named after their type, such as perf-cost; different configurations and repeated executions can therefore write into the same directory.

We should separate the three concepts of an experiment type, experiment ID (named by the user), and the run ID, which is generated automatically and encodes the date. Example below:

{
  "schema_version": 2,
  "defaults": {
    "deployment": "aws-us-east",
    "architecture": "x64",
    "system_variant": "package",
    "runtime": {
      "language": "python",
      "version": "3.11"
    },
    "output_root": "./results"
  },
  "deployments": {
    "aws-us-east": {
      "provider": "aws",
      "region": "us-east-1",
      "resources": {
        "use_function_url": true,
        "function_url_auth_type": "NONE"
      }
    },
    "aws-eu-west": {
      "provider": "aws",
      "region": "eu-west-1",
      "resources": {
        "use_function_url": true,
        "function_url_auth_type": "NONE"
      }
    }
  },
  "experiments": {
    "html-us": {
      "type": "perf-cost",
      "parameters": {
        "benchmark": "110.dynamic-html",
        "modes": ["cold", "warm", "burst", "sequential"],
        "input_size": "test",
        "repetitions": 50,
        "concurrent_invocations": 50,
        "memory_sizes": [128, 256]
      }
    },
    "thumbnail-eu": {
      "deployment": "aws-eu-west",
      "output_root": "./thumbnail-results",
      "type": "perf-cost",
      "parameters": {
        "benchmark": "210.thumbnailer",
        "modes": ["cold", "warm", "burst", "sequential"],
        "input_size": "test",
        "repetitions": 50,
        "concurrent_invocations": 50,
        "memory_sizes": [128, 256, 1024]
      }
    }
  }
}

In this example:

  • html-us inherits the deployment, runtime, architecture, system variant, and output root from defaults.
  • thumbnail-eu overrides the deployment reference and output root.
  • Both entries use the perf-cost implementation with independent parameters.
  • Unused deployment profiles and experiment types can be omitted.
  • update_code, update_storage, and download_results default to false and can be supplied in defaults or individual experiment entries.

To resolve different configurations, we could have the following order:

  1. Built-in defaults.
  2. File-level defaults.
  3. Experiment-specific values.
  4. Explicit CLI overrides. CLI options that were not supplied must not override configuration values.

The CLI usage would change from experiment type to explicit experiment name. When a file contains multiple experiments, we require an explicit experiment ID or --all:

sebs experiment invoke html-us --config study/suite.json
sebs experiment invoke --all --config study/suite.json

For output directories, we should allocate a fresh directory for every execution:

<output_root>/<experiment_id>/<run_id>/

For the example configuration stored at study/suite.json, results would be placed under:

study/results/html-us/20261021T120000Z-a81f/
study/thumbnail-results/thumbnail-eu/20261021T120000Z-b92e/

Postprocessing should select an existing run directly:

sebs experiment process --run-dir \
  study/results/html-us/20261021T120000Z-a81f
Dominant language
Python
Stars
200
Forks
112
Avg merge
25m
Merged PRs (30d)
3

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from spcl/serverless-benchmarks

All issues in spcl/serverless-benchmarks

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.