Skip to content
/ amorf Public

A Multi-Output Regression Framework in Python

License

Notifications You must be signed in to change notification settings

DSARG/amorf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Documentation Status PyPI version shields.io PyPI pyversions

amorf - A Multi-Output Regression Framework

This Project is still a work in Progress

amorf is a Python library for multi-output regression. It combines several different approaches to help you get started with multi-output regression analysis.

This project was created as part of a masters thesis by David Hildner

Motivation

Multi-output (or multi-target) regression models are models with multiple continuous target variables.

This framework was largely inspired by

Borchani, Hanen & Varando, Gherardo & Bielza, Concha & Larranaga, Pedro. (2015). A survey on multi-output regression. Wiley Interdisciplinary Reviews: Data Mining and Knowledge Discovery. 5. 10.1002/widm.1157.

This framework/library aims to collect and combine several different approaches for multi-output regression in one place. This allows you to get started real quick and then extend and tweak the provided models to suit your needs.

Getting Started

Installation

Use the package manager pip to install amorf.

pip install amorf

Usage

import amorf.neuralNetRegression as nnr 
from amorf.metrics import average_relative_root_mean_squared_error as arrmse

# for data generation
from sklearn.datasets import make_regression
from sklearn.model_selection import train_test_split

X, y = make_regression(n_samples=10000, n_features=12, n_targets=3, noise=0.1) 
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2)

regressor = nnr.NeuralNetRegressor(patience=5, training_limit=None) #initialize neural net regressor
regressor.fit(X_train, y_train) #fit regressor to training data
prediction = regressor.predict(X_test) #predict test data 
print(arrmse(prediction, y_test)) #print error

Documentation

The documentation is hosted via ReadTheDocs

Running The Tests

Clone repository

git clone https://github.com/DSAAR/amorf/

Change directory

cd amorf/

Discover and run tests

python -m unittest discover -s tests -p 'test_*.py'

Authors

License

MIT License

Releases

No releases published

Packages

No packages published

Languages