mirror of
https://github.com/TheAlgorithms/Python.git
synced 2024-11-23 21:11:08 +00:00
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
This commit is contained in:
parent
8735fb0e66
commit
af4a64b125
|
@ -60,7 +60,11 @@ class GaussianFuzzySet:
|
||||||
|
|
||||||
membership_value = np.exp(-0.5 * ((member - self.mean) / self.std_dev) ** 2)
|
membership_value = np.exp(-0.5 * ((member - self.mean) / self.std_dev) ** 2)
|
||||||
# Directly return for non-complement or return 1 - membership for complement
|
# Directly return for non-complement or return 1 - membership for complement
|
||||||
return float(membership_value) if not self.is_complement else 1 - float(membership_value)
|
return (
|
||||||
|
float(membership_value)
|
||||||
|
if not self.is_complement
|
||||||
|
else 1 - float(membership_value)
|
||||||
|
)
|
||||||
|
|
||||||
def complement(self) -> GaussianFuzzySet:
|
def complement(self) -> GaussianFuzzySet:
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Reference in New Issue
Block a user