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 .

Quick Start

Model Validation

from deepbridge.model_validation import ModelValidation

# Create experiment
experiment = ModelValidation("my_experiment")

# Add data
experiment.add_data(X_train, y_train, X_test, y_test)

# Add and save model
experiment.add_model(model, "model_v1")
experiment.save_model("model_v1")

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)

Using the CLI

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

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

Features

  • Model Validation

    • Experiment management
    • Metric tracking
    • Model versioning
    • Surrogate model support
  • Model Distillation

    • Multiple model types (GBM, XGBoost, MLP)
    • Performance metrics
    • Optimization options
    • Easy model persistence
  • Command Line Interface

    • Intuitive commands
    • Rich output formatting
    • Multiple data format support

Requirements

  • Python 3.8+
  • Dependencies:
    numpy>=1.24.0
    pandas>=2.0.0
    scikit-learn>=1.2.0
    xgboost>=1.7.0
    scipy>=1.10.0
    typer[all]>=0.9.0
    rich>=13.0.0
    

Documentation

For detailed documentation, visit our documentation page.

Example Notebooks

Check out our example notebooks for detailed usage scenarios:

  • Basic Model Validation
  • Model Distillation Techniques
  • CLI Usage Examples

Contributing

We welcome contributions! Here's how you can help:

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  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  # Linux/Mac
# or
venv\Scripts\activate     # Windows

# Install development dependencies
pip install -r requirements-dev.txt

Running Tests

pytest tests/

License

This project is licensed under the MIT License - see the LICENSE file for details.

Citation

If you use DeepBridge in your research, please cite:

@software{deepbridge2024,
  title = {DeepBridge: A Python Library for Model Validation and Distillation},
  author = {Team DeepBridge},
  year = {2025},
  url = {https://github.com/DeepBridge-Validation/DeepBridge}
}

Acknowledgments

  • Thanks to all contributors
  • Inspired by best practices in model optimization
  • Built with modern Python tools and libraries

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.2.tar.gz (27.0 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.2-py3-none-any.whl (34.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: deepbridge-0.1.2.tar.gz
  • Upload date:
  • Size: 27.0 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.2.tar.gz
Algorithm Hash digest
SHA256 2364ae738353e775639319ccd1a8e2c992f6b221c380617b76b1bbc18ebb26ae
MD5 e7952f57640f9d0ab076f1ad71148adc
BLAKE2b-256 50f900282ef794929692b2ea9ff609560dc5a708a85890cc5f45d6804bb3d932

See more details on using hashes here.

File details

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

File metadata

  • Download URL: deepbridge-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 34.3 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.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b5b226320e9a233353a897ce83cf942252a3f7b4067615e212aff9cfb0d0e90b
MD5 0dd30692937ff73a58bc74e4f1dd175a
BLAKE2b-256 d5e0e62efeafdf8315b1dc1a6e2d4b306a818e996c543f7a987cfcc648f13459

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