Emily CLI Documentation

Release-v3.0.6

Emily combines the powers of Python and Docker to build stable and consistent machine learning and datascience python environments. Emily is useful for large cross-team project development as well as for simply running a single jupyter notebook or python script.

Download emily@v3.0.6
See earlier versions
$ emily build [options]

Start a new project Valid Emily images: base | slim | cv | nlp torch-slim | torch-cv | torch-nlp | tf-slim tf-cv | tf-nlp | cuda-base | cuda-slim cuda-cv | cuda-nlp |cuda-torch-slim| cuda-torch-cv cuda-torch-nlp| cuda-tf-slim | cuda-tf-cv | cuda-tf-nlp

$ emily build
Emily: Project name::
· getting-started
Emily: An Emily template is a pre-built template containing
essential boilerplate code useful in the development of
microservices.
These templates include relevant endpoints depending on
which template you choose.

? Emily: Which Emily template do you want to use?(Use arrow keys, confirm with ENTER)> Default - Minimal project with hello world script
API - Simple project with API set up and ready
Machine learning [API, DVC, MLFlow, Pytorch] - Machine learning template with API, Data version control (DVC), MLFlow experiment reporting and pytorch
Machine learning API [API, Pytorch] - Machine learning template with API and pytorch
Machine learning [gRPC] - Machine learning template with gRPC
Machine Learning Reporting - Machine learning reporting template
· Default
Emily: An Emily image is a pre-built docker image containing
essential packages that are useful in the development of
microservices.
These images include relevant packages depending on which
type of project you are developing.

? Emily: Which Emily image fits your use case the best?(Use arrow keys, confirm with ENTER)> Base (contains just enough to run an API)
Slim (contains essential Machine Learning packages)
Computer Vision
Natural Language Processing
· Base
? Emily: Which editor do you want to use?(Use arrow keys, confirm with ENTER)
Visual Studio Code
> PyCharm
Jupyter Notebook
Jupyter Lab
· PyCharm
Emily: Creating a new Emily project in my-directory/my-project-name...

Running Emily Build

To build a new Emily project, run emily build in your terminal. You will be asked to provide a project name, choose a project template (e.g. Default, API, ML-API, etc.), an Emily image and an editor (e.g. VSCode, PyCharm, Jupyter Notebook or Jupyter Lab).

$ emily build
$ emily build
-n my-project-name
-i base
-t ml-api
-e lab


If you want to build a project without automatically starting a docker container use the flag --no-autostart

Emily images

Emily comes with a selection of pre-built images configured for different usecases:

  • Basic tasks that include an API (base)
  • Machine learning and data science (slim)
  • Computer vision and image processing (cv)
  • Natural language processing (nlp)

Included packages

The Emily images are pre-built with the following packages :

baseslimcvnlp
GCCbase +slim +slim +
MakeGTKpkg-config
CMake+ 8 packages1libicu-dev
G++
Python 3.8 with:Extra Python packages:Extra Python packages:Extra Python packages:
- protobuf- scikit-learn- OpenCV- spacy
- fastapi- pandas- Scikit-Image- tqdm
- requests- numpy- Tesseract- typer
- jupyter- matplotlib- Imageio- textblob
- tornado- scipy- PyWavelets- wasabi
- click- pillow- imutils- smart-open
- loguru- seaborn- networkx- thinc
- pydantic- cython- packaging- polyglot
- uvloop+ 4 packages2- [imageio]+ 14 packages3
- jinja2- tifffile
+ 77 packages4

The four images may be retrieved ´as-is´ or combined with a deep learning framework such as Tensorflow or PyTorch. Furthermore, the variants may be bundled with CUDA support.

The tables below give an overview of the 20 different variants of the images. Use the --image option followed by the image name shown in the tables below to specify the image you would like to use.

Images without CUDA

No deep learning frameworkTensorflowPyTorch
Basebase--
Slimslimtf-slimtorch-slim
Computer Visioncvtf-cvtorch-cv
Natural Language Processingnlptf-nlptorch-nlp

CUDA-enabled images

No deep learning frameworkTensorflowPyTorch
Basecuda-base--
Slimcuda-slimcuda-tf-slimcuda-torch-slim
Computer Visioncuda-cvcuda-tf-cvcuda-torch-cv
Natural Language Processingcuda-nlpcuda-tf-nlpcuda-torch-nlp

Footnotes

  1. Additional packages for the cv image: libsm6, libxext6, libglib2.0-0, libsm6, libxrender1, libfontconfig1, libxext6, libgl1

  2. Additional python packages for the slim image: joblib, kiwisolver, threadpoolctl, cycler

  3. Additional python packages for the nlp image: blis, catalogue, corenlp, cymem, langcodes, lemmy, morfessor, murmurhash, pathy, preshed, pycld2, pyicu, regex, srsly

  4. Additional python packages for the base image:psutil, gunicorn, prompt-toolkit, starlette, uvicorn, python-dotenv, pycodestyle, attrs, websockets, autopep8, pyzmq, urllib3, websocket-client, prometheus-client, pycparser, bleach, flake8, lxml, mistune, PyYAML, python-dateutil, pyrsistent, pyparsing, beautifulsoup4, grpcio, grpcio-tools, pyflakes, babel, pygments, anyio, watchfiles, toml, debugpy, six, decorator, certifi, traitlets, parso, mccabe, pytz, MarkupSafe, pandocfilters, packagingnest-asyncio, argon2-cffi, fastjsonschema, terminado, defusedxml, wcwidth, charset-normalizer, Send2Trash, cffi, executing, ptyprocess, soupsieve, asttokens, json5, tinycss2, typing-extensions, sniffio, entrypoints, pickleshare, webencodings, stack-data, pure-eval, backcall, argon2-cffi-bindings, pexpect, h11, httptools, idna, ipykernel, ipython-genutils, ipywidgets, jedi, jsonschema

    Options

  • -h,--help

    Display help for command

  • -a,--access-token<token>

    The access token to use for authentication

  • -eu,--emily-user<name>

    The email address for the Emily user related to the access token if provided (only required when --access-token is passed)

  • -n,--project-name<project-name>

    The project name.

  • -o,--out-dir<path>

    The directory in which to create the project.

  • -t,--template<template>

    The Emily template to use.

  • -i,--image<image>

    The Emily image to use.

  • -ho,--host<host>

    The host address to listen for requests on.

  • -p,--port<port>

    The port to listen for requests on.

  • -nh,--notebook-host<host>

    The Jupyter notebook server host.

  • -np,--notebook-port<port>

    The Jupyter notebook port.

  • -a,--autostart(--no-autostart)

    Automatically start Docker container and open in editor. (default: true)

  • -e,--editor<editor>

    The editor to use [vscode | pycharm | notebook | lab].

  • -g,--gpu(--no-gpu)

    Enable GPU capabilities within the container.

  • -d,--detach

    Detached mode: Run container in the background. Requires manual shutdown.

  • -s,--silent

    Execute Emily silently. (default: false)

  • -u,--update(--no-update)

    Prompt for update if newer version found. (default: true)

  • -vb,--verbose

    Print detailed information while running commands.