Has anyone used erlport to call python is that recommended?

I need to do an algorithm to group some geo points I’ve seen implementations of KNN made in python using good libraries like numpy, has anyone done somthing similar this with erlport?

I’ve not used erlport nor export (elixir wrapper around erlport) so far. For me it wasn’t necessary.

But in elixir and erlang it is a common idiom to delegate some workload to external systems that are better suited. Thats exactly the cause why we have all those nice facilities do communicate with those services and some do even integrate nicely in a supervision tree.

Therefore I do not see any problems in using ~r/e(rl|x)port/

2 Likes

Even just using the normal built-in Port is fine. erlport and others are primarily useful if the called program is not aware of the BEAM, but if it is and as such it communicates over stdin/stdout and closes when stdin closes then just Port is perfectly fine.

And yes, Python communicates wonderfully over Ports, and there are some good libraries to marshall things in ETF, making this very simple and fast to communicate too.

1 Like