Skip to main content

Package for maintaining robust, reproducible data management.

Project description

rushd

Stable documentation PyPI-downloads PyPI-version PyPI-license Supported python versions codecov

A package for maintaining robust, reproducible data management.

Rationale

Science relies on repeatable results. rushd is a Python package that helps with this, both by making sure that the execution context (e.g. the state of all of the Pip packages) is saved, alongside helper functions that help you cleanly, but repeatedly, separate data from code.

Install

This package is on Pip, so you can just:

pip install rushd

Alternatively, you can get built wheels from the Releases tab on Github.

Quickstart

Simply import rushd!

import rushd as rd

Documentation

See the documentation available at https://gallowaylabmit.github.io/rushd

Developer install and contributing

If you'd like to hack locally on rushd, after cloning this repository:

$ git clone https://github.com/GallowayLabMIT/rushd.git
$ cd rushd

you can create a local virtual environment, and install rushd in "development (editable) mode" with the extra requirements for tests.

$ python -m venv env
$ .\env\Scripts\activate    (on Windows)
$ source env/bin/activate   (on Mac/Linux)
$ pip install -e .[dev]     (on most shells)
$ pip install -e '.[dev]'   (on zsh)

After this 'local install', you can use and import rushd freely without having to re-install after each update.

Pre-commit

We use something called pre-commit to automatically run linters, formatters, and other checks to make sure the code stays high quality.

After doing the developer install and activating the virtual environment, you should run:

$ pre-commit install

to install the git hooks. Now, pre-commit will automatically run whenever you go to commit.

Testing with pytest

We use pytest to test our code. You just type:

$ pytest

to run all tests, though you can add an optional argument to run some subset of the tests:

$ pytest tests/test_file_io.py

Pytest automatically discovers tests put in the tests directory, whose files and functions start with the word test.

Code coverage

On every push, all of the tests are run and the coverage, or which lines are "covered" or executed during all tests, is calculated and uploaded to Codecov. This is a nice way of seeing if you missed any edge cases that need tests added.

Publishing a release

Following the steps described above, the full process for publishing a release is:

  1. Test

    • Write new tests as needed
    • Run tests to confirm changes pass
  2. Pre-commit

    • Stage changes in git
    • Run pre-commit (requires developer mode)
    • Resolve any errors/warnings from pre-commit (e.g., run ruff --fix)
    • Stage any new fixes and re-run pre-commit
  3. Commit changes

    • Commit and sync changes
    • Confirm project builds on github with no errors (see 'Actions' tab)
    • Confirm adequate coverage via codecov (click link on github)
  4. Document changes

    • Edit CHANGELOG.md and README.md to reflect changes, then commit
    • Tag the release using git tag -a vX.X.X (updating Xs) with a short changelog summary as the tag message
    • Push changes git push --tags
  5. Build the release

    • Build using python -m build
    • Add a release to the github page by copy-pasting the changelog
    • Add the .whl and .tar.gz files (from the build folder) to the github release
    • Upload the package to PyPI using twine upload dist/*

Changelog

See the CHANGELOG for detailed changes.

## [0.6.0] - 2026-01-27
### Added
- Module `rd.qpcr` for loading qPCR data, i.e., .csv (and similar) files containing a column with well IDs
  - `rd.qpcr.load_single_csv_with_metadata` for loading single files
  - `rd.qpcr.load_plates_with_metadata` for loading multiple files, analogous to `rd.flow.load_groups_with_metadata`
- Module `rd.ddpcr` for loading ddPCR data with metadata by extracting info from .ddpcr files
- `rd.flow.load_csv` for loading multiple .csv files without additional .yaml metadata, using only metadata in filename
### Modified
- All functions that load .csv files now accept optional kwargs that are passed to pandas `read_csv`

License

This is licensed by the MIT license. Use freely!

What does the name mean?

The name is a reference to Ibn Rushd, a Muslim scholar born in Córdoba who was responsible for translating and adding scholastic commentary to ancient Greek works, especially Aristotle. His translations spurred further translations into Latin and Hebrew, reigniting interest in ancient Greek works for the first time since the fall of the Roman empire.

His name is pronounced rush-id.

If we take the first and last letter, we also get rd: repeatable data!

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

rushd-0.6.0.tar.gz (37.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rushd-0.6.0-py3-none-any.whl (26.0 kB view details)

Uploaded Python 3

File details

Details for the file rushd-0.6.0.tar.gz.

File metadata

  • Download URL: rushd-0.6.0.tar.gz
  • Upload date:
  • Size: 37.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.0

File hashes

Hashes for rushd-0.6.0.tar.gz
Algorithm Hash digest
SHA256 4c9986c8ffa0a2d8ca0d870dd6fb8abfa4f73ae03da408181f7bbe74d0467241
MD5 3723bee533f6d9c59056cf1013130de0
BLAKE2b-256 0ffc1f978c01a03360558a501edb0d3148ddbd1440bbaac02b5b2428824b3419

See more details on using hashes here.

File details

Details for the file rushd-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: rushd-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 26.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.0

File hashes

Hashes for rushd-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f8ec85a1293db41929d96d59c8efbed63737572a39f2f473416b6b710002e11e
MD5 c196e598fac9eb8910a2b08300a1bcca
BLAKE2b-256 e73eaf24551f30d7f23562fe79f63cd7ab44ef851d3758dba6a33dff3f8aacd3

See more details on using hashes here.

Supported by

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