sustainable-computing-io / kepler

Kepler (Kubernetes-based Efficient Power Level Exporter) uses eBPF to probe performance counters and other system stats, use ML models to estimate workload energy consumption based on these stats, and exports them as Prometheus metrics
https://sustainable-computing.io
Apache License 2.0
1.19k stars 184 forks source link

fix(validator): multiply mape value by 100 to get percentage error #1823

Closed vprashar2929 closed 1 month ago

vprashar2929 commented 1 month ago

This commit fixes the mape values returned by validator by multiplying them by 100 to get percentage error.

github-actions[bot] commented 1 month ago

🤖 SeineSailor

Here is a concise summary of the pull request changes:

Summary: This PR updates the mape function in the validator module to return Mean Absolute Percentage Error (MAPE) values as percentages by multiplying them by 100. The change is internal and does not affect the external interface or behavior of the code, except for the returned error values now being represented as percentages.

Key Modifications:

Impact: The change is confined to the internal implementation and does not affect the signatures of exported functions or global data structures. The only impact is that returned error values are now represented as percentages instead of raw MAPE values.

Observations/Suggestions: The change is straightforward and well-contained. However, it would be beneficial to include a comment in the code explaining the reason behind multiplying MAPE values by 100, to provide context for future maintainers. Additionally, consider updating any relevant documentation to reflect the change in error value representation.