Document dataset metadata. For use in Statistics Norway's metadata system.
Project description
Datadoc
Document datasets in Statistics Norway
Usage
From Jupyter
- Open https://jupyter.dapla-staging.ssb.no or another Jupyter Lab environment
- Run
pip install ssb-datadoc[gcs]
in the terminal - Upload a dataset to your Jupyter server (e.g. https://github.com/statisticsnorway/datadoc/blob/master/klargjorte_data/person_data_v1.parquet)
- Run
from datadoc import main; main("./person_data_v1.parquet")
in a notebook - Datadoc will open in a new tab
Contributing
Prerequisites
- Python >3.8 (3.10 is preferred)
- Poetry, install via
curl -sSL https://install.python-poetry.org | python3 -
Dependency Management
Poetry is used for dependency management. Poe the Poet is used for running poe tasks within poetry's virtualenv. Upon cloning this project first install necessary dependencies, then run the tests to verify everything is working.
Install all dependencies
poetry install --all-extras
Add dependencies
Main
poetry add <python package name>
Dev
poetry add --group dev <python package name>
Run tests
poetry run poe test
Run project locally
To run the project locally:
poetry run poe datadoc "gs://ssb-staging-dapla-felles-data-delt/datadoc/klargjorte_data/person_data_v1.parquet"
Run project locally in Jupyter
To run the project locally in Jupyter run:
poetry run poe jupyter
A Jupyter instance should open in your browser. Open and run the cells in the .ipynb
file to demo datadoc.
Bump version
poetry run poe bump-patch-version
:warning: Run this on the default branch
This command will:
- Increment version strings in files
- Commit the changes
- Tag the commit with the new version
Then just run git push origin --tags
to push the changes and trigger the release process.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for ssb_datadoc-0.1.8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68a5894fe9889ec0d69195f5c0b4169664d621c7a87bc5ee828d64dc43437d6e |
|
MD5 | f185ee7dda9bea0364ffc114c62ed6b7 |
|
BLAKE2b-256 | ce7844a54955696c81835c2ee3532cba1316fd3320df8b3efae71f6299f98a58 |