PyTorch has support for using the shaders in the M series chips, but to use it, one has to use the arm64 version of Python. Should a native (in this case, M3) build of Slicer3D be possible? If yes, where should I get the 5.15.2 Qt package (for MacOS arm64)?
Support for a macOS arm64 version of Slicer is something planned though not for the immediate short term. If you have technical build experience you can try following the collection of work arounds to get something working posted in the following issue:
Some uses of PyTorch in things like TotalSegmentator are still not optimized for the MPS usage in PyTorch as seen at:
Therefore I can’t say for sure how much benefit you may get at this time.
@GeneRisi There are some various scripts around that people have tried to build Slicer from source to build a ARM64 variant, but nothing official yet such as Slicer preview build of such a version.
The below issue is still in progress and various Slicer developers have been actively working on a long chain of dependency updates including Qt5 → Qt6 that is part of bringing in ARM64 support across all the various libraries that Slicer uses. It is currently being worked on and I expect it to continue for a month or two.
Nothing to report yet. @jcfr has been working diligently to upgrade Slicer to Qt6 and following that should be able to get to a native arm64 build.
Following some special instructions you can successfully build Slicer on arm64 by building an Intel x86_64 version of the application that runs on Apple Silicon through Rosetta.
do you have the link/docs to do this? and will building like this still run the compiled application on intel macs? or will it only work on arm64 (through rosetta) macs?
The following discourse post provides some details primarily about building for developing features with Slicer, but does include a comment of mine about the qt-easy-build process to build Qt from source while on a macOS arm machine which is necessary for packaging and distribution to other computers to be successful. Even on Intel Macs it is currently required to build Qt for on source to successfully package and distribute. And Yes these instructions will work for distribution onto Intel Macs as well as the arm Macs which will run it through Rosetta.
The preceding work of updating Slicer from Qt5 to Qt6 has made progress and @lassoan has been working to integrate a large number of commits recently to support this effort. Remaining changes for Qt6 support should hopefully wrap up here in the next week and then we will likely update the Slicer Preview to Qt6.
After that support for native arm64 builds will come. With the holidays and an upcoming Slicer project week in late-January - this task may ultimately happen later at that time. @jcfr has switched jobs and has less time available for the Slicer project, but others from Kitware will help support the infrastructure changes necessary to build and distribute arm64 native builds using Slicer factory build machines.