#332332nd of 433 in ML frameworks and libraries

ml-ane-transformers

Reference PyTorch Transformer code optimized for the Apple Neural Engine

Stars
2.8k
License
custom license
Last commit
Sep 2026
Last release
Aug 2022
Language
Python
Stars, last 30 weeks+54
2 May 2026: 2,696 stars9 May 2026: 2,698 stars16 May 2026: 2,699 stars23 May 2026: 2,702 stars30 May 2026: 2,704 stars6 Jun 2026: 2,706 stars13 Jun 2026: 2,707 stars20 Jun 2026: 2,709 stars27 Jun 2026: 2,709 stars4 Jul 2026: 2,709 stars11 Jul 2026: 2,713 stars18 Jul 2026: 2,719 stars25 Jul 2026: 2,721 stars1 Aug 2026: 2,722 stars8 Aug 2026: 2,723 stars15 Aug 2026: 2,726 stars22 Aug 2026: 2,728 stars29 Aug 2026: 2,731 stars5 Sept 2026: 2,734 stars12 Sept 2026: 2,738 stars19 Sept 2026: 2,740 stars26 Sept 2026: 2,741 stars3 Oct 2026: 2,742 stars10 Oct 2026: 2,743 stars17 Oct 2026: 2,744 stars24 Oct 2026: 2,744 stars31 Oct 2026: 2,748 stars7 Nov 2026: 2,749 stars14 Nov 2026: 2,750 stars21 Nov 2026: 2,750 stars28 Nov 2026: 2,750 stars

2,696 on 2 May 20262,750 on 28 Nov 2026

From GitHub's daily star counts.

Checked on GitHub.

Overview

A Python package with a standalone reference Transformer implementation and ANE-optimized Hugging Face DistilBERT classes. The README walks through tracing the model with TorchScript and converting it to a Core ML mlprogram with coremltools. Apple reports up to 10x lower latency and 14x lower peak memory versus baseline on A14/M1 or newer; the tutorial case (seq length 128, batch 1) shows 2.84x.

Who it is for: Engineers deploying Transformer models to iPhone, iPad and Mac via Core ML

Strengths

  • Equivalent DistilBERT that loads baseline Hugging Face weights via load_state_dict
  • Tutorial covers the full path: trace, coremltools conversion, Xcode performance report
  • Backed by a published Apple research article with latency and memory data
  • Installs with pip install ane_transformers

Weaknesses

  • Only DistilBERT is shown as a Hugging Face example
  • Targets A14/M1 or newer; speed-up tests only warn on other devices
  • Last release was 2022-08-09; README benchmarks use iOS 16.0
  • License is not identified (NOASSERTION)

What it needs

  • Needs PyTorch, transformers, coremltools, Xcode
  • Models: DistilBERT, Core ML mlprogram, TorchScript

What changed

From the release notes. No flag means the note does not say so, not that the upgrade is safe. Releases and problems by RSS

Also in ML frameworks and libraries

See all 433
Also in ML frameworks and libraries
RankProjectScore
#330morph-netTensorFlow library that learns smaller CNN layer widths under FLOP or size limits1k starsApache-2.037 out of 100
#331implicitPython library for recommender systems on implicit feedback data3.8k starsMIT36 out of 100
#333ampligraphTensorFlow 2 library for knowledge graph embeddings and link prediction2.2k starsApache-2.036 out of 100
#334openmldbSQL feature platform giving consistent ML features for training and inference1.7k starsApache-2.036 out of 100
#335optimum-quantoPyTorch quantization library for Hugging Face LLMs and diffusers models1.1k starsApache-2.036 out of 100