Skip to main content

ML Inference 🥶

Project description

PyPI - Python Version Downloads GitHub

🧐 What is Nbox?

nbox provides first class API support for all NimbleBox.ai infrastructure (NBX-Build, Jobs, Deploy) and services (NBX-Workspaces) components. Write jobs using nbox.Operators

Installation

# on macos find the correct wheel file based on python version: https://github.com/pietrodn/grpcio-mac-arm-build/releases/tag/1.51.1
pip install <wheel_url>
pip install nbox

# on linux
pip install nbox

🤷Why NimbleBox

  • Write and execute code in Python
  • Document your code that supports mathematical equations
  • Create/Upload/Share notebooks
  • Import notebooks from your local machine
  • Import/Publish notebooks from/to GitHub
  • Import external datasets (e.g. from Kaggle)
  • Integrate PyTorch, TensorFlow, Keras, OpenCV
  • Share your projects
  • Collaborate with your team

🚀 Startup Program

image

If you're a new startup with(<$1M raised,<3 years since founded) then you're in luck to be the part of our startup program!

Get $420k worth of deals on your favorite tools

Check it out !

🎚 Features

🏗️ Freedom To Build

Build Landing Page (2)

🦾 Automate with Ease

Jobs Landing Page

🚀 Intuitive Dashboard

Deploy Landing Page

🏁 Get Started

Install the package from pypi:

When loading nbox for the first time, it will prompt you the username and password and create a secrets file at ~/.nbx/secrets.json. This file then contains all the information that you don’t have to fetch manually again.

APIs

Our APIs are deep, user functions are kept to minimum and most relavant. This documentation contains the full spec of everything, but here’s all the APIs you need to know:

nbox
├── Model          # Framework agnostic Model
│   ├── __call__
│   ├── deploy
│   ├── train_on_instance (WIP)
│   └── train_on_jobs (WIP)
├── Operators      # How jobs are combinations of operators
│   ├── __call__
│   └── deploy
├── Jobs           # For controlling all your jobs
│   ├── logs       # stream logs right on your terminal
│   └── trigger    # manually trigger a job
└── Instance
   ├── __call__    # Run any command on the instance
   └── mv (WIP)    # Move files to and from NBX-Build

Deploy and run any model

Let's take this script as an example

from nbox import operator, Operator
from nbox.lib.shell import ShellCommand

# define your function and wrap it as an operator
@operator()
def foo(x: Dict):
  return "bar"

# or use OO to deploy an API
@operator()
class Baz():
  def __init__(self, power: int = 2):
    # load any model that you want
    self.model = load_tf_pt_model()
    self.power = power
  
  def forward(self, x: float = 1.0):
    return {"pred": x ** self.power}    

Through your CLI:

# to deploy a job
nbx jobs upload file:foo 'my_first_job'

# to deploy an API
nbx serve upload file:Baz 'my_first_api'

🛟 How to get help?

Join our discord and someone from our community or engineering team will respond!

🔖Read our Blog.

🧩 License

The code in thist repo is licensed as Apache License 2.0. Please check for individual repositories for licenses.

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

nbox-0.12.0.tar.gz (206.3 kB view details)

Uploaded Source

Built Distribution

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

nbox-0.12.0-py3-none-any.whl (210.8 kB view details)

Uploaded Python 3

File details

Details for the file nbox-0.12.0.tar.gz.

File metadata

  • Download URL: nbox-0.12.0.tar.gz
  • Upload date:
  • Size: 206.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.2 CPython/3.10.8 Darwin/22.1.0

File hashes

Hashes for nbox-0.12.0.tar.gz
Algorithm Hash digest
SHA256 07613ed4b9c8477be43f0714b3b09d8b46f3a796399ec493faf1c1638f0e8d3b
MD5 11ef021ca0d8f1567516cc862cfaa4cd
BLAKE2b-256 96207f3e553d807d30432c2f7c315cfcfec56d1cc4501be06ca2f92ebc6c0451

See more details on using hashes here.

File details

Details for the file nbox-0.12.0-py3-none-any.whl.

File metadata

  • Download URL: nbox-0.12.0-py3-none-any.whl
  • Upload date:
  • Size: 210.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.2 CPython/3.10.8 Darwin/22.1.0

File hashes

Hashes for nbox-0.12.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9e87878066225329f2a94686a4543eb4e9c271496e0223f7abade5c1dd38f8e6
MD5 f2a622d85094bd43066e1195be8aeaa9
BLAKE2b-256 d8d54a90cf5b281bb01c25387e1e1c012ff7322b48f23c8db9b38c4c97774b7f

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