Skip to main content

The gravity-ai.com helper package

Project description

Gravity-ai.com

This package includes helper scripts for interfacing your machine learning code with the Gravity-ai.com containerization code.

To install from pypi:

pip install gravityai

To install from source:

python3 setup.py install

Example Implementation Code

from gravityai import gravityai as grav

# the following function is a callback (defined by you), that may be
# async or synchronous and that may be called multiple times, to
# transform input data against an algorithm or model (or whatever you want)
# If an error is experienced, return an error string message, or throw an exception.
def process_data(dataPath, outPath):
    # TODO:
    # Read data in from dataPath
    # Transform Data via model
    # Write data out to outPath
    # Return None if everything went ok.
    # return an error string if there was a problem.


# TODO Initialize models, etc. before calling wait_for_requests.

grav.wait_for_requests(process_data)

Building a new Version

To build a new version for pypi (only we do that):

python3 -m pip install --user --upgrade setuptools wheel

python3 -m pip install --user --upgrade twine

python3 setup.py sdist bdist_wheel

python3 -m twine upload --repository pypi dist/*

Use the saved credentials, and remember the username is __token__

Project details


Download files

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

Source Distribution

gravityai-0.1.2.tar.gz (5.9 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

gravityai-0.1.2-py3.6.egg (10.9 kB view details)

Uploaded Egg

gravityai-0.1.2-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file gravityai-0.1.2.tar.gz.

File metadata

  • Download URL: gravityai-0.1.2.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.6.13

File hashes

Hashes for gravityai-0.1.2.tar.gz
Algorithm Hash digest
SHA256 a134b25bbd8461983f58821f22516937247513c820b28d08b00d2a749a924d4b
MD5 4a0e1cd631dfb4af538621b353e9c59d
BLAKE2b-256 30010586413d543b9f83e364967c800926096f62d3ccf3a0f605acfec5ea8257

See more details on using hashes here.

File details

Details for the file gravityai-0.1.2-py3.6.egg.

File metadata

  • Download URL: gravityai-0.1.2-py3.6.egg
  • Upload date:
  • Size: 10.9 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.6.13

File hashes

Hashes for gravityai-0.1.2-py3.6.egg
Algorithm Hash digest
SHA256 633c48291130258a89490fd6f585319da834efad8aa706b53061c34921a2def2
MD5 e63fd50fa91cae5409196744a09431cb
BLAKE2b-256 e989f67f36ca1153b2453009314ce5384f092bc7ca6de986469c7c55855e41f2

See more details on using hashes here.

File details

Details for the file gravityai-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: gravityai-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 6.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.6.13

File hashes

Hashes for gravityai-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 817f0ab2887bedfb89e4683c902a11ffb73e6e8dbf2df34c3065e59fbf546b51
MD5 ff2dd931258a5bd9696d6fbf1fc5199c
BLAKE2b-256 889f7b57690e1264d68908f77562b81c19fc7da7bac76d0d758517291c984a65

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page