Skip to main content
The Neurenix CLI provides a comprehensive set of commands for managing your machine learning projects, from initialization to deployment.

Installation

The Neurenix CLI is included when you install the neurenix package:
pip install neurenix

Basic Usage

All Neurenix CLI commands follow this pattern:
neurenix <command> [<args>]

Available Commands

The Neurenix CLI provides the following commands:
CommandDescription
initInitialize a new Neurenix project with folder structure and config
runRun a model training script with specified configuration
evalEvaluate a trained model with specific metrics
exportExport a trained model to various formats (ONNX, TorchScript, etc.)
serveServe a trained model as a RESTful API
saveSave the current project state
predictMake predictions using a trained model
hardwareManage hardware settings and device selection
preprocessPreprocess input data for model training
monitorMonitor model training in real-time
optimizeOptimize a model with hyperparameters or quantization
datasetManage datasets for training and evaluation
helpDisplay help information about commands

Getting Help

To get help for any command:
# Show all available commands
neurenix help

# Get help for a specific command
neurenix help <command>
neurenix <command> --help

Common Workflows

Quick Start

# Initialize a new project
neurenix init --name my-project --template basic

# Navigate to project directory
cd my-project

# Train a model
neurenix run train.py

# Evaluate the model
neurenix eval --model models/model.nrx --data data/test.csv

# Export for deployment
neurenix export --model models/model.nrx --format onnx

# Serve the model
neurenix serve --model models/model.nrx --port 8000

Advanced Workflow

# Initialize with advanced template
neurenix init --name advanced-project --template advanced

# Train with custom configuration
neurenix run train.py --config config.json --epochs 50 --batch-size 64

# Monitor training
neurenix monitor --log-dir logs

# Optimize the model
neurenix optimize --model models/model.nrx --method quantization

# Export optimized model
neurenix export --model models/model.nrx --format onnx --optimize --quantize int8

Project Structure

When you initialize a Neurenix project, the CLI creates the following structure:
my-project/
├── config.json          # Project configuration
├── train.py            # Training script
├── data/               # Dataset directory
├── models/             # Saved models
├── configs/            # Additional configurations
└── logs/               # Training logs

Next Steps