skillfed

fasttransform

Transform is the main building block of data pipelines in fastai. And elsewhere if you want.

fasttransform v0.0.2 216.0K downloads/30d#9,388 on PyPI35
Permissive license Apache Software License 2.0 Active released

What it is and what it does

fasttransform is a data transformation framework that wraps functions into Transform objects, enabling them to be composed into reusable pipelines. The core idea is that a single Transform can encode data forward and decode it backward, specialize behavior based on input types, and preserve or convert types intelligently. It depends on fastcore for core utilities and plum-dispatch for type-based function selection.

The package is designed for data pipeline construction where you need transformations that are reversible (useful for normalization/denormalization), type-aware (handling multiple input formats), and composable into larger workflows. It supports decorator syntax for simple cases and class-based definition for stateful transforms that need setup phases, like computing statistics from a dataset before normalizing.

Use it for:

  • Build reversible normalization transforms that can both encode data (e.g., z-score) and decode predictions back to original scale.
  • Handle heterogeneous input types in a pipeline by defining type-specialized encode functions that dispatch automatically.
  • Compose multiple transforms into a Pipeline for end-to-end data processing with single encode/decode calls.
  • Create stateful transforms that compute aggregate properties (mean, std) during setup and apply them consistently across data.
  • Preserve runtime subtypes through transformations so that custom numeric types remain their original type after operations.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

fasttransform provides a Transform class for building reusable, composable data transformations with support for reversibility, type-based dispatch, and type preservation.

Yes, if you are building data pipelines that need reversible, type-aware transformations. The low install friction, active maintenance, permissive license, and clean API make it a reasonable choice. However, verify that it fits your specific dispatch and composition needs—it is still in Beta (version 0.0.2) and may not yet be production-hardened for all use cases.

Install

fasttransform on PyPI

pip

pip install fasttransform

uv

uv add fasttransform

poetry

poetry add fasttransform

Installing fasttransform

Before you install

Low install friction with only two runtime dependencies (fastcore and plum-dispatch). The package is actively maintained with a recent commit on 2026-07-26 and has been in active development since its first release.

License in practice

Licensed under Apache Software License 2.0, a permissive license that allows commercial use, modification, and distribution with minimal restrictions.

Quickstart

from fasttransform import Transform, Pipeline

@Transform
def add_one(x):
    return x + 1

result = add_one(2)  # returns 3

# Reversible transform
def enc(x): return x*2
def dec(x): return x//2
t = Transform(enc, dec)
encoded = t(2)  # returns 4
decoded = t.decode(encoded)  # returns 2

Verify before relying

  • Whether type-based dispatch via plum-dispatch handles edge cases or has known limitations with complex type hierarchies.
  • Performance characteristics when chaining many transforms in a pipeline with large datasets.
  • Whether the package is actively used in production fastai workflows or remains primarily experimental.

Package facts

License Apache Software License 2.0 (permissive)
Python support supports the current Python release (>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 2 — fastcore, plum-dispatch
Maintenance actively maintained — 483 days since the last release
Last repo commit
First released
Downloads 215,996/month — #9,388 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: fasttransform-0.0.2-py3-none-any.whl

Keywords: nbdev, jupyter, notebook, python

Development Status :: 4 - BetaIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseNatural Language :: EnglishProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.9

Tags

data transformation pipelinereversible data transformstype-based function dispatchdata encoding decodingreusable data pipelinetype conversion preservationfunction composition framework
data-pipelinetype-dispatchreversible-transform

More Application Frameworks packages