Skip to content

chore: unit test regressors to match estimator results #1804

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

Closed
wants to merge 2,537 commits into from

Conversation

rootfs
Copy link
Contributor

@rootfs rootfs commented Oct 9, 2024

No description provided.

KaiyiLiu1234 and others added 30 commits July 10, 2024 11:40
Cleaned YAML files to remove trailing lines.

Signed-off-by: Kaiyi <kaiyiliu21@gmail.com>
Cleaned YAML files to resolve yamllint action errors.

Signed-off-by: Kaiyi <kaiyiliu21@gmail.com>
…puting-io/dependabot/github_actions/github-actions-b63beb1316

build(deps): bump the github-actions group across 1 directory with 2 updates
Remove cache clearing and update from scaph dockerfile.

Signed-off-by: Kaiyi <kaiyiliu21@gmail.com>
…efile-macos

fix: Makefile for running on macOS
This commit adds a more comprehensive eBPF test suite.
Currently it tests the operation of a number of key functions
within the eBPF code - for example the main sched_switch
tracepoint that we run. In addition, it runs a number
of micro benchmarks so we can track performance of these
key pieces of code.

Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
This commit addresses and resolves various linting issues in the validator module
Additionally, it includes the following improvements:

- Add a new make target to run the linter.
- Add `__init__.py` to the `tests/validator` directory
  to resolve the linting issue: implicit-namespace-package (INP001).
- Suppress certain linting issues that are intentional or not applicable in our context.

Signed-off-by: vprashar2929 <vprashar@redhat.com>
Refactor pkg/sensors/accelerator to use a more generic device
abstractions that different devices can plug into.

Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
Removed Autoheal feature of the health check.

Signed-off-by: Kaiyi <kaiyiliu21@gmail.com>
Added back apt-get update back to scaph dockerfile as it
fails to install curl without it.

Signed-off-by: Kaiyi <kaiyiliu21@gmail.com>
…x-lint

fix(validator): resolve linting issues
This commit allows grafana to be accessed without logging in as
admin user. It also solves the nagging change password issue.

Signed-off-by: Sunil Thaha <sthaha@redhat.com>
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
…ecommit-shellcheck-mardown

chore: precommit add markdown + spellcheck
Bumps the go-dependencies group with 1 update: [github.com/prometheus/prometheus](https://github.com/prometheus/prometheus).


Updates `github.com/prometheus/prometheus` from 0.53.0 to 0.53.1
- [Release notes](https://github.com/prometheus/prometheus/releases)
- [Changelog](https://github.com/prometheus/prometheus/blob/main/CHANGELOG.md)
- [Commits](prometheus/prometheus@v0.53.0...v0.53.1)

---
updated-dependencies:
- dependency-name: github.com/prometheus/prometheus
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
…puting-io/dependabot/go_modules/go-dependencies-d988561a6c

build(deps): bump github.com/prometheus/prometheus from 0.53.0 to 0.53.1 in the go-dependencies group
…afana-login

chore(compose/grafana): allow anonymous login with admin role
This commit improves the README with detailed instructions on how to set up
and run the Docker Compose for VM validations. Additionally, it updates the
steps required to launch the validator tool

Signed-off-by: vprashar2929 <vibhu.sharma2929@gmail.com>
…l-readme

docs(validator): update the documentation for running the validator
Signed-off-by: Vimal Kumar <vimal78@gmail.com>
Signed-off-by: Vimal Kumar <vimal78@gmail.com>
…te-mock-acpi

feat: Add mock-acpi validation to validator
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
Added image signing to workflow using cosign.  Signs images with
GitHub OIDC token, and permissions updated and restricted to
reflect this.

Signed-off-by: Arthur Savage <arthursavage47@gmail.com>
Moved Dockerfile.scaphandre from kepler build repo into
manifests/compose/validation/dockerfiles.

Signed-off-by: Kaiyi <kaiyiliu21@gmail.com>
Bumps the go-dependencies group with 3 updates: [k8s.io/api](https://github.com/kubernetes/api), [k8s.io/apimachinery](https://github.com/kubernetes/apimachinery) and [k8s.io/client-go](https://github.com/kubernetes/client-go).


Updates `k8s.io/api` from 0.29.6 to 0.29.7
- [Commits](kubernetes/api@v0.29.6...v0.29.7)

Updates `k8s.io/apimachinery` from 0.29.6 to 0.29.7
- [Commits](kubernetes/apimachinery@v0.29.6...v0.29.7)

Updates `k8s.io/client-go` from 0.29.6 to 0.29.7
- [Changelog](https://github.com/kubernetes/client-go/blob/master/CHANGELOG.md)
- [Commits](kubernetes/client-go@v0.29.6...v0.29.7)

---
updated-dependencies:
- dependency-name: k8s.io/api
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go-dependencies
- dependency-name: k8s.io/apimachinery
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go-dependencies
- dependency-name: k8s.io/client-go
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go-dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>
…puting-io/dependabot/go_modules/go-dependencies-08a97c52c3

build(deps): bump the go-dependencies group with 3 updates
maryamtahhan and others added 20 commits September 18, 2024 09:05
…gm-build

fixes: aa66ada adding the needed libraries to the builder stage
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
…puting-io/dependabot/go_modules/go-dependencies-f1759efdc8

build(deps): bump the go-dependencies group across 1 directory with 6 updates
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
…roup-cleanup-globals

chore: cleanup globals in pkg/cgroup
Signed-off-by: Vimal Kumar <vimal78@gmail.com>
…-bpf-metrics

fix(metrics): Remove resource usage check for skipping bpf metrics
Signed-off-by: Vimal Kumar <vimal78@gmail.com>
Signed-off-by: Vimal Kumar <vimal78@gmail.com>
Bumps the github-actions group with 1 update in the / directory: [securego/gosec](https://github.com/securego/gosec).


Updates `securego/gosec` from 2.20.0 to 2.21.3
- [Release notes](https://github.com/securego/gosec/releases)
- [Changelog](https://github.com/securego/gosec/blob/master/.goreleaser.yml)
- [Commits](securego/gosec@6fbd381...be8bd6e)

---
updated-dependencies:
- dependency-name: securego/gosec
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: github-actions
...

Signed-off-by: dependabot[bot] <support@github.com>
…bvirt-exporter

chore(compose): Add libvirt-exporter
…puting-io/dependabot/github_actions/github-actions-c2deb92154

build(deps): bump securego/gosec from 2.20.0 to 2.21.3 in the github-actions group across 1 directory
… github-actions group across 1 directory"

Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
…puting-io/revert-1794-dependabot/github_actions/github-actions-c2deb92154

Revert "build(deps): bump securego/gosec from 2.20.0 to 2.21.3 in the github-actions group across 1 directory"
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
…e-bpf-overhead

fix(bpf): exclude bpf overhead in bpf_cpu_time
…date-gosec-to-master

chore: update gosec to use master
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
…tfix-dcgm-init

fix: error initializing dcgm
Signed-off-by: Maryam Tahhan <mtahhan@redhat.com>
@rootfs rootfs requested review from sthaha and sunya-ch October 9, 2024 14:57
Copy link
Contributor

github-actions bot commented Oct 9, 2024

🤖 SeineSailor

Here is a concise summary of the pull request changes:

Summary: This pull request introduces unit tests for the logarithmic regression model and SGD regressor model in the regressor package, specifically testing the GetComponentsPower function and power calculation results. The changes are internal and do not affect the external interface or behavior of the code.

Key Modifications:

  • Added unit tests for logarithmic regression model and SGD regressor model
  • Tested GetComponentsPower function and power calculation results

Impact: The changes are limited to internal testing code and do not affect the external interface or behavior of the code.

Observations/Suggestions:

  • It's great to see the addition of unit tests to improve code coverage and reliability.
  • Consider adding more comprehensive tests to cover edge cases and ensure the models' correctness.
  • Since this is a work-in-progress change, it's essential to ensure that the tests are properly reviewed and validated before merging.

@rootfs rootfs changed the title [WIP] chore: unit test regressors to match estimator results chore: unit test regressors to match estimator results Oct 9, 2024
Signed-off-by: Huamin Chen <hchen@redhat.com>
Copy link
Collaborator

@sunya-ch sunya-ch left a comment

Choose a reason for hiding this comment

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

Mostly looks good to me. Just leave a comment.
Thank you.

// Test power calculation. The results should match those from estimator
// https://github.com/sustainable-computing-io/kepler-model-server/pull/493#discussion_r1795610556
testModel("https://raw.githubusercontent.com/sustainable-computing-io/kepler-model-db/refs/heads/main/models/v0.7/ec2-0.7.11/rapl-sysfs/AbsPower/BPFOnly/SGDRegressorTrainer_0.json",
types.LinearRegressionTrainer, 146994, 18704, 146994)
Copy link
Collaborator

Choose a reason for hiding this comment

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

We may make the note that the expected value must be updated if when the model at the target URL has changed.

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.