njayaram2 commented on a change in pull request #373: Changed default 
max_item_size to 10
URL: https://github.com/apache/madlib/pull/373#discussion_r278319642
 
 

 ##########
 File path: src/ports/postgres/modules/assoc_rules/assoc_rules.py_in
 ##########
 @@ -63,9 +63,8 @@ def assoc_rules(madlib_schema, support, confidence, tid_col,
     begin_func_exec = time.time();
     begin_step_exec = time.time();
     cal_itemsets_time = 0;
-    if max_itemset_size is None:
-        max_itemset_size = float('inf')
-    elif max_itemset_size <= 1:
 
 Review comment:
   I just realized while testing more thoroughly that this `if` statement 
should not be removed, apologies for the previous comment.
   `max_itemset_size` is an optional parameter, so `NULL` is an acceptable 
value in the input param. If it's `NULL`, we should set it to `10` instead of 
`float('inf')`:
   ```
   if max_itemset_size is None:
           max_itemset_size = float('inf')
   elif max_itemset_size <= 1:
           plpy.error("ERROR: max_itemset_size has to be greater than 1.")
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to