Skip to content

Commit

Permalink
Bug fix in norm_score
Browse files Browse the repository at this point in the history
  • Loading branch information
rgerkin committed Feb 13, 2020
1 parent b517482 commit 48c1892
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sciunit/scores/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,19 +95,19 @@ def norm_score(self):
def log_norm_score(self):
"""The natural logarithm of the `norm_score`.
This is useful for guaranteeing convexity in an error surface"""
return np.log(s.norm_score) if s.norm_score is not None else None
return np.log(self.norm_score) if self.norm_score is not None else None

@property
def log2_norm_score(self):
"""The logarithm base 2 of the `norm_score`.
This is useful for guaranteeing convexity in an error surface"""
return np.log2(s.norm_score) if s.norm_score is not None else None
return np.log2(self.norm_score) if self.norm_score is not None else None

@property
def log10_norm_score(self):
"""The logarithm base 10 of the `norm_score`.
This is useful for guaranteeing convexity in an error surface"""
return np.log10(s.norm_score) if s.norm_score is not None else None
return np.log10(self.norm_score) if self.norm_score is not None else None

def color(self, value=None):
"""Turn the score intp an RGB color tuple of three 8-bit integers."""
Expand Down

0 comments on commit 48c1892

Please sign in to comment.