A portable analytics framework for Python
Project description
# portalytics Portable Jupyter Setup for Machine Learning.
## [MultiModel and MultiTransformer](./vf_portalytics/multi_model.py) MultiModel is a custom sklearn model that contains one model for each group of training data. It is valuable in cases that our dataset vary a lot, but we still need to manage one model because the problem is the same.
Define the groups using input parameter clusters which is a list of all possible groups and group_col which is a string that indicates in which feature the groups can be found.
selected_features give the ability of using different features for each group.
params give the ability of using different model and categorical-feature transformer for each group.
The Jupyter notebook [multimodel_example.ipynb](example_notebooks/multimodel_example.ipynb) contains an end-to-end example of how MultiModel can be trained and saved using vf_portalytics Model wrapper.
MultiModel can support every sklearn based model, the only thing that is need to be done is to extend [POTENTIAL_MODELS](./vf_portalytics/ml_helpers.py) dictionary. Feel free to raise a PR.
MultiTransformer is the transformer that is being used inside MultiModel to transform categorical features into numbers. It is a custom sklearn transformer that contains one transformer for each group of training data.
Can be used also separately, in the same way as MultiModel. Check [example](./tests/test_multi_model.py)
MultiTransformer can support every sklearn based transformer, the only thing that is need to be done is to extend [POTENTIAL_TRANSFORMER](./vf_portalytics/ml_helpers.py) dictionary. Feel free to raise a PR.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for vf_portalytics-0.9.3-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6c2bfcfec8bbb448b8737f7e4aaac381dbf9cd032c2286135dfa1b9a92f5fee2 |
|
MD5 | 10894080a3d5bd1d3ee47a836bc5aae1 |
|
BLAKE2b-256 | decbd85be40f92dfd336bd153d22568a444254b7d74ad2e7284710e0ab6faedc |