dcyd model performance monitoring client
Project description
MPM Model Performance Monitoring client
Installation
$ pip3 install dcyd $ dcyd-config AN_ALPHANUMERIC_USERNAME $ export DCYD_CONFIG_FILE=/some/path/dcyd-key.json
Usage
Barebones decorator of your predict
function:
from dcyd.mpm import mpm @mpm def my_predict_function(some args, some kwargs): ... return some response
Decorate your predict
function, but include some metadata (e.g. customer_id
, experiment_group
, model_version
) for helpful tracking:
from dcyd.mpm import mpm @mpm(optional kwargs for tracking/filtering) def my_other_predict_function(some args, some kwargs): ... return some response
Decorate a method as well:
from dcyd.mpm import mpm class MyModel(object): @mpm(optional kwargs for tracking/filtering) def my_predict_method(self, *args, **kwargs): ... return some response
Development
- Clone the repo locally, and switch to a branch other than
master
. - Create and activate a virtual environment:
$ python3 -m venv my_env_name
- From the directory containing
setup.py
:
$ pip3 install .
or
$ pip3 install -e .
(These are in place of python3 setup.py install
and python3 setup.py develop
, for reasons explained here.
Distributing the package in PyPI
This process comes from this turorial.
- Increment the version in
setup.py
, using these rules (or newer). - Install/update some modules:
$ pip3 install --user --upgrade setuptools wheel twine
- From the directory containing
setup.py
(and not in a virtual environment), create the wheel:
$ python3 setup.py sdist bdist_wheel
- Upload the wheel to PyPI:
$ python3 -m twine upload dist/*
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
dcyd-0.0.5.tar.gz
(5.3 kB
view hashes)
Built Distribution
dcyd-0.0.5-py3-none-any.whl
(7.0 kB
view hashes)