Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/multi loader #559

Draft
wants to merge 48 commits into
base: main
Choose a base branch
from

Conversation

nosnelmil
Copy link
Contributor

Summary

A wrapper around loader to run multiple studies at once with additional features like validation, dry-run and log collection

Implementation Notes ⚒️

  • Multi-Loader Entry Point:

    • MultiLoaderRunner houses the main logic of the multi-loader and exposes two execution points: RunDryRun and RunActual
    • multi_loader.go in tools/multiloader/ initializes the MultiLoaderRunner and calls the appropriate execution point
  • Experiment Execution Flow:

    • The multi-loader runner is instantiated with the provided configuration path
    • Execution is split into three phases: pre-execution, execution, and post-execution
      • Pre-Execution: Executes global pre-scripts, sets up directories, and unpacks sub-experiments.
      • Execution: Runs experiments with the generated configurations and appropriate flags and collect loader.go logs.
      • Post-Execution: Executes experiment-specific post-scripts and performs necessary cleanup tasks.
    • If the execution is a dry run, the same flow is followed, but the dryRun flag is set to true when calling loader.go
  • Post Execution:

    • Global post-scripts are executed after the experiments finish
    • Executes Make Clean
    • Temporary folders are removed

External Dependencies 🍀

  • N/A

Breaking API Changes ⚠️

  • N/A

Simply specify none (N/A) if not applicable.

@leokondrashov leokondrashov marked this pull request as draft November 21, 2024 08:26
Copy link
Contributor

@leokondrashov leokondrashov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the first brief look at the code.

Please consider moving the multi-loader exclusive part away from the loader's common package. There is no point in storing a structure for a multi-loader there.

Another thing is gofmt; please set the VS Code to run it on all file saves. There are issues with alignment and whitespace around parentheses.

Please add GitHub workflows for the tests and add e2e tests. You can add separate workflow files for both. In e2e, please check the output hierarchy and the different settings used in the experiments.

Please review each function and ensure that the names make sense to someone who reads them for the first time.

For the failing spellcheck, you will need to add all the failing words (unless you misspelled them) into .github/configs/wordlist.txt.

pkg/common/node_types.go Outdated Show resolved Hide resolved
pkg/common/config_types.go Outdated Show resolved Hide resolved
pkg/common/validators.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch from ee6a717 to 6549a3c Compare December 24, 2024 03:49
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch 4 times, most recently from 12d3e5e to b2c1295 Compare January 6, 2025 09:25
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch 2 times, most recently from 45b325a to 038568c Compare January 14, 2025 02:55
Copy link
Contributor

@leokondrashov leokondrashov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job. I've made couple of comments about minor things, please fix

.github/workflows/e2e_loader.yaml Outdated Show resolved Hide resolved
docs/multi_loader.md Outdated Show resolved Hide resolved
tools/multi_loader/base_loader_config.json Outdated Show resolved Hide resolved
tools/multi_loader/common/constants.go Outdated Show resolved Hide resolved
tools/multi_loader/common/utils.go Show resolved Hide resolved
tools/multi_loader/test_data/example_1_test/dirigent.csv Outdated Show resolved Hide resolved
tools/multi_loader/types/node_types.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
Signed-off-by: Lenson <[email protected]>

add multi loader base

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

add additional knative platform type

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update multi loader config struct

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

add unpack study

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update experiment config temp path

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update log parser

Signed-off-by: Lenson <[email protected]>

update log parser

Signed-off-by: Lenson <[email protected]>

update log parser

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update default multi loader config path

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update basic config

Signed-off-by: Lenson <[email protected]>

update basic config

Signed-off-by: Lenson <[email protected]>

add basic configs

Signed-off-by: Lenson <[email protected]>

update base config

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update log verbosity

Signed-off-by: Lenson <[email protected]>

update logs

Signed-off-by: Lenson <[email protected]>

update logs

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update test

Signed-off-by: Lenson <[email protected]>

refactor multi-loader tests

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

update failfast flag description

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

add progress in logging

Signed-off-by: Lenson <[email protected]>
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch from 038568c to 1be427f Compare January 16, 2025 03:04
Signed-off-by: Lenson <[email protected]>

remove extra features

Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch 3 times, most recently from 08fab95 to 84acc2a Compare January 16, 2025 09:31
Signed-off-by: Lenson <[email protected]>

update multi loader e2e tests

Signed-off-by: Lenson <[email protected]>

revert setup.cfg

Signed-off-by: Lenson <[email protected]>

chmod script

Signed-off-by: Lenson <[email protected]>

update unit tests

Signed-off-by: Lenson <[email protected]>
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch from 84acc2a to 2adfc32 Compare January 16, 2025 09:32
Signed-off-by: Lenson <[email protected]>
Signed-off-by: Lenson <[email protected]>

fix docs

Signed-off-by: Lenson <[email protected]>
@nosnelmil nosnelmil force-pushed the feature/multi-loader branch from c3a70e5 to b53d6df Compare January 16, 2025 10:00
docs/multi_loader.md Outdated Show resolved Hide resolved
tools/multi_loader/common/validators.go Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner_test.go Outdated Show resolved Hide resolved
tools/multi_loader/runner/multi_loader_runner_test.go Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants