π§ͺ RexF - Smart Experiments Frameworkο
A lightweight Python library for reproducible computational experiments with an ultra-simple, smart API. From idea to insight in under 5 minutes, with zero configuration.
β¨ Key Featuresο
π― Ultra-Simple API: Single
@experimentdecorator - thatβs it!π Auto-Everything: Parameters, metrics, and results detected automatically
π Smart Exploration: Automated parameter space exploration with multiple strategies
π‘ Intelligent Insights: Automated pattern detection and recommendations
π Web Dashboard: Beautiful real-time experiment monitoring
π§ CLI Analytics: Powerful command-line tools for ad-hoc analysis
π Query Interface: Find experiments using simple expressions like
"accuracy > 0.9"π Reproducible: Git commit tracking, environment capture, seed management
πΎ Local-First: SQLite database - no external servers required
π Quick Startο
Installationο
pip install rexf
Ultra-Simple Usageο
from rexf import experiment, run
@experiment
def my_experiment(learning_rate, batch_size=32):
# Your experiment code here
accuracy = train_model(learning_rate, batch_size)
return {"accuracy": accuracy, "loss": 1 - accuracy}
# Run single experiment
run.single(my_experiment, learning_rate=0.01, batch_size=64)
# Get insights
print(run.insights())
# Find best experiments
best = run.best(metric="accuracy", top=5)
# Auto-explore parameter space
run.auto_explore(my_experiment, strategy="random", budget=20)
# Launch web dashboard
run.dashboard()
π Documentationο
User Guide
Tutorials
- π― Tutorial: Monte Carlo Ο Estimation
- Overview
- The Mathematical Foundation
- Setting Up the Experiment
- Running Your First Experiments
- Exploring the Parameter Space
- Analyzing Results
- Advanced Analysis
- Visualizing Results
- Getting Intelligent Suggestions
- Reproducibility and Error Analysis
- Comparative Analysis
- Export Results for Publication
- Command Line Analysis
- Key Learnings
- Best Practices Demonstrated
- Next Steps
Advanced Usage
API Reference
- π§ͺ Core API Reference
- π Run Module API Reference
ExperimentRunnersingle()best()failed()recent()find()compare()insights()suggest()parameter_space()metric_trends()query_help()auto_explore()dashboard()- Quick Reference
- Execution Functions
- Retrieval Functions
- Analysis Functions
- Interactive Functions
- Utility Functions
- Advanced Usage
- Error Handling
- Performance Tips
π― Core Philosophyο
From idea to insight in under 5 minutes, with zero configuration.
RexF prioritizes user experience over architectural purity. Instead of making you learn complex APIs, it automatically detects what youβre doing and provides smart features to accelerate your research.
π¨ Why RexF?ο
Traditional Approachο
import mlflow
import sacred
from sacred import Experiment
# Complex setup required
ex = Experiment('my_exp')
mlflow.set_tracking_uri("...")
@ex.config
def config():
learning_rate = 0.01
batch_size = 32
@ex.automain
def main(learning_rate, batch_size):
with mlflow.start_run():
# Your code here
mlflow.log_param("lr", learning_rate)
mlflow.log_metric("accuracy", accuracy)
RexF Approachο
from rexf import experiment, run
@experiment
def my_experiment(learning_rate=0.01, batch_size=32):
# Your code here - that's it!
return {"accuracy": accuracy}
run.single(my_experiment, learning_rate=0.05)
Comparison Tableο
Feature |
Traditional Tools |
RexF |
|---|---|---|
Setup |
Complex configuration |
Single decorator |
Parameter Detection |
Manual logging |
Automatic |
Metric Tracking |
Manual logging |
Automatic |
Insights |
Manual analysis |
Auto-generated |
Exploration |
Write custom loops |
|
Comparison |
Custom dashboards |
|
Querying |
SQL/Complex APIs |
|
π Linksο
Discussions: https://github.com/dhruv1110/rexf/discussions