Polynomial, trigonometric, and tropical activations

Ismail Khalfaoui-Hassani, Stefan Kesselheim
2/3/2025
cs.LGcs.AIcs.CL

Official code: K-H-Ismail/torchortho (16 stars, GPL-3.0, PyTorch, last commit 2026-02-23).

Abstract

Which functions can be used as activations in deep neural networks? This article explores families of functions based on orthonormal bases, including the Hermite polynomial basis and the Fourier trigonometric basis, as well as a basis resulting from the tropicalization of a polynomial basis. Our study shows that, through simple variance-preserving initialization and without additional clamping mechanisms, these activations can successfully be used to train deep models, such as GPT-2 for next-token prediction on OpenWebText and ConvNeXt for image classification on ImageNet. Our work addresses the issue of exploding and vanishing activations and gradients, particularly prevalent with polynomial activations, and opens the door for improving the efficiency of large-scale learning tasks. Furthermore, our approach provides insight into the structure of neural networks, revealing that networks with polynomial activations can be interpreted as multivariate polynomial mappings. Finally, using Hermite interpolation, we show that our activations can closely approximate classical ones in pre-trained models by matching both the function and its derivative, making them especially useful for fine-tuning tasks. These activations are available in the torchortho library, which can be accessed via: https://github.com/K-H-Ismail/torchortho.

View on arXivView PDF

Code Implementations(1)

PyTorchGPL-3.0

[ICLR 2026] Polynomial, trigonometric, and tropical activations

160Python, Jupyter NotebookSep 27, 20248 months agoGPL-3.0
activationsaiartificial-intelligencebasisconvolutional-neural-networks+15 more

Similar Papers

Cite this paper

@article{khalfaouihassani2025polynomial,
  title  = {Polynomial, trigonometric, and tropical activations},
  author = {Ismail Khalfaoui-Hassani and Stefan Kesselheim},
  year   = {2025},
  eprint = {2502.01247},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.01247v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2502.01247.svg)](https://codeofpaper.com/paper/2502.01247)

Discussion