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 compatibility layer for Apple mlx #162

Open
j-emberton opened this issue Jul 24, 2024 · 5 comments
Open

Add compatibility layer for Apple mlx #162

j-emberton opened this issue Jul 24, 2024 · 5 comments

Comments

@j-emberton
Copy link

j-emberton commented Jul 24, 2024

MLX is an array library for use on apple silicon. It is intended to closely follow the python Array API however some difference exist.

https://github.com/ml-explore/mlx?tab=readme-ov-file

It would be useful to add compatibility layers for this app to support users wishing to do array operations on apple gpu.

I am happy to lead this if I can be added as contributor.

@lucascolley
Copy link
Contributor

x-ref ml-explore/mlx#48

@asmeurer
Copy link
Member

@j-emberton this is definitely in scope for array-api-compat. If you want to work on this, the best thing to do would be to fork this repository and make a pull request.

Also note that partial support is OK to begin with, so if there's some function that's difficult to support, we can skip it for now. The development notes in the docs are a good place to start for contributing https://data-apis.org/array-api-compat/dev/index.html

@asmeurer
Copy link
Member

asmeurer commented Aug 5, 2024

Also there has been some upstream work in mlx to support the array API (e.g., ml-explore/mlx#1289), so you may want to synchronize with them to see what their plans are. If they are planning to add full support directly to mlx, that is preferable to adding support to the compat library. But if there are things they can't support easily because of backwards compatibility, then we may need a compat wrapper.

@asmeurer
Copy link
Member

asmeurer commented Aug 7, 2024

Based on the discussion at ml-explore/mlx#1289, the MLX folks are open to having full compatibility in MLX itself, so any work on upstream incompatibilities should go there. For now, let's just add helper functions for MLX to array-api-compat.

@asmeurer
Copy link
Member

I don't know if the upstream is doing anything here, but it might be worth revisiting this if they aren't. MLX is a useful library.

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

3 participants