From no CPython C API experience to shipping a new DType in NumPy 2.0
summary
Implements a UTF-8 variable-width StringDType in NumPy 2.0 by writing C using the NumPy DType C API, funded via a NASA ROSES grant collaboration, and lands as a shipped feature that supports missing values and new string ufuncs. It uses a struct-of-pointers layout with short string optimization and an arena allocator to keep data contiguous, improves performance over old fixed-width/object approaches, and currently serializes via pickle while NPY format support remains pending.
AI-written summary · about
chapters (11)
- 0:00Introduction to numpy strings
- 1:13History of numpy strings
- 4:46Ecosystem and community impact
- 7:24Funding and project origins
- 9:09Background and onboarding
- 10:49Engineering the string dtype
- 14:05Development process and Dtypes
- 15:47Overcoming project challenges
- 18:00Becoming a maintainer
- 19:48Features of the new dtype
- 22:38Q&A and concluding remarks
