Live data from Hacker News

Node.js and Python Interoperability

fridgerator.github.io

21–22 of 22 posts

Re: Node.js and Python Interoperability

#21
We needed to solve this as part of using pydata/GPU service calls from our node app. While we do have a couple of native modules, they're a PITA. Our solution for more generic code is async HTTP service calls passing typed Apache Arrow tables ( https://arrow.apache.org/docs/js/ ), which gives a cleaner path to maintenance, observability, packaging, distribution, low overhead etc.

The current trick we're looking at is making this zero-copy when same-node, esp for GPU code, so happy to chat with folks about that!

Re: Node.js and Python Interoperability

#22

I'm having the requirement to work with Node and Python now. I write my webapps in node but have data analytics scripts written in python to be invoked. I'm planning to use [python-shell - npm]( https://www.npmjs.com/package/python-shell )

There's also python-bridge: https://github.com/Submersible/node-python-bridge

I don't recall now why I chose it over the much more popular python-shell. Sigh - the exploratory-spike log is sparse, and then "that all works, so why revisit low-commitment choices". I used it last year for a python helper, to offload some opencv and tensorflow optical tracking from electron.

(Both exist, and work, in javascript. But opencv had painfully subtle issues even with py3 vs py2, so I payed complexity to be closer to then mainstream center py2. And then moved tf over to work around chromium's excellent video latency and load (for passthrough AR) becoming much less so when also touched by the cpu.)

Post reply on HN