Repository: mindsdb/lightwood

Issue:
Dataset from 'Process Quality` tutorial doesn't work
[A tutorial](https://docs.mindsdb.com/sql/tutorials/process-quality/)

```
INFO:lightwood-31930:Dropping features: []
INFO:lightwood-31930:Analyzing a sample of 952
INFO:lightwood-31930:from a total population of 1000, this is equivalent to 95.2% of your data.
INFO:lightwood-31930:Using 7 processes to deduct types.
INFO:lightwood-31948:Infering type for: silica_feed
INFO:lightwood-31948:Column silica_feed has data type binary
INFO:lightwood-31948:Infering type for: flotation_column_01_air_flow
INFO:lightwood-31948:Column flotation_column_01_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_02_air_flow
INFO:lightwood-31948:Column flotation_column_02_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_03_air_flow
INFO:lightwood-31948:Column flotation_column_03_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_04_air_flow
INFO:lightwood-31948:Column flotation_column_04_air_flow has data type binary
INFO:lightwood-31948:Infering type for: flotation_column_05_air_flow
INFO:lightwood-31948:Column flotation_column_05_air_flow has data type binary
INFO:lightwood-31948:Infering type for: flotation_column_06_air_flow
INFO:lightwood-31948:Column flotation_column_06_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_07_air_flow
INFO:lightwood-31948:Column flotation_column_07_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_01_level
INFO:lightwood-31948:Column flotation_column_01_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_02_level
INFO:lightwood-31948:Column flotation_column_02_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_03_level
INFO:lightwood-31948:Column flotation_column_03_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_04_level
INFO:lightwood-31952:Infering type for: ore_pulp_density
INFO:lightwood-31948:Column flotation_column_04_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_05_level
INFO:lightwood-31952:Column ore_pulp_density has data type float
INFO:lightwood-31952:Infering type for: flotation_column_06_level
INFO:lightwood-31948:Column flotation_column_05_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_07_level
INFO:lightwood-31952:Column flotation_column_06_level has data type float
INFO:lightwood-31952:Infering type for: iron_concentrate
INFO:lightwood-31948:Column flotation_column_07_level has data type float
INFO:lightwood-31952:Column iron_concentrate has data type tags
INFO:lightwood-31948:Infering type for: silica_concentrate
INFO:lightwood-31948:Column silica_concentrate has data type tags
..................................................................................................................
INFO:lightwood-31930:Started fitting LGBM model
ERROR:lightwood-31930:Lightgbm mixer not supported for type: tags
WARNING:lightwood-31930:Exception: Lightgbm mixer not supported for type: tags when training mixer: <lightwood.mixer.lightgbm.LightGBM object at 0x7f24ec574f40>

```

Dataset from 'Process Quality` tutorial doesn't work
[A tutorial](https://docs.mindsdb.com/sql/tutorials/process-quality/)

```
INFO:lightwood-31930:Dropping features: []
INFO:lightwood-31930:Analyzing a sample of 952
INFO:lightwood-31930:from a total population of 1000, this is equivalent to 95.2% of your data.
INFO:lightwood-31930:Using 7 processes to deduct types.
INFO:lightwood-31948:Infering type for: silica_feed
INFO:lightwood-31948:Column silica_feed has data type binary
INFO:lightwood-31948:Infering type for: flotation_column_01_air_flow
INFO:lightwood-31948:Column flotation_column_01_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_02_air_flow
INFO:lightwood-31948:Column flotation_column_02_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_03_air_flow
INFO:lightwood-31948:Column flotation_column_03_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_04_air_flow
INFO:lightwood-31948:Column flotation_column_04_air_flow has data type binary
INFO:lightwood-31948:Infering type for: flotation_column_05_air_flow
INFO:lightwood-31948:Column flotation_column_05_air_flow has data type binary
INFO:lightwood-31948:Infering type for: flotation_column_06_air_flow
INFO:lightwood-31948:Column flotation_column_06_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_07_air_flow
INFO:lightwood-31948:Column flotation_column_07_air_flow has data type tags
INFO:lightwood-31948:Infering type for: flotation_column_01_level
INFO:lightwood-31948:Column flotation_column_01_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_02_level
INFO:lightwood-31948:Column flotation_column_02_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_03_level
INFO:lightwood-31948:Column flotation_column_03_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_04_level
INFO:lightwood-31952:Infering type for: ore_pulp_density
INFO:lightwood-31948:Column flotation_column_04_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_05_level
INFO:lightwood-31952:Column ore_pulp_density has data type float
INFO:lightwood-31952:Infering type for: flotation_column_06_level
INFO:lightwood-31948:Column flotation_column_05_level has data type float
INFO:lightwood-31948:Infering type for: flotation_column_07_level
INFO:lightwood-31952:Column flotation_column_06_level has data type float
INFO:lightwood-31952:Infering type for: iron_concentrate
INFO:lightwood-31948:Column flotation_column_07_level has data type float
INFO:lightwood-31952:Column iron_concentrate has data type tags
INFO:lightwood-31948:Infering type for: silica_concentrate
INFO:lightwood-31948:Column silica_concentrate has data type tags
..................................................................................................................
INFO:lightwood-31930:Started fitting LGBM model
ERROR:lightwood-31930:Lightgbm mixer not supported for type: tags
WARNING:lightwood-31930:Exception: Lightgbm mixer not supported for type: tags when training mixer: <lightwood.mixer.lightgbm.LightGBM object at 0x7f24ec574f40>

```



Discussion:

Resolving patch:
diff --git a/lightwood/data/infer_types.py b/lightwood/data/infer_types.py
--- a/lightwood/data/infer_types.py
+++ b/lightwood/data/infer_types.py
@@ -236,9 +236,9 @@ def get_column_data_type(arg_tup):
                 lengths.append(len(item_tags))
                 unique_tokens = unique_tokens.union(set(item_tags))
 
-        # If more than 30% of the samples contain more than 1 category and there's more than 6 of them and they are shared between the various cells # noqa
+        # If more than 30% of the samples contain more than 1 category and there's more than 6 and less than 30 of them and they are shared between the various cells # noqa
         if (can_be_tags and np.mean(lengths) > 1.3 and
-                len(unique_tokens) >= 6 and
+                6 <= len(unique_tokens) <= 30 and
                 len(unique_tokens) / np.mean(lengths) < (len(data) / 4)):
             curr_dtype = dtype.tags
 


Test patch: