[ 
https://issues.apache.org/jira/browse/MADLIB-1486?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17555915#comment-17555915
 ] 

penguin commented on MADLIB-1486:
---------------------------------

 

Hello [~okislal] :

The error message is:

-----------------------------------------------------------
Notebook  Supervised-learning/Elastic-net-v3.ipynb
 
DROP TABLE IF EXISTS houses_en, houses_en_summary;
SELECT madlib.elastic_net_train( 'houses',                  -- Source table
                                 'houses_en',               -- Result table
                                 'price',                   -- Dependent 
variable
                                 'array[tax, bath, size]',  -- Independent 
variable
                                 'gaussian',                -- Regression family
                                 0.5,                       -- Alpha value
                                 0.1,                       -- Lambda value
                                 TRUE,                      -- Standardize
                                 NULL,                      -- Grouping 
column(s)
                                 'fista',                   -- Optimizer
                                 '',                        -- Optimizer 
parameters
                                 NULL,                      -- Excluded columns
                                 10000,                     -- Maximum 
iterations
                                 1e-6                       -- Tolerance value
                               );
SELECT * FROM houses_en;
 
The errors output is:
InternalError: (psycopg2.errors.ExternalRoutineException) 
spiexceptions.ExternalRoutineException: error fetching next item from iterator 
DETAIL: TypeError: slice indices must be integers or None or have an __index__ 
method CONTEXT: Traceback (most recent call last): PL/Python function 
"elastic_net_train", line 21, in <module> return elastic_net.elastic_net_train( 
PL/Python function "elastic_net_train", line 344, in elastic_net_train 
PL/Python function "elastic_net_train", line 381, in 
_internal_elastic_net_train PL/Python function "elastic_net_train", line 15, in 
_elastic_net_gaussian_fista_train PL/Python function "elastic_net_train", line 
159, in _elastic_net_fista_train PL/Python function "elastic_net_train", line 
262, in _elastic_net_fista_train_compute PL/Python function 
"elastic_net_train", line 403, in _compute_fista PL/Python function 
"elastic_net_train", line 552, in test PL/Python function "elastic_net_train" 
[SQL: SELECT madlib.elastic_net_train( 'houses', -- Source table 'houses_en', 
-- Result table 'price', -- Dependent variable 'array[tax, bath, size]', -- 
Independent variable 'gaussian', -- Regression family 0.5, -- Alpha value 0.1, 
-- Lambda value TRUE, -- Standardize NULL, -- Grouping column(s) 'fista', -- 
Optimizer '', -- Optimizer parameters NULL, -- Excluded columns 10000, -- 
Maximum iterations 1e-6 -- Tolerance value );] (Background on this error at: 
[https://sqlalche.me/e/14/2j85)]
 

> Madlib support python3.0
> ------------------------
>
>                 Key: MADLIB-1486
>                 URL: https://issues.apache.org/jira/browse/MADLIB-1486
>             Project: Apache MADlib
>          Issue Type: Wish
>            Reporter: penguin
>            Priority: Critical
>
> I tried to run madlib on postgres 13 but I failed. I then found that madlib 
> can only support python2.7 instead of python3. Do you plan to support 
> python3.0?



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

Reply via email to