forked from TrueCloudLab/frostfs-api-go
[#199] sdk/netmap: Correct linter's remarks
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
459d295788
commit
3a966ee5df
9 changed files with 69 additions and 37 deletions
|
@ -70,10 +70,12 @@ func (c *Context) setPivot(pivot []byte) {
|
|||
func GetDefaultWeightFunc(ns Nodes) weightFunc {
|
||||
mean := newMeanAgg()
|
||||
min := newMinAgg()
|
||||
|
||||
for i := range ns {
|
||||
mean.Add(float64(ns[i].Capacity))
|
||||
min.Add(float64(ns[i].Price))
|
||||
}
|
||||
|
||||
return newWeightFunc(
|
||||
newSigmoidNorm(mean.Compute()),
|
||||
newReverseMinNorm(min.Compute()))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue