Review reference implementations of modular arithmetic kernels for homomorphic encryption.
Run modular addition, multiplication, and number-theoretic transform operators on Ascend hardware.
Verify a CANN 8.5.0 environment setup using the included Jupyter notebook.
| bjtupupil/ascendfhe | keralots/bambuhelper | actuallyaridan/linux-devmgmt | |
|---|---|---|---|
| Stars | 233 | 243 | 267 |
| Language | C++ | C++ | C++ |
| Setup difficulty | hard | moderate | moderate |
| Complexity | 5/5 | 4/5 | 3/5 |
| Audience | researcher | general | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires Huawei's CANN 8.5.0 toolkit and Ascend 910B hardware, no top-level build file is included.
AscendFHE is a library of low-level math operations designed to speed up homomorphic encryption on Huawei's Ascend NPU hardware, specifically the Atlas A2 and Ascend 910B chips. Homomorphic encryption is a type of cryptography that lets you perform computations on encrypted data without ever decrypting it, which is useful for privacy-preserving AI inference and secure cloud computing. The library provides the building-block math operations that homomorphic encryption algorithms need, implemented as hardware kernels that run directly on the Ascend accelerator. The eight operators in the library cover the core math that homomorphic encryption schemes use. These include modular addition and subtraction (arithmetic that wraps around at a fixed number), two types of modular multiplication using different algorithmic tricks (Shoup and Montgomery methods), a number-theoretic transform (a fast algorithm for polynomial multiplication used in many encryption schemes), basis conversion for a representation called RNS (Residue Number System, which splits large numbers across smaller ones for efficiency), a dot-product accumulation step, and an automorphism operation that reorders and normalizes coefficients. Each operator has its own subdirectory with the device-side kernel code and the host-side logic that prepares the data layout. Once the operator package is installed and registered, the operators are accessible from Python through PyTorch using calls like torch.ops.ascend_npu_fhe.add_mod(). The README notes that the current repository does not include a top-level CMakeLists.txt for building the full extension from scratch, so the operators cannot be called without a separately installed package. The repository is primarily useful for reviewing the source code, preparing a CANN 8.5.0 environment, and running the included Jupyter notebook to verify the environment setup. The README is written in Chinese and targets researchers and engineers working on homomorphic encryption acceleration. The project requires Huawei's CANN toolkit version 8.5.0 and the matching 910B operator package. Python integration is done through PyTorch combined with torch_npu, Huawei's PyTorch extension for Ascend hardware.
A C++ library of hardware-accelerated math operations for homomorphic encryption on Huawei's Ascend NPU chips.
Mainly C++. The stack also includes C++, PyTorch, CANN.
The README does not state a license.
Setup difficulty is rated hard, with roughly 1day+ to a first successful run.
Mainly researcher.
This repo across BitVibe Labs
Verify against the repo before relying on details.