CNet: A Complex-Valued Deep Learning Framework with Wirtinger Autodifferentiation and FFT--Hadamard Convolution
Abstract
CNet is a C++/CUDA framework for deep complex-valued neural networks (CVNNs), trained by gradient descent with explicit Wirtinger (CR-calculus) derivatives. Complex models are underexplored yet natural where data is intrinsically complex -- RF/IQ, MRI k-space, radar/SAR, audio spectra -- and phase carries information real networks discard. CNet is physics-native: a network is a cascade of complex (often unitary) operations on an amplitude vector, and classification is a Born-rule measurement p_k = |z_k|^2 / ||z||^2 rather than a softmax over real logits. Every layer ships a CPU reference and a finite-difference-verified CUDA kernel; the static, batch-cloned computation graph captures cleanly into CUDA Graphs, outperforming eager and compiled torch.complex64 on an H100. We present three studies. (1) A fully complex causal language model, built on a new causal (triangular-masked) Fourier mixer with an O(N log N) Bluestein evaluation of the forward pass and its Wirtinger adjoint, matches a parameter-matched real causal FNet on character-level tiny-shakespeare in under half the steps. We introduce Born-rule attention, a content-based causal mixer whose weights are the quantum-measurement probabilities ||^2 -- to our knowledge the first classical, complex-valued attention to replace softmax with the squared-magnitude Born score; with rotary embeddings and per-token complex normalization it reaches 1.52 nats/char, matching softmax self-attention, and transfers unchanged to byte-level (1.31 nats/char) and sub-word WikiText-103. (2) On radio-modulation classification (RML2016.10a/RML22) we trace the pooled-power accuracy ceiling to discarded temporal structure and recover it with a learnable cyclostationary conjugate-lag operator. (3) A bottleneck analysis of the Fourier phase problem in coherent-diffraction imaging isolates where complex-valued networks still need new operators.
Related
- Reverse Translation and Convolution Estimates in the Framework of the Mehler-Fock Transform
- A computational framework for multidimensional loop-cocyclic Hadamard matrices
- A fractional modular Poincaré--Wirtinger-type inequality in Sobolev spaces with variable exponents
- The convolution product is generally not an open map
- Higher-order convex orders under free multiplicative convolution
BibTeX
@misc{crasmaru2026cnet,
title = {{CNet: A Complex-Valued Deep Learning Framework with Wirtinger Autodifferentiation and FFT--Hadamard Convolution}},
author = {Marcel Crasmaru},
howpublished = {arXiv},
year = {2026},
month = oct,
doi = {10.48550/arxiv.2610.08592},
eprint = {2610.08592},
archivePrefix = {arXiv},
url = {https://arxiv.org/abs/2610.08592},
}
RIS
TY - UNPB
TI - CNet: A Complex-Valued Deep Learning Framework with Wirtinger Autodifferentiation and FFT--Hadamard Convolution
AU - Marcel Crasmaru
PY - 2026
DA - 2026/10/15
PB - arXiv
DO - 10.48550/arxiv.2610.08592
UR - https://arxiv.org/abs/2610.08592
AB - CNet is a C++/CUDA framework for deep complex-valued neural networks (CVNNs), trained by gradient descent with explicit Wirtinger (CR-calculus) derivatives. Complex models are underexplored yet natural where data is intrinsically complex -- RF/IQ, MRI k-space, radar/SAR, audio spectra -- and phase carries information real networks discard. CNet is physics-native: a network is a cascade of complex (often unitary) operations on an amplitude vector, and classification is a Born-rule measurement p_k = |z_k|^2 / ||z||^2 rather than a softmax over real logits. Every layer ships a CPU reference and a finite-difference-verified CUDA kernel; the static, batch-cloned computation graph captures cleanly into CUDA Graphs, outperforming eager and compiled torch.complex64 on an H100. We present three studies. (1) A fully complex causal language model, built on a new causal (triangular-masked) Fourier mixer with an O(N log N) Bluestein evaluation of the forward pass and its Wirtinger adjoint, matches a parameter-matched real causal FNet on character-level tiny-shakespeare in under half the steps. We introduce Born-rule attention, a content-based causal mixer whose weights are the quantum-measurement probabilities ||^2 -- to our knowledge the first classical, complex-valued attention to replace softmax with the squared-magnitude Born score; with rotary embeddings and per-token complex normalization it reaches 1.52 nats/char, matching softmax self-attention, and transfers unchanged to byte-level (1.31 nats/char) and sub-word WikiText-103. (2) On radio-modulation classification (RML2016.10a/RML22) we trace the pooled-power accuracy ceiling to discarded temporal structure and recover it with a learnable cyclostationary conjugate-lag operator. (3) A bottleneck analysis of the Fourier phase problem in coherent-diffraction imaging isolates where complex-valued networks still need new operators.
ER -