Skip to content
Snippets Groups Projects
Commit 5c44156c authored by MoritzThomasHuebner's avatar MoritzThomasHuebner
Browse files

Simplified an unrelated expression

parent c91c8b2a
No related branches found
No related tags found
1 merge request!230Resolve "PEP8 Imports"
Pipeline #33362 failed
......@@ -23,11 +23,9 @@ class Model(object):
self.parameters[key] = None
def prob(self, data):
probability = 1.0
for ii, function in enumerate(self.models):
if ii == 0:
probability = function(data, **self._get_function_parameters(function))
else:
probability *= function(data, **self._get_function_parameters(function))
probability *= function(data, **self._get_function_parameters(function))
return probability
def _get_function_parameters(self, function):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment