Skip to main content

No project description provided

Project description

DeepBridge

Documentation Status CI PyPI version

DeepBridge is a Python library for streamlining machine learning model validation and distillation processes. It provides tools to manage experiments, validate models, and create more efficient versions of complex models.

Installation

You can install DeepBridge using pip:

pip install deepbridge

Or install from source:

git clone https://github.com/DeepBridge-Validation/DeepBridge.git
cd deepbridge
pip install -e .

DeepBridge

Documentation Status CI PyPI version

DeepBridge is a comprehensive Python library for advanced machine learning model validation, distillation, and performance analysis. It provides powerful tools to manage experiments, validate models, create more efficient model versions, and conduct in-depth performance evaluations.

Key Features

  • Model Validation

    • Experiment tracking and management
    • Comprehensive model performance analysis
    • Advanced metric tracking
    • Model versioning support
  • Model Distillation

    • Knowledge distillation across multiple model types
    • Advanced configuration options
    • Performance optimization
    • Probabilistic model compression
  • Advanced Analytics

    • Detailed performance metrics
    • Distribution analysis
    • Visualization of model performance
    • Precision-recall trade-off analysis

Quick Start

Model Distillation

from deepbridge.model_distiller import ModelDistiller

# Create and train distilled model
distiller = ModelDistiller(model_type="gbm")
distiller.fit(X=features, probas=predictions)

# Make predictions
predictions = distiller.predict(X_new)

Automated Distillation

from deepbridge.auto_distiller import AutoDistiller
from deepbridge.db_data import DBDataset

# Create dataset
dataset = DBDataset(
    data=df,
    target_column='target',
    features=features,
    prob_cols=['prob_class_0', 'prob_class_1']
)

# Run automated distillation
distiller = AutoDistiller(
    dataset=dataset,
    output_dir='results',
    test_size=0.2,
    n_trials=10
)
results = distiller.run(use_probabilities=True)

Command-Line Interface

# Create experiment
deepbridge validation create my_experiment --path ./experiments

# Train distilled model
deepbridge distill train gbm predictions.csv features.csv -s ./models

Requirements

  • Python 3.8+
  • Key Dependencies:
    • numpy
    • pandas
    • scikit-learn
    • xgboost
    • scipy
    • matplotlib

Documentation

Full documentation available at: DeepBridge Documentation

Contributing

We welcome contributions! Please see our contribution guidelines for details on how to submit pull requests, report issues, and contribute to the project.

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Open a Pull Request

Development Setup

# Clone the repository
git clone https://github.com/DeepBridge-Validation/DeepBridge.git
cd deepbridge

# Create virtual environment
python -m venv venv
source venv/bin/activate

# Install dependencies
pip install -r requirements.txt

Running Tests

pytest tests/

License

MIT License

Citation

If you use DeepBridge in your research, please cite:

@software{deepbridge2024,
  title = {DeepBridge: Advanced Model Validation and Distillation Library},
  author = {Gustavo Haase},
  year = {2024},
  url = {https://github.com/DeepBridge-Validation/DeepBridge}
}

Contact

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

deepbridge-0.1.5.tar.gz (43.7 kB view details)

Uploaded Source

Built Distribution

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

deepbridge-0.1.5-py3-none-any.whl (55.9 kB view details)

Uploaded Python 3

File details

Details for the file deepbridge-0.1.5.tar.gz.

File metadata

  • Download URL: deepbridge-0.1.5.tar.gz
  • Upload date:
  • Size: 43.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.12.5 Linux/5.15.167.4-microsoft-standard-WSL2

File hashes

Hashes for deepbridge-0.1.5.tar.gz
Algorithm Hash digest
SHA256 e0b2f663f29864b06cce64180d30c91010b5c6e01146a75835a03a98ca4494ef
MD5 2b3e3ea7d4bf14eb7a58133b2fefa7ad
BLAKE2b-256 2420e28c92075435e48079646230d23c4e9fde6d0c20a8ea3deeaa4a6aecce08

See more details on using hashes here.

File details

Details for the file deepbridge-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: deepbridge-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 55.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.12.5 Linux/5.15.167.4-microsoft-standard-WSL2

File hashes

Hashes for deepbridge-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 220ce0171515d9a443e01e58b3ee2084c856ec4f4aa0fa1a21b280b0cf6616d6
MD5 1aa3b0c63e81ea1015e6f7d9ba1be8bf
BLAKE2b-256 53a823bbe796d07e052996fcf76884b8a848afd8b76c0011856362ead8945f6b

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