Skip to content

Commit

Permalink
rm deaultf pararms + set default to minhash
Browse files Browse the repository at this point in the history
  • Loading branch information
TwsThomas committed Aug 18, 2020
1 parent bdaa1ab commit 8de9993
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion dirty_cat/minhash_encoder.py
Expand Up @@ -57,7 +57,7 @@ class MinHashEncoder(BaseEstimator, TransformerMixin):
"""

def __init__(self, n_components, ngram_range=(2, 4),
def __init__(self, n_components=30, ngram_range=(2, 4),
hashing='fast', minmax_hash=False):
self.ngram_range = ngram_range
self.n_components = n_components
Expand Down
3 changes: 1 addition & 2 deletions examples/02_fit_predict_plot_employee_salaries.py
Expand Up @@ -73,8 +73,7 @@
'one-hot': OneHotEncoder(handle_unknown='ignore', sparse=False),
'similarity': SimilarityEncoder(similarity='ngram'),
'target': TargetEncoder(handle_unknown='ignore'),
'minhash': MinHashEncoder(n_components=100, ngram_range=(2, 4),
hashing='fast', minmax_hash=False),
'minhash': MinHashEncoder(n_components=100),
'numerical': FunctionTransformer(None)}

# We then create a function that takes one key of our ``encoders_dict``,
Expand Down
3 changes: 1 addition & 2 deletions examples/03_fit_predict_plot_midwest_survey.py
Expand Up @@ -69,8 +69,7 @@
encoder_dict = {
'one-hot': OneHotEncoder(handle_unknown='ignore', sparse=False),
'similarity': SimilarityEncoder(similarity='ngram'),
'minhash': MinHashEncoder(n_components=30, ngram_range=(2, 4),
hashing='fast', minmax_hash=False),
'minhash': MinHashEncoder(),
'num': FunctionTransformer(None)
}
##############################################################################
Expand Down

0 comments on commit 8de9993

Please sign in to comment.