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 instructions for a conda environment on mac #284

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

jatkinson1000
Copy link
Member

@jatkinson1000 jatkinson1000 commented Feb 13, 2025

Can successfully build FTorch and utilise the MPS backend on Apple Silicon.

This provides an alternative for users on mac, and also acts as a workaround whilst we wait for pytorch/pytorch#143571 to be resolved.

@jatkinson1000
Copy link
Member Author

@jwallwork23 This allows users to build FTorch from inside conda.
The instructions to build are currently based on the existing configuration in main, so will need updating somewhere (depending on the order #276 goes in).

jatkinson1000 and others added 2 commits February 21, 2025 13:44
Copy link
Contributor

@jwallwork23 jwallwork23 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This reads well to me. I'm not able to test it as I don't have access to a Mac, but am otherwise happy with this.

(according to https://pytorch.org/). However, the version of PyTorch provided by
`pip install torch` uses an ARM binary for LibTorch which works on Apple Silicon.
At the time of writing [there are issues](https://github.com/pytorch/pytorch/issues/143571)
building FTorch on apple silicon when linking to downloaded `LibTorch` binaries or
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
building FTorch on apple silicon when linking to downloaded `LibTorch` binaries or
building FTorch on Apple Silicon when linking to downloaded `LibTorch` binaries or

We install PyTorch using `pip` from within the conda environment which should include
the MPS backend.

FTorch can then be build with a CMake command similar to the following:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
FTorch can then be build with a CMake command similar to the following:
FTorch can then be built with a CMake command similar to the following:

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

Successfully merging this pull request may close these issues.

2 participants