Skip to content

Commit

Permalink
Fix OneHotEncoder.
Browse files Browse the repository at this point in the history
  • Loading branch information
knc6 committed Mar 20, 2024
1 parent b9fbc07 commit e0419b2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions jarvis/core/specie.py
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,8 @@ def get_digitized_feats_hot_encoded(
from sklearn.preprocessing import OneHotEncoder
import pandas as pd

encoder = OneHotEncoder(categories="auto", sparse=False)
encoder = OneHotEncoder(categories="auto", sparse_output=False)
# encoder = OneHotEncoder(categories="auto", sparse=False)
dat = defaultdict()
for i, j in chem_data.items():
tmp = defaultdict()
Expand Down Expand Up @@ -458,7 +459,8 @@ def get_feats_hot_encoded(feature_names=keys, filename="feats_encoded.json"):
from sklearn.preprocessing import OneHotEncoder
import pandas as pd

encoder = OneHotEncoder(categories="auto", sparse=False)
encoder = OneHotEncoder(categories="auto", sparse_output=False)
# encoder = OneHotEncoder(categories="auto", sparse=False)
dat = {}
for i, j in chem_data.items():
tmp = []
Expand Down

0 comments on commit e0419b2

Please sign in to comment.