Transform a TF-DF into pure Python code #50
rstz
started this conversation in
Show and tell
Replies: 1 comment 1 reply
-
It sounds like transforming a random forest would be more difficult. How much? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Sometimes you might want to use a decision tree in an environment that does not allow any new third-party libraries and very minimal code changes. One (hacky, but fun!) solution is to just transform your decision tree into a pure python function - just a sequence of nested if-else statements. Here's some code to do just that:
Disclaimers
else
part in code generatorBeta Was this translation helpful? Give feedback.
All reactions