Skip to main content

hkube api for Jupyter Notebook

Project description

hkube_notebook

This python3 library for Jupyter Notebook enables to integrate with hkube system:

  • Algorithms: add (including image built), list and delete algorithms.
  • Pipelines: Create and store pipelines, get stored pipelines, etc.
  • Execution: execute pipeline, track execution status by a progress bar, get the results, etc. Algorithm could be built and added to Hkube in 3 methods:
  • Function/s: pass your algorithm function/s (only 'start' function is must) - requirements.txt is created automatically.
  • Algorithm folder: pass your algorithm code folder - requirements.txt is expected.
  • Github: pass algorithm project github url - requirements.txt is expected.

Intructions for Developer

  • Download the hkube project hkube_notebook
  • Make sure you have python3 and Jupyter Notebook installed (Anaconda is recommended)
  • Make sure python3 is in your path
  • Update pip3 and install dependecies:
$ python3 -m pip install --upgrade pip
$ python3 -m pip install pipreqs
$ python3 -m pip install flask=0.12.2
$ python3 -m pip install tqdm=4.28.1
  • Better work with a virtual env (in that case install required packages also in your virtual env)
  • Install the library using the following shell commands (notice that library version is taken from setup.py):
$ cd hkube_notebook
$ python3 setup.py develop
$ # make sure hkube_notebook is installed
$ python3 -m pip list | grep hkube
  • Run Jupyter Notebook server, open a new python session, import the library and start work
import hkube_notebook
  • Example and test notebook for pipeline build, store, execute and track: hkube_notebook.ipynb
  • DS pipeline example notebook, including algorithms build and end-to-end DS pipeline: preprocess + split data + train batch + find best model, train and dump it: DS Example Pipeline.ipynb
  • Tested: Python 3.6.8 from Anaconda

Upload package to python registry

See: https://packaging.python.org/tutorials/packaging-projects/

  • Install/update tools:
$ python3 -m pip install --user --upgrade setuptools wheel
$ python3 -m pip install --user --upgrade twine
$ # create a 'dist' diectory with whl and gz files:
$ python3 setup.py sdist bdist_wheel
$ # upload to python registry:
$ python3 -m twine upload --repository-url <url> dist/*
$ # for python test registry use: <url>=https://test.pypi.org/legacy/
$ # Create account for python test registry at: https://test.pypi.org/account/register/

Install package in user python3 env

  • In user python environment:
$ python3 -m pip install --index-url <url> hkube_notebook
$ # for python test registry use: <url>=https://test.pypi.org/simple/
$ # now install missing dependency packages...

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

hkube_notebook-1.0.0.dev3-py3-none-any.whl (22.9 kB view details)

Uploaded Python 3

File details

Details for the file hkube_notebook-1.0.0.dev3-py3-none-any.whl.

File metadata

  • Download URL: hkube_notebook-1.0.0.dev3-py3-none-any.whl
  • Upload date:
  • Size: 22.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.7.9

File hashes

Hashes for hkube_notebook-1.0.0.dev3-py3-none-any.whl
Algorithm Hash digest
SHA256 eb1df4516e3fb634a8515fa3da8c4e710da21f8b13e46f63dfb9a40df64e7ab8
MD5 857ba3711eac80bbfd148e387d92a575
BLAKE2b-256 9e958937bba113aa4d6938b8856c3322ca056943a4ff13bc6741fb0db8dca97b

See more details on using hashes here.

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