Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a Wrapper for Julia #164

Open
RoyiAvital opened this issue Jun 29, 2024 · 3 comments
Open

Add a Wrapper for Julia #164

RoyiAvital opened this issue Jun 29, 2024 · 3 comments

Comments

@RoyiAvital
Copy link

It would be great to be able to use DIPLib in Julia.

I'd recommend having no dependency on the current Image library of Julia and just use the regular AbstractArray as the data type.

@crisluengo
Copy link
Member

I looked into Julia bindings back in 2015 or so when I started thinking about the C++ rewrite of DIPlib. Back then there was only a C API, I don’t know if there’s a way to bind C++ libraries now.

But back then the Julia community seemed totally uninterested in DIPlib bindings, it seemed to me that they only wanted packages written in Julia. Which seems dumb to me, why would you re-implement algorithms just to have them be written in your own language? Maybe the ideas in the community are different now, I don’t know.

So, if it’s possible (and not too complicated) to bind a C++ library, and there are people in the Julia community actually interested in using it, then I’d be more than happy to accept Julia bindings in this repository.

I don’t know Julia at all (got disappointed in it back then, haven’t looked at it since), and don’t have the time for a major push like this on my own. But if you or anyone else is interested in writing these bindings, I’ll be happy to help.

@RoyiAvital
Copy link
Author

I think back then it was indeed the trend.
Do all in Julia.

Yet a decade later, the Julia eco system for Image Processing and Computer Vision is pretty lean.
So DIPLib could be a major boost.

I know no C++ and not enough low level Julia.
Hopefully, someone with the proper knowledge will be exposed to this.

@crisluengo
Copy link
Member

crisluengo commented Jun 29, 2024

It looks like there is something similar in spirit to Pybind11 to wrap a C++ library for use in Julia: https://github.com/JuliaInterop/CxxWrap.jl

It being similar means we should be able to reuse a lot of the work we did for Python.

But Julia not having classes might make it hard to translate some core concepts such as the distinction between spatial dimensions and tensor dimensions, pixel sizes being attached to an image, etc. I don’t know enough Julia to say for sure, there might be some way to do this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants