Skip to main content

A lightweight DataFrame validation library.

Project description

Pulire

A lightweight DataFrame validation library for Pandas.

Auto Formatting

poetry run black .

Schema

Pulire requires a Schema which describes all columns in a given DataFrame.

from pulire import Schema, Column, validators, formatters

Schema([
    Column("temp", "Float64", [
        validators.minimum(-80),
        validators.maximum(65),
        formatters.decimals(1)
    ])
])

Validate

Pulire automatically removes values which fail the validation. Let's use the meteostat library to get some data:

from datetime import datetime
from meteostat import Hourly

df = Hourly("10637", datetime(2018, 1, 1), datetime(2018, 1, 1, 23, 59)).fetch()

print(df)

Now, we can get a valid copy of our Meteostat DataFrame by running our schema's validate method:

df = myschema.validate(df)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pulire-0.0.4.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

pulire-0.0.4-py3-none-any.whl (11.3 kB view details)

Uploaded Python 3

File details

Details for the file pulire-0.0.4.tar.gz.

File metadata

  • Download URL: pulire-0.0.4.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for pulire-0.0.4.tar.gz
Algorithm Hash digest
SHA256 c27a1b3c7e5de46cf7648d182620efdb832c10d23f89b5fc60856606a4b11537
MD5 6430eb4fe1d8d68cd0640d8b8a32c42a
BLAKE2b-256 f2fbab0d9c3fc50568ca53ec783a6aeaaf9cbe099719225ac3ee0f5b7a1ecef8

See more details on using hashes here.

Provenance

The following attestation bundles were made for pulire-0.0.4.tar.gz:

Publisher: publish.yml on meteostat/pulire

Attestations:

File details

Details for the file pulire-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: pulire-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 11.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for pulire-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 804f8c8c2ad56a7fbe9b29cd4ae6c83b32cd4e60f03e89afa7fd375001db1562
MD5 a5691af3017281700eb5052d5d499545
BLAKE2b-256 cf02d569557c87b2887b7fbce0c23a7b9e7c6660efe08a9263fa8a287082d780

See more details on using hashes here.

Provenance

The following attestation bundles were made for pulire-0.0.4-py3-none-any.whl:

Publisher: publish.yml on meteostat/pulire

Attestations:

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page