problem "fit" with current relation #1339
Unanswered
lepelletieralexandre
asked this question in
Potential bug
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
There is a bug when I use the "fit" method with "LogisticRegression" model.
In fact, I have this error :
MissingRelation: Severity: ERROR, Message: Relation "SCHEMA.TVUL_STAT_titanic_CHAID_INT_SANS_NA_ SELECT ION_OK_DECOUP_MAIN_TRAIN_TEST_train_DUMMIES_MODELE_titanic_test" does not exist, Sqlstate: 42V01, Routine: throwRelationDoesNotExist,
There are 2 spaces between "SELECT" for "SELECTION" word which have been added.
I found where the problem comes from.
In "fit" method here : https://github.com/vertica/VerticaPy/blob/master/verticapy/machine_learning/vertica/base.py , line 2354, you use "self.input_relation = input_relation.current_relation()". But, by default, the parameter "reindent" in "current_relation" function is TRUE.
line 432 here -> https://github.com/vertica/VerticaPy/blob/master/verticapy/core/vdataframe/_sys.py#L432 , you call "indent_vpy_sql" function, which is define here line 1219 -> https://github.com/vertica/VerticaPy/blob/master/verticapy/_utils/_sql/_format.py , where spaces are adds between "SELECT" word.
I think, when we use "fit" fonction, the "reindent" parameter from "current_relation" need to be False. And, in general, all function which call "current_relation" function to capture "input_relation" in the code need to define False value to "reindent" parameter ;
for exemple, line 7837 for class Unsupervised(VerticaModel).
Can you fix this problem?
Best regards,
Alexandre
Beta Was this translation helpful? Give feedback.
All reactions