Thread Safety for numpy, pandas for embedded python in UDF

Moderator: NorbertKrupa

Post Reply
dhaneshp
Newbie
Newbie
Posts: 2
Joined: Tue Jan 05, 2016 9:09 am

Thread Safety for numpy, pandas for embedded python in UDF

Post by dhaneshp » Wed Jan 06, 2016 5:21 pm

There seems to be thread-safety issues while invoking python within C++ UDF's especially when the python code calls numpy or pandas. It turns out numpy and pandas aren't inherently thread-safe. As a consequence, scalar UDF's invoking the python code fail, and also it appears only one transform UDF call can be made in a session.

Any pointers on how to ensure thread safety while invoking python within C++ UDF? I see a few links like http://www.codeproject.com/Articles/118 ... -C-Part-II

Would this help? Any recommendations on how to get around this problem?

scutter
Master
Master
Posts: 301
Joined: Tue Aug 07, 2012 2:15 am

Re: Thread Safety for numpy, pandas for embedded python in UDF

Post by scutter » Thu Jan 07, 2016 7:17 pm

You may want to ask this question in the HP Developer Community, where there’s more of an HP presence.

https://community.dev.hpe.com/t5/Vertic ... ms_vertica
Sharon Cutter
Vertica Consultant, Zazz Technologies LLC

Post Reply

Return to “Vertica User Defined Functions (UDFs)”