Skip to content

Commit

Permalink
fixed dimensions when is_folded=True
Browse files Browse the repository at this point in the history
  • Loading branch information
Alice Capecchi committed Sep 15, 2020
1 parent a41f45d commit 1457602
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion map4/map4.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ def __init__(self, dimensions=1024, radius=2, is_counted=False, is_folded=False,
"""
MAP4 calculator class
"""
self.dimensions = dimensions
self.radius = radius
self.is_counted = is_counted
self.is_folded = is_folded
Expand Down Expand Up @@ -70,7 +71,7 @@ def _calculate(self, mol):

def _fold(self, pairs):
fp_hash = self.encoder.hash(set(pairs))
return self.encoder.fold(fp_hash)
return self.encoder.fold(fp_hash, self.dimensions)

def _get_atom_envs(self, mol):
atoms_env = {}
Expand Down

0 comments on commit 1457602

Please sign in to comment.