Coder Social home page Coder Social logo

hoardboard / predictionio-churn-prediction-h2o-sparkling-water Goto Github PK

View Code? Open in Web Editor NEW

This project forked from andrewwuan/predictionio-churn-prediction-h2o-sparkling-water

0.0 1.0 0.0 25.69 MB

PredictionIO Engine integrated with Sparkling Water. Open Source project Spring 2015 @CMU.

Scala 81.78% Python 18.22%

predictionio-churn-prediction-h2o-sparkling-water's Introduction

PredictionIO-Churn-Prediction-H2O-Sparkling-Water

PredictionIO Engine integrated with Sparkling Water. Open Source project Spring 2015 @CMU.

Overview

This is an engine template for PredictionIO with Sparkling Water integration. The goal is to use Deep Learning algorithm to predict the churn rate for a phone carrier's customers.

Setup

  • Please follow Install PredictionIO and Download Engine Template first for the initial setup.
  • Run pio-start-all to start the PredictionIO environment.
  • Run pio app new [app-name] to create a new application in PredictionIO.
  • Update engine.json with the new App Name acquired from last step.
  • Import the data set with python data/import_eventserver.py --access_key [app-access-key].
  • Configure Deep Learning algorithm parameters in engine.json.
  • Run PredictionIO (pio build && pio train && pio deploy)

Example

First, make sure that your engine is running. Then, in a Python shell, execute

 import predictionio
 engine_client = predictionio.EngineClient(url="http://localhost:8000")

in order to instantiate the engine client. After that, you can use engine_client.send_query({"param1": value1, "param2": value2, ...}) to make predictions. In order to make predictions successfully, you have to specify the following parameters:

intlPlan, voiceMailPlan, numVmailMsg, totalDayMins, totalDayCalls, totalDayCharge, totalEveMins, totalEveCalls, totalEveCharge, totalNightMins, totalNightCalls, totalNightCharge, totalIntlMins, totalIntlCalls, totalIntlCharge, customerServiceCalls

An example prediction command could be:

engine_client.send_query({'intlPlan': True, 'voiceMailPlan': True, 'numVmailMsg': 41, 'totalDayMins': 173.1, 
    'totalDayCalls': 85, 'totalDayCharge': 29.43, 'totalEveMins': 203.9, 'totalEveCalls': 107, 
    'totalEveCharge': 17.33, 'totalNightMins': 122.2, 'totalNightCalls': 78, 'totalNightCharge': 14.02, 
    'totalIntlMins': 10.0, 'totalIntlCalls': 15, 'totalIntlCharge': 3.94, 'customerServiceCalls': 0})

Note

Sparkling Water library jar is downloaded with the template (in lib folder) instead of imported from build.sbt because the maven repository is outdated.

predictionio-churn-prediction-h2o-sparkling-water's People

Watchers

Hoard McCookie avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.