unionai-oss/pandera

A light-weight, flexible, and expressive statistical data testing library

What it solves

Pandera solves the problem of unreliable data in processing pipelines. It provides a way to enforce "statistical typing" on dataframes, ensuring that the data flowing through your code matches the expected structure, types, and constraints before it causes errors downstream.

How it works

You define a schema—either as an object or a class—that describes the expected properties of your dataframe columns, such as data types and value ranges. You then pass your dataframe through this schema to validate it. If the data meets your criteria, the pipeline continues; if not, it alerts you to the discrepancy.

Who it’s for

It is designed for data scientists, engineers, and analysts who need to build robust, readable, and predictable data processing pipelines using popular libraries like pandas, polars, or pyspark.

Highlights

  • Flexible API that supports both object-based and class-based schema definitions.
  • Multi-library support, including pandas, polars, and pyspark.
  • Enables statistically typed dataframes to catch errors early.
  • Improves code readability by explicitly documenting data requirements.

Related

  • Project
  • Project
  • Project
  • Project