The command line interface for Gradient - Gradient is an an end-to-end MLOps platform

Overview

GitHubSplash

Gradient CLI

PyPI Downloads


Get started: Create AccountInstall CLITutorialsDocs

Resources: WebsiteBlogSupportContact Sales


Gradient is an an end-to-end MLOps platform that enables individuals and organizations to quickly develop, train, and deploy Deep Learning models. The Gradient software stack runs on any infrastructure e.g. AWS, GCP, on-premise and low-cost Paperspace GPUs. Leverage automatic versioning, distributed training, built-in graphs & metrics, hyperparameter search, GradientCI, 1-click Jupyter Notebooks, our Python SDK, and more.

Key components:

  • Notebooks: 1-click Jupyter Notebooks.
  • Workflows: Train models at scale with composable actions.
  • Inference: Deploy models as API endpoints.

Gradient supports any ML/DL framework (TensorFlow, PyTorch, XGBoost, etc).


See releasenotes.md for details on the current release, as well as release history.


Getting Started

  1. Make sure you have a Paperspace account set up. Go to http://paperspace.com to register and generate an API key.

  2. Use pip, pipenv, or conda to install the gradient package, e.g.:

    pip install -U gradient

    To install/update prerelease (Alpha/Beta) version version of gradient, use:

    pip install -U --pre gradient

  3. Set your api key by executing the following:

    gradient apiKey

    Note: your api key is cached in ~/.paperspace/config.json

    You can remove your cached api key by executing:

    gradient logout

Executing tasks on Gradient

The Gradient CLI follows a standard [command] [--options] syntax

For example, to create a new Deployment use:

gradient workflows create [type] [--options]

For a full list of available commands run gradient workflows --help. You can also view more info about Workflows in the docs.

Contributing

Want to contribute? Contact us at [email protected]

Pre-Release Testing

Have a Paperspace QA tester install your change directly from the branch to test it. They can do it with pip install git+https://github.com/Paperspace/[email protected].

Comments
  • Some parameters in job_client.create() don't work

    Some parameters in job_client.create() don't work

    I'm following the sample docs at gradient.api_sdk.clients.job_client. I can't get working_directory or job_env to work.

    working_directory: auto set to /paperspace. When I pass in /app, it's ignored & /paperspace is still used (listed Console > Job > Environment; and on the Job model fetch from job_client.list()). I just cashed in and set all my Docker stuff from /app to /paperspace and it worked. Ideally I wouldn't even want to pass /app, but it'd just be picked up from WORKDIR in the Dockerfile (which is /app)

    job_env: I can't find a workaround (save putting a config.json in /storage). Parameter gets gets ignored; of note, the docs has a typo:

    job = job_client.create(
        ...
        job_env={
            'CUSTOM_ENV'='Some value that will be set as system environment',
        }
    )
    

    'CUSTOM_ENV'='..' should be 'CUSTOM_ENV': '..'. Not nit-picking; just that it had me second guessing my approach, since using a dict gets ignored ([j.job_env for j in job_client.list()] => [None, None, ..]) so I tried json.dumps(my_dict), still ignored. Any suggestions on getting the job_env passed in?

    Overall, it seems like some params are respected, and others not; and it's hard to know which is which. Maybe a mismatch on the docs vs Github vs PyPi?

    opened by lefnire 8
  • Unable to install due to numpy==1.19.4

    Unable to install due to numpy==1.19.4

    Hi I am unable to use gradient on python 3.7.9 due to RuntimeError caused by numpy==1.19.4

    RuntimeError: The current Numpy installation ('c:\users\XXXX\envs\gradient\lib\site-packages\numpy\init.py') fails to pass a sanity check due to a bug in the windows runtime. See this issue for more information: https://tinyurl.com/y3dm3h86

    I tried downgrading the numpy, but it appears to be incompatible and i got the ff ModuleNotFoundError: ModuleNotFoundError: No module named '_curses'

    opened by thompsonalecbgo 7
  • Update Readme.md

    Update Readme.md

    I found two outdated or currently not working commands while trying to execute my container:

    1. The --project option was ignored but providing --projectId worked.
    2. The example for the --command option had as error message: Error: Missing argument "SCRIPT...". Upon providing a script the originally provided command was ignored. Instead I had to use the --shell option to execute the correct call.
    opened by nziermann 6
  • Keep artifacts for canceled jobs

    Keep artifacts for canceled jobs

    I am aware this is probably not the place to open this issue, but it seems like artifacts are not kept when a job is canceled. But why? I just finished a 2 days running job and wanted to have access to my best model, but the artifacts are not showing up potentially because I canceled the job. If this is the case, this is very frustrating.

    opened by MichelML 5
  • feat(notebooks): enable basic notebook lifecycle commands PS-13680

    feat(notebooks): enable basic notebook lifecycle commands PS-13680

    Newly Supported Commands

    • notebooks stop
    • notebook start
    • notebook create
    • notebook fork
    • notebook artifacts list

    Related tickets

    https://paperspace.atlassian.net/browse/PS-12219 https://paperspace.atlassian.net/browse/PS-11559 https://paperspace.atlassian.net/browse/PS-13681 https://paperspace.atlassian.net/browse/PS-13682 https://paperspace.atlassian.net/browse/PS-13683 https://paperspace.atlassian.net/browse/PS-13684

    This PR follows up on the PR for PS-12219 (https://github.com/Paperspace/PS_API/pull/1526). It enables createNotebook, startNotebook, artifactsList and forkNotebook commands with the v2 endpoint. It adds in the ability for creating a notebook with vm_type_id or vm_type_label

    opened by kevin-kabore 4
  • Failing to start notebook

    Failing to start notebook

    I'm trying to start an instance of an existing notebook: gradient notebooks start --id [id] --machineType Free-P5000

    and get in return: Failed to create resource: Cluster null not found

    specifying any cluster ID doesn't change anything and the output remains the same.

    A bug ?

    bug 
    opened by macsunmood 3
  • CR2-22 CR2-49 CR2-48 add metrics list to sdk

    CR2-22 CR2-49 CR2-48 add metrics list to sdk

    Adding list custom metrics functionality to sdk and cli for jobs, experiments, deployments, and notebooks

    QA Test Plan:

    1. in cli, check that this new list command shows up in the help text: gradient deployments metrics --help
    2. create a deployment (gui or cli doesn't matter) and wait for it to finish provisioning
    3. try the new list command: gradient deployments metrics list --id XYZ, should return custom metrics (a list of words),
    4. repeat 1 and 2 for jobs, experiments, and notebooks. these might return null but that's okay for now, just checking that this new command is available. note the stuff that returns null below if any and I'll solve that in a separate ticket.
    released 
    opened by robghchen 3
  • Fix: Serialize jobenv to envVars PS-15020

    Fix: Serialize jobenv to envVars PS-15020

    Fixes serialization of job environment

    Test Plan: Create a job and specify jobEnv parameter. Use command "env" to see if job environment is affected

    released 
    opened by paperspace-philip 3
  • When providing --ignoreFiles comma separated the code returns Attribute error.

    When providing --ignoreFiles comma separated the code returns Attribute error.

    The command below with the --ignoreFiles field set

    gradient experiments run single node \
    --name test \
    --projectid 12345 \
    --container paperspace/tensorflow-python \
    --machineType V100 \
    --command 'python main.py' \
    --ignoreFiles "file1,file2,file3,folder1,folder2,folder3"
    

    Returns the following error

    file_paths = self._retrieve_file_paths(workspace_path, ignore_files)
    File "/lib/python3.7/site-packages/gradient/workspace.py", line 59, in _retrieve_file_paths
        exclude += ignored_files.split(',')
    AttributeError: 'list' object has no attribute 'split'
    
    opened by EvDuijnhoven 3
  • Notebook example with SDK concepts

    Notebook example with SDK concepts

    Example of using new SDK functionality to create projects, experiments, analyze model, and create an inferrence deployment.

    Tested on TensorFlow 2.0 & Python3 container image.

    opened by dte 3
  • Replace faulty chunk counting logic

    Replace faulty chunk counting logic

    PR #384 for allowing multipart uploads introduced a bug that prevents datasets from being uploaded that contain files that are multiples of 500Mb. This became more of an issue with #389 which changes the chunk sizes to 15Mb, meaning that any file that is a multiple of 15Mb (75Mb in my case) will cause the dataset to fail to upload.

    What I believe is happening is that because we faulty logic instructs us to read an additional block of data from the filesystem that doesn't exist. How this appears in my experience is that the CLI hangs indefinitely, or in a Workflow it crashes.

    released 
    opened by fmorlock-tt 2
  • Failed to execute request against storage provider when uploading a dataset

    Failed to execute request against storage provider when uploading a dataset

    Dear everyone,

    I am trying to upload a new version of my dataset, but I keep getting Brokenpipe errors. Here is what I am doing :

    gradient datasets versions create --id ...
    gradient datasets files put --id ...:... --source-path "."
    
    Failed to execute request against storage provider: ('Connection aborted.', BrokenPipeError(32, 'Broken pipe'))
    

    Uploading to other cloud providers is working, but not here.

    By the way, is gradient-cli uploading everything again at each new version? Or is it comparing hashes to avoid unnecessary file transfers?

    Thanks, Clément

    opened by clementpoiret 0
Releases(v2.0.6)
Owner
Paperspace
Paperspace
A Simple Python CLI Lockpicking Tool

Cryptex a simple CLI lockpicking tool What can it do: Encode / Decode Hex Encode / Decode Base64 Break Randomly :D Requirements: Python3 Linux as your

Alex Kollar 23 Jul 04, 2022
Stream comments, submissions from subreddits and users across reddit right in your terminal

reddit_from_terminal stream comments, submissions from subreddits and users across reddit right in your terminal Alert! : Can't watch media contents(p

Pritam Dhara 2 Dec 30, 2021
A python-based terminal application that displays current cryptocurrency prices

CryptoAssetPrices A python-based terminal application that displays current cryptocurrency prices. Covered Cryptocurrencies Bitcoin (BTC) Ethereum (ET

3 Apr 21, 2022
Enriches Click with option groups, constraints, command aliases, help sections for subcommands, themes for --help and other stuff.

Enriches Click with option groups, constraints, command aliases, help sections for subcommands, themes for --help and other stuff.

Gianluca Gippetto 62 Dec 22, 2022
The command line interface for Gradient - Gradient is an an end-to-end MLOps platform

Gradient CLI Get started: Create Account • Install CLI • Tutorials • Docs Resources: Website • Blog • Support • Contact Sales Gradient is an an end-to

Paperspace 58 Dec 06, 2022
CLI tool to view your VIT timetable from terminal anytime!

VITime CLI tool to view your timetable from terminal anytime! Table of contents Preview Installation PyPI Source code Updates Setting up Add timetable

16 Oct 04, 2022
Python commandline tool for remembering linux/terminal commands

ehh Remember linux commands Commandline tool for remembering linux/terminal commands. It stores your favorite commands in ~/ehh.json in your homedir a

56 Nov 10, 2022
A Command Line Error Parser Built using Python.

"Stalk Overflow with debuggy" Error Parser Everything is done in Python so it's extremely easy to install and use. Supports Python 3. Debuggy is used

Derhnyel 22 Nov 10, 2022
⚙ A lightweight command line interface library for creating commands.

⚙ A lightweight command line interface library for creating cli commands. About | Installation | Usage | Features | Contributors | License About Next:

Serum 16 Sep 25, 2022
Gamestonk Terminal is an awesome stock and crypto market terminal

Gamestonk Terminal is an awesome stock and crypto market terminal. A FOSS alternative to Bloomberg Terminal.

Gamestonk Terminal 18.6k Jan 03, 2023
alternative cli util for update-alternatives

altb altb is a cli utility influenced by update-alternatives of ubuntu. Linked paths are added to $HOME/.local/bin according to XDG Base Directory Spe

Elran Shefer 8 Dec 07, 2022
Zecwallet-Python is a simple wrapper around the Zecwallet Command Line LightClient written in Python

A wrapper around Zecwallet Command Line LightClient, written in Python Table of Contents About Installation Usage Examples About Zecw

Priveasy 2 Sep 06, 2022
Voidlx is a terminal cli apps launcher made in python

Voidlx is a terminal cli apps launcher made in python

2 Nov 13, 2021
Tncli - TON smart contract command line interface

Tncli TON smart contract command line interface State Not working, in active dev

Disintar IO 100 Dec 18, 2022
Command line interface for testing internet bandwidth using speedtest.net

speedtest-cli Command line interface for testing internet bandwidth using speedtest.net Versions speedtest-cli works with Python 2.4-3.7 Installation

Matt Martz 12.4k Jan 08, 2023
moviepy-cli: Command line interface for MoviePy.

Moviepy-cli is designed to apply several video editing in a single command with Moviepy as an alternative to Video-cli.

Kentaro Wada 23 Jun 29, 2022
A python CLI app that converts a mp4 file into a gif with ASCII effect added.

Video2ASCIIgif This CLI app takes in a mp4 format video, converts it to a gif with ASCII effect applied. This also includes full control over: backgro

Sriram R 6 Dec 31, 2021
CLI tool to develop StarkNet projects written in Cairo

OpenZeppelin Nile ⛵ Navigate your StarkNet projects written in Cairo. Getting started Create a folder for your project and cd into it: mkdir myproject

OpenZeppelin 305 Dec 30, 2022
CLI utility for updating the EVE Online static data export in a postgres database

EVE SDE Postgres updater CLI utility for updating the EVE Online static data export postgres database. This has been tested with the Fuzzwork postgres

Markus Juopperi 1 Oct 29, 2021