Closed Proheeler closed 3 years ago
Translation to C++ or JS is performed via Sympy and the error you are seeing looks like an old Sympy feature.
I'm not sure I could help you much here. Sympy's programming language translation capabilities are somewhat flaky in general, and were added to SKompiler's mainly as a fun proof of concept without hopes that those would be 100% reliable. If you need the translation for serious production use, your best bet is to implement a custom SKAST-to-C++ translator manually (PRs welcome!).
However, it may still be useful if you could construct a minimal example for reproducing the problem - perhaps the Sympy issue could be hacked around by redefining the way piecewise functions are represented.
Hi! I'm trying to export RandomForestRegressor to C/C++ (also tried for js). Unfortunately got this exception: unsupported operand type(s) for |=: 'Piecewise' and 'Piecewise'
Can you please help me?