Rapl node capping daemon #21
13
rapl-daemon/README.md
Normal file
|
@ -0,0 +1,13 @@
|
|||
![]() capable of changing capable **of** changing
|
||||
# RAPL Daemon
|
||||
![]() capable of changing capable **of** changing
|
||||
|
||||
![]() capable of changing capable **of** changing
|
||||
This runs a server that is capable changing the percentage at which
|
||||
![]() capable of changing capable **of** changing
|
||||
a node is being throttled using RAPL. This daemon should be installed
|
||||
![]() capable of changing capable **of** changing
|
||||
on all worker nodes.
|
||||
![]() capable of changing capable **of** changing
|
||||
|
||||
![]() capable of changing capable **of** changing
|
||||
### Sample payload for testing:
|
||||
![]() capable of changing capable **of** changing
|
||||
```
|
||||
![]() capable of changing capable **of** changing
|
||||
curl --header "Content-Type: application/json" \
|
||||
![]() capable of changing capable **of** changing
|
||||
--request POST \
|
||||
![]() capable of changing capable **of** changing
|
||||
--data '{"percentage":75}' \
|
||||
![]() capable of changing capable **of** changing
|
||||
http://localhost:9090/powercap
|
||||
![]() capable of changing capable **of** changing
|
||||
```
|
||||
![]() capable of changing capable **of** changing
|
49
rapl-daemon/main.go
Normal file
|
@ -0,0 +1,49 @@
|
|||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
package main
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
import (
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
"encoding/json"
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
"fmt"
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
"html"
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
"log"
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
"net/http"
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
const powercapDir = "/sys/class/powercap/"
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
// Cap is a payload that is expected from Elektron to cap a node
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
type Cap struct {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
Percentage int
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
}
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
func main() {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
fmt.Fprintf(w, "Unsupported endpoint %s", html.EscapeString(r.URL.Path))
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
})
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
http.HandleFunc("/powercap", powercapEndpoint)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
log.Fatal(http.ListenAndServe(":9090", nil))
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
}
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
// Handler powercapping HTTP API endpoint
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
![]() error messages should be lowercase. error messages should be lowercase.
![]() In this case this is some http content being served back to to the client that made the request. I did make it lower case though. In this case this is some http content being served back to to the client that made the request. I did make it lower case though.
|
||||
func powercapEndpoint(w http.ResponseWriter, r *http.Request) {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
var payload Cap
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
decoder := json.NewDecoder(r.Body)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
err := decoder.Decode(&payload)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
if err != nil {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
http.Error(w, "Error parsing payload: "+err.Error(), 400)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
return
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
}
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
if payload.Percentage < 0 || payload.Percentage > 100 {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
http.Error(w, "Bad payload: percentage must be between 0 and 100", 400)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
return
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
}
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
err = capNode(powercapDir, payload.Percentage)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
if err != nil {
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
http.Error(w, err.Error(), 400)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
return
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
}
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
fmt.Fprintf(w, "Capped node at %d percent", payload.Percentage)
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
||||
}
|
||||
![]() missing period at the end of the sentence. missing period at the end of the sentence.
![]() missing period at end of sentence. missing period at end of sentence.
|
88
rapl-daemon/util.go
Normal file
|
@ -0,0 +1,88 @@
|
|||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
package main
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
import (
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
"fmt"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
"io/ioutil"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
"math"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
"path/filepath"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
"strconv"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
"strings"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
const raplPrefixCPU = "intel-rapl"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// constraint_0 is usually the longer window while constraint_1 is usually the longer window
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
const maxPowerFileShortWindow = "constraint_0_max_power_uw"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
const powerLimitFileShortWindow = "constraint_0_power_limit_uw"
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// capNode uses pseudo files made available by the Linux kernel
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// in order to capNode CPU power. More information is available at:
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// https://www.kernel.org/doc/html/latest/power/powercap/powercap.html
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
func capNode(base string, percentage int) error {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if percentage <= 0 || percentage > 100 {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return fmt.Errorf("cap percentage must be between 0 (non-inclusive) and 100 (inclusive): %d", percentage)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
files, err := ioutil.ReadDir(base)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if err != nil {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return err
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
for _, file := range files {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
fields := strings.Split(file.Name(), ":")
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// Fields should be in the form intel-rapl:X where X is the power zone
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// We ignore sub-zones which follow the form intel-rapl:X:Y
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if len(fields) != 2 {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
continue
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if fields[0] == raplPrefixCPU {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
maxPower, err := maxPower(filepath.Join(base, file.Name(), maxPowerFileShortWindow))
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if err != nil {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
fmt.Println("unable to retreive max power for zone ", err)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
continue
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
![]() any reason for just printing the error and not returning it? any reason for just printing the error and not returning it?
Basically, the question is whether we need to continue to attempt to powercap if an error occurs anywhere in the process.
![]() Agreed, I don't know what the right path to take is here. If the file write fails, we could be left in an inconsistent state. The only options here are to bail and return an error right away, or to continue trying to cap the node and then returning an array of zones where were unable to cap the node in. Agreed, I don't know what the right path to take is here. If the file write fails, we could be left in an inconsistent state. The only options here are to bail and return an error right away, or to continue trying to cap the node and then returning an array of zones where were unable to cap the node in.
![]() Any chance we can roll back the power limits set to the previous values if and when any of the file writes fail? Any chance we can roll back the power limits set to the previous values if and when any of the file writes fail?
![]() If the write fails, we're sort of left in limbo. If the write to modify it failed, then most likely the write to restore the value will fail too. We can try reading it and seeing if that's the same value as before. If the write fails, we're sort of left in limbo. If the write to modify it failed, then most likely the write to restore the value will fail too. We can try reading it and seeing if that's the same value as before.
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// We use floats to mitigate the possibility of an integer overflows.
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
powercap := uint(math.Ceil(float64(maxPower) * (float64(percentage) / 100)))
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
err = capZone(filepath.Join(base, file.Name(), powerLimitFileShortWindow), powercap)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if err != nil {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
fmt.Println("unable to write powercap value: ", err)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
continue
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
![]() same here regarding whether the error to continue if error occurs or should we just return it. same here regarding whether the error to continue if error occurs or should we just return it.
|
||||
fmt.Println(file.Name(), ": ", int(maxPower), ", ", int(powercap))
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return nil
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// maxPower returns the value in float of the maximum watts a power zone
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// can use.
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
func maxPower(zone string) (uint64, error) {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
maxPower, err := ioutil.ReadFile(zone)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if err != nil {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return 0.0, err
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
maxPoweruW, err := strconv.ParseUint(strings.TrimSpace(string(maxPower)), 10, 64)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if err != nil {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return 0.0, err
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return maxPoweruW, nil
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
// capZone caps a power zone to a specific amount of watts specified by value
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
func capZone(zone string, value uint) error {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
err := ioutil.WriteFile(zone, []byte(string(value)), 0644)
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
if err != nil {
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return err
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
return nil
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
||||
}
|
||||
![]() constraint_1 is the shorter window. constraint_1 is the shorter window.
![]() maybe just say cap percentage must be in the range (0, 100]. maybe just say **cap percentage must be in the range (0, 100]**.
![]() constraint_0 is the longer window. constraint_0 is the longer window.
Going by [this](https://github.com/spdfg/elektron/blob/master/scripts/RAPL_PKG_Throttle.py#L48) we are intending to use the longer window for running average calculations.
So, change the variable name to `maxPowerFileLongWindow`?
![]() ditto. ditto.
![]() overflow overflow~s~
![]() fits on a single line. fits on a single line.
![]() Can you expand on this comment? Can you expand on this comment?
![]() Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is. Actually, your way of representing the ranges is more explicit and clear. One is not well-versed with range expressions would still be able to understand your explanation. So, ignore my previous statement and leave it as is.
![]() Either change overflows to overflow, or get rid of the "an". Either change **overflows** to **overflow**, or get rid of the "an".
![]() Good catch, fixed. Good catch, fixed.
![]() Fixed this, definitely a mistake on my part. Thanks for catching it! Fixed this, definitely a mistake on my part. Thanks for catching it!
![]() I'll revert it I'll revert it
|
14
rapl-daemon/util_test.go
Normal file
|
@ -0,0 +1,14 @@
|
|||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
package main
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
import "testing"
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
// TODO(rdelvalle): Add more thourough testing. Generate mock files
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
// that mimic the powercap subsystem and create test to operate on it.
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
func TestCap(t *testing.T) {
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
err := capNode("/sys/devices/virtual/powercap/intel-rapl", 95)
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
if err != nil {
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
t.Fail()
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
}
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
||||
}
|
||||
![]() I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default. I think it's safe to use spaces ("bad percentage") as the words are hyphenated by default.
Although, I do not mind the camelcasing.
![]() Good point, fixed. Good point, fixed.
|
capable of changing