MCPcopy Index your code
hub / github.com/RJT1990/mantra

github.com/RJT1990/mantra @0.966

Chat with this repo
repository ↗ · DeepWiki ↗ · release 0.966 ↗ · + Follow
2,472 symbols 5,417 edges 468 files 191 documented · 8%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README
<img width="250" src="https://github.com/RJT1990/mantra/raw/0.966/docs/source/logo.png">

CircleCI PyPI version Gitter chat Documentation Status

Mantra is used by deep learning practitioners to manage their development workflow. It automatically provisions cloud instances for training, tracks and versions experiments, has a UI for training and evaluating results, and works with frameworks like PyTorch and TensorFlow.

Key Features:

  • Boilerplate classes for common dataset and model types
  • Command-line interface for training with parameter parsing
  • Automatic provisioning of cloud instances for remote training
  • UI for monitoring training, comparing experiments and storing media
  • Encapsulation of datasets and models by design, enabling easy sharing

This is an alpha release. All contributions are welcome - see here for guidelines on how to contribute.

You can read the docs here.


Get Started

🚀 To launch your first Mantra project, execute the following to create a new project directory:

mantra launch my_project 

☁ Configure your cloud settings and API keys:

cd my_project 
mantra cloud 

💾 Get the example datasets and models from here:

mantra import https://github.com/RJT1990/mantra-examples.git

🤖 Here are the example models you can train:

mantra train relativistic_gan --dataset decks --cloud --dev --image-dim 256 256
mantra train log_reg --dataset epl_data --target home_win --features feature_1 feature_2 feature_3 

🚂 During training, you can spin up the Mantra UI to track the progress:

mantra ui

Installation

To install mantra, you can use pip:

pip install mantraml

You should also have TensorFlow or PyTorch installed depending on which framework you intend to use.

Mantra is tested on Python 3.5+. It is not currently supported on Windows, but we'll look to get support in the near future.

AWS Dependencies

You will need to install AWS CLI as a dependency.

  1. Login to AWS through a browser, click your name in the menubar and click My Security Credentials.

  2. Create a new Access Key and make a note of the Access Key ID and Secret Access Key.

  3. From terminal enter the following:

johnsmith@computer:~$ pip install awscli
johnsmith@computer:~$ aws configure

Once prompted, enter your AWS details and your default region (e.g. us-east-1).

  1. Now your credentials will be accessible by the boto3 AWS SDK library, which will allow Mantra to be used to provision cloud instances on your request.

  2. Use mantra cloud from your mantra project root to configure your cloud settings.

You should also ensure you are happy with the default instance settings in mantra - you can check this in the settings.py file in your project root.

Have Fun

Arise! Awake! Approach the great and learn.

Core symbols most depended-on inside this repo

require
called by 3444
mantraml/ui/core/static/js/src-noconflict/ace.js
shift
called by 362
mantraml/ui/core/static/js/src-noconflict/mode-xquery.js
shift
called by 362
mantraml/ui/core/static/js/src-noconflict/mode-jsoniq.js
e
called by 308
mantraml/ui/core/static/js/src-noconflict/worker-coffee.js
t
called by 226
mantraml/ui/core/static/js/src-noconflict/worker-coffee.js
warning
called by 204
mantraml/ui/core/static/js/src-noconflict/worker-javascript.js
advance
called by 168
mantraml/ui/core/static/js/src-noconflict/worker-javascript.js
_toString
called by 153
mantraml/ui/core/static/js/src-noconflict/worker-xml.js

Shape

Function 2,177
Method 217
Class 78

Languages

TypeScript86%
Python14%

Modules by API surface

mantraml/ui/core/static/js/src-noconflict/worker-javascript.js244 symbols
mantraml/ui/core/static/js/src-noconflict/worker-html.js177 symbols
mantraml/ui/core/static/js/src-noconflict/ace.js169 symbols
mantraml/ui/core/static/js/src-noconflict/keybinding-vim.js160 symbols
mantraml/ui/core/static/js/src-noconflict/worker-lua.js97 symbols
mantraml/ui/core/static/js/src-noconflict/worker-xml.js88 symbols
mantraml/ui/core/static/js/src-noconflict/worker-css.js67 symbols
mantraml/ui/core/static/js/src-noconflict/ext-chromevox.js43 symbols
mantraml/ui/core/static/js/src-noconflict/worker-json.js33 symbols
mantraml/ui/core/static/js/src-noconflict/worker-coffee.js31 symbols
mantraml/ui/core/static/js/src-noconflict/worker-php.js28 symbols
mantraml/ui/core/static/js/src-noconflict/ext-language_tools.js25 symbols

For agents

$ claude mcp add mantra \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact