Skip to content
/ ounce Public

A simple Python package to manipulate units of measure

License

Notifications You must be signed in to change notification settings

lace/ounce

Repository files navigation

ounce

version python version license build docs build code style

Fast, simple, non-fancy, and non-magical package for manipulating units of measure.

It's a faster and less fancy counterpart to Pint.

Installation

pip install ounce

Usage

import ounce

value, units = ounce.convert(value, "in", "cm")

Versioning

This library adheres to Semantic Versioning.

Development

First, install Poetry.

After cloning the repo, run ./bootstrap.zsh to initialize a virtual environment with the project's dependencies.

Subsequently, run ./dev.py install to update the dependencies.

Acknowledgements

This was extracted from blmath by Paul Melnikow. blmath itself was extracted from the Body Labs codebase and open-sourced by Alex Weiss.

License

The project is licensed under the two-clause BSD license.