Github user njayaram2 commented on a diff in the pull request:

    https://github.com/apache/incubator-madlib/pull/156#discussion_r131024096
  
    --- Diff: 
src/ports/postgres/modules/recursive_partitioning/decision_tree.py_in ---
    @@ -825,22 +855,34 @@ def _get_bins(schema_madlib, training_table_name,
                             ({{col}})::text AS levels,
                             {{order_fun}} AS dep_avg
                         FROM {training_table_name}
    -                    WHERE {filter_null}
    -                        AND {{col}} is not NULL
    +                    WHERE {filter_str}
                         GROUP BY {{col}}
    +                    {union_null_proxy}
                     ) s
                 ) s1
                 WHERE array_upper(levels, 1) > 1
                 """.format(training_table_name=training_table_name,
    -                       filter_null=filter_null)
    +                       filter_str=filter_str,
    +                       union_null_proxy=union_null_proxy)
    +
    +        all_col_expressions = {}
    +        for col in cat_features:
    +            if col in boolean_cats:
    +                all_col_expressions[col] = ("(CASE WHEN " + col +
    +                                            " THEN 'True' ELSE 'False' 
END)")
    +            else:
    +                # if null_proxy is not None:
    +                #     all_col_expressions[col] = ("COALESCE({0}, {1})".
    +                #                                 format(col, null_proxy))
    +                # else:
    --- End diff --
    
    Do we need to keep these commented lines?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to