-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
builtins functions are not working when try to save pipeline #371
Comments
You can do aggregation using the special-purpose For binary case, you can express As for Looking at the business logic of your Alternatively, consider using |
Thank you vruusmann but I do not think that there is a direct solution to the problem I wrote and different problems that may arise in the future. Because i put mapper where i take the maximum of 2 numbers as an example, you offered a simple if statement solution, but my main problem was to get the maximum of 4 numbers. It's not elegant to write this with an if statement. In the second example, instead of offering an alternative solution to functions such as round, str, float and int, you suggested mathematical operations, but I don't think it's an elegant solution to write the code that can be replaced all of these functions with mathematical operations. |
The list of supported functions is here: Indeed, there are close to 50 functions to choose from, mostly Numpy. Also, you should pay attention to "missing value awareness" of chosen functions. IIRC, the |
Thank you for your share. It will be useful indeed. |
Hi,
I want to use Dataframe mapping function and Expression transformer for my preprocessing steps. Xgb model has 25 input feature but i wont talk about all the process.
I am having trouble just with bulit-in function in Expression transformer.
Other features that created with Expression transformer are saveable.
Let me put some example:
When i do not use any built in function like mapper_1 it can be saved as pmml.
But i want to use a built-in function like max, str, float sklearn2pmml give me an error.
Standard output is empty
Standard error:
Exception in thread "main" java.lang.IllegalArgumentException: Function 'builtins.max' is not supported
Another example;
Standard output is empty
Standard error:
Exception in thread "main" java.lang.IllegalArgumentException: Function 'builtins.str' is not supported
at org.jpmml.python.FunctionUtil.encodePythonFunction(
FunctionUtil.java:104
How can i handle this situation?
The text was updated successfully, but these errors were encountered: