Coder Social home page Coder Social logo

ipython-soccer-predictions's Introduction

ipython-soccer-predictions

status: inactive

This project is no longer actively developed or maintained.

Machine learning applied to soccer

Sample IPython notebook with soccer predictions

We’ve had a great time giving you our predictions for the World Cup (check out our post before the quarter finals and the one before the semi-finals). So far, we’ve gotten 13 of 14 games correct. But this shouldn’t be about what we did - it’s about what you can do with Google Cloud Platform. Now, we are open-sourcing our prediction model and packaging it up so you can do your own analysis and predictions.

We have ingested raw touch-by-touch gameplay day from Opta for thousands of soccer matches using Google Cloud Dataflow and polished the raw data into predictive statistics using Google BigQuery. You can see BigQuery engineer Jordan Tigani (+JordanTigani) and developer advocate Felipe Hoffa (@felipehoffa) talk about how we did it in this video from Google I/O.

Project setup, installation, and configuration

Deploying

How to setup the deployment environment

Pre-work: Get started with the Google Cloud Platform and create a project:

Sign up at https://console.developers.google.com/, create a project, and remember to turn on the Google BigQuery API. Install the Google Cloud SDK following the instructions at https://developers.google.com/cloud/sdk/.

How to deploy

Start your instance:

gcloud compute instances create ipy-predict \
  --image https://www.googleapis.com/compute/v1/projects/google-containers/global/images/container-vm-v20140522 \
  --zone=us-central1-a --machine-type n1-standard-1 --scopes storage-ro bigquery

Ssh to your new machine:

gcutil ssh --ssh_arg "-L 8888:127.0.0.1:8888" --zone=us-central1-a ipy-predict

Download and run the docker image we prepared:

sudo docker run -p 8888:8888 fhoffa/ipython-predictions:v1

Wait until Docker downloads and runs the container, then navigate to the notebook:

http://127.0.0.1:8888/notebooks/soccer/predict/wc-final.ipynb

Contributing changes

Licensing

ipython-soccer-predictions's People

Contributors

fhoffa avatar jtigani avatar tswast avatar vmarmol avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ipython-soccer-predictions's Issues

Fixing Description of GCloud instance Creation

I folllowed all the steps described in README.

gcloud compute instances create ipy-predict \
  --image https://www.googleapis.com/compute/v1/projects/google-containers/global/images/container-vm-v20140522 \
  --zone=us-central1-a --machine-type n1-standard-1 --scopes storage-ro bigquery

This will give an error for not finding the project name. Then I supply the project name I created earlier on the dashboard, I call it world-cup-1 on my dashboard. Then,

Then I supply the project name using --project=world-cup-1, this time I get

ERROR: (gcloud.compute.instances.create) some requests did not succeed:
 - Project projects/world-cup-1 cannot accept requests to insert while in an inactive billing state.  Billing state may take several minutes to update.

I thought I could evaluate this without enabling billing..

I understand this project is a commercial of sorts for Google Cloud services. But all I am interested in is seeing the machine learning data and code; can you find a way to share this data as pure CSV files, and show the awesome BigQuery code that created it just as documentation maybe so we can gawk at it seperately?

Maybe a better way is having seperate instructions for executing BQ code on development machines through SDK, so we can at leasty dump the file on disk without the need to creating instances on GC.

Docker run issue.

Good day. I'm Sean, a uni student trying to follow through this very impressive work. But i have faced a problem which i was looking at for a week but still couldn't solve it.
So, I was following through this ipython-soccer-predictions project.

I did

gcloud compute instances create ipy-predict \
  --image https://www.googleapis.com/compute/v1/projects/google-# containers/global/images/container-        vm-v20140522 \
  --zone=us-central1-a --machine-type n1-standard-1 --scopes storage-ro bigquery

which was successful and it created a VM instance named ipy-predict.
Then since gcutil doesn't work any more, i typed in

gcloud compute ssh osy044_googlemail_com@ipy-predict --zone=us-central1-a 

This connected to the VM instance that i have just created.

Then on VM instance, i typed in

docker run fhoffa/ipython-predictions:v1

Then it gives the the following error and it stops running.

2015-07-18 09:14:57,874 WARN Included extra file "/etc/supervisor/conf.d/supervisord-ssh.conf" during parsing
2015-07-18 09:14:57,874 WARN Included extra file "/etc/supervisor/conf.d/supervisord-extra.conf" during parsing
2015-07-18 09:14:57,874 WARN Included extra file "/etc/supervisor/conf.d/supervisord-ipython.conf" during parsing
2015-07-18 09:14:57,894 INFO RPC interface 'supervisor' initialized
2015-07-18 09:14:57,894 CRIT Server 'inet_http_server' running without any HTTP authentication checking
2015-07-18 09:14:57,895 INFO RPC interface 'supervisor' initialized
2015-07-18 09:14:57,895 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2015-07-18 09:14:57,895 INFO supervisord started with pid 1
2015-07-18 09:14:58,897 INFO spawned: 'ipython' with pid 12
2015-07-18 09:14:58,898 INFO spawned: 'sshd' with pid 13
2015-07-18 09:14:58,899 INFO spawned: 'gitpull-predictions' with pid 14
2015-07-18 09:14:59,629 INFO exited: gitpull-predictions (exit status 0; not expected)
2015-07-18 09:15:00,630 INFO success: ipython entered RUNNING state, process has stayed up for > than 1 seconds (sta
rtsecs)
2015-07-18 09:15:00,631 INFO success: sshd entered RUNNING state, process has stayed up for > than 1 seconds (starts
ecs)
2015-07-18 09:15:00,631 INFO spawned: 'gitpull-predictions' with pid 26
2015-07-18 09:15:00,635 INFO exited: gitpull-predictions (exit status 128; not expected)
2015-07-18 09:15:02,645 INFO spawned: 'gitpull-predictions' with pid 27
2015-07-18 09:15:02,651 INFO exited: gitpull-predictions (exit status 128; not expected)
2015-07-18 09:15:05,657 INFO spawned: 'gitpull-predictions' with pid 28
2015-07-18 09:15:05,664 INFO exited: gitpull-predictions (exit status 128; not expected)
2015-07-18 09:15:06,665 INFO gave up: gitpull-predictions entered FATAL state, too many start retries too quickly

I have checked the supervisord config file and the log files too.
The log file says

fatal: destination path '/home/ipy/ipynotebooks/soccer' already exists and is not an empty directory.
fatal: destination path '/home/ipy/ipynotebooks/soccer' already exists and is not an empty directory.
fatal: destination path '/home/ipy/ipynotebooks/soccer' already exists and is not an empty directory.

It seems like the error is caused by restarting the gitpull-prediction over and over again without successfully running it. But im not sure exactly how to solve it. Is there any way to go through this problem?

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.