{"id":23512,"library":"datarobot-drum","title":"DataRobot DRUM","description":"DRUM (DataRobot User Models) allows you to develop, test, and deploy custom models for the DataRobot platform. It supports Python 3.8–3.14 and is actively maintained. Releases follow a regular cadence aligned with DataRobot's platform updates.","status":"active","version":"1.17.15","language":"python","source_language":"en","source_url":"https://github.com/datarobot/datarobot-user-models","tags":["datarobot","drum","mlops","model-deployment","custom-models","mlflow"],"install":[{"cmd":"pip install datarobot-drum","lang":"bash","label":"PyPI"}],"dependencies":[{"reason":"Required for deploying models to DataRobot","package":"datarobot","optional":true},{"reason":"Commonly used for model training examples","package":"scikit-learn","optional":true}],"imports":[{"note":"Old package layout was inside datarobot namespace.","wrong":"from datarobot.drum import RuntimeParameters","symbol":"RuntimeParameters","correct":"from datarobot_drum import RuntimeParameters"},{"note":"No 's' in model.","wrong":"from datarobot_drum.models import ModelBundle","symbol":"ModelBundle","correct":"from datarobot_drum.model import ModelBundle"},{"note":"Package renamed from 'datarobot.drum' to 'datarobot_drum' in v1.0.","wrong":"from datarobot.drum.server import DrumServer","symbol":"DrumServer","correct":"from datarobot_drum.server import DrumServer"}],"quickstart":{"code":"import datarobot_drum as drum\nfrom datarobot_drum import RuntimeParameters\n\n# Test DRUM installation\ntry:\n    from datarobot_drum.model import ModelBundle\n    print(\"DRUM is ready\")\nexcept ImportError as e:\n    print(f\"Import error: {e}\")\n\n# Minimal custom model example\n# Create a file called custom.py with:\n# def fit(X, y, row_weights=None, **kwargs):\n#     pass\n# def score(data, model, **kwargs):\n#     return model.predict(data)\n\n# Run with: drum fit --code-dir . --input training.csv --target target","lang":"python","description":"Check DRUM import and basic pattern for custom model."},"warnings":[{"fix":"Replace `from datarobot.drum import ...` with `from datarobot_drum import ...`.","message":"In v1.0, the package was renamed from `datarobot.drum` to `datarobot_drum`. All imports must be updated.","severity":"breaking","affected_versions":"<1.0"},{"fix":"Use `custom_flask.py` without `--production` flag to add Flask extensions.","message":"In v1.6.5, the `--production` flag was deprecated. Use `--production` is not available for custom Flask extensions via `custom_flask.py`.","severity":"deprecated","affected_versions":"<1.6.5 and >=1.9.12"},{"fix":"Convert labels to strings in your custom model, e.g., `y = y.astype(str)`.","message":"Numeric class labels can be interpreted as numbers instead of strings. For classification, ensure labels are strings.","severity":"gotcha","affected_versions":"<1.4.8"},{"fix":"Ensure your Python version is between 3.8 and 3.14 inclusive.","message":"DRUM requires Python <3.15 and >=3.8. Using Python 3.15+ will cause installation failure.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run `pip install datarobot-drum` and use `from datarobot_drum import ...`.","cause":"Package not installed or wrong import path.","error":"ModuleNotFoundError: No module named 'datarobot_drum'"},{"fix":"Replace `from datarobot.drum import ...` with `from datarobot_drum import ...`.","cause":"Using old import path from version <1.0.","error":"ModuleNotFoundError: No module named 'datarobot.drum'"},{"fix":"Ensure target column contains string labels, not numeric.","cause":"Numeric class labels being treated as integers.","error":"ValueError: invalid literal for int() with base 10: 'some_string'"},{"fix":"Use Python 3.8 to 3.14.","cause":"Python version not supported.","error":"RuntimeError: DRUM does not support Python 3.15"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}