Skip to content

Commit

Permalink
input vec
Browse files Browse the repository at this point in the history
  • Loading branch information
cactuskid committed Aug 30, 2024
1 parent 7b713bd commit d550320
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/HogProf/lshbuilder.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ def __init__(self,h5_oma=None,fileglob = None, taxa=None,masterTree=None, saving
#load machine learning weights
self.treeweights = treeweights
tax_max = max(self.taxaIndex.values())+1
wmg = WeightedMinHashGenerator(3*tax_max, sample_size = numperm , seed=1)
wmg = WeightedMinHashGenerator(3*tax_max , sample_size = numperm , seed=1)
with open( self.saving_path + 'wmg.pkl', 'wb') as wmgout:
wmgout.write( pickle.dumps(wmg))
self.wmg = wmg
Expand Down
2 changes: 1 addition & 1 deletion src/HogProf/utils/hashutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def hash_tree(tp , taxaIndex , treeweights , wmg , lossonly = False , duplonly =
input_vec = list(hog_matrix_weighted.flatten())

if wmg.dim == len(input_vec):
weighted_hash = wmg.minhash()
weighted_hash = wmg.minhash(input_vec)
return hog_matrix_binary , weighted_hash

else:
Expand Down

0 comments on commit d550320

Please sign in to comment.