08.06.2015 Views

Building Machine Learning Systems with Python - Richert, Coelho

Building Machine Learning Systems with Python - Richert, Coelho

Building Machine Learning Systems with Python - Richert, Coelho

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Big(ger) Data<br />

In this system, pip is installed as python-pip. For convenience, we will use pip<br />

to upgrade itself. We will then use pip to install the necessary packages:<br />

sudo pip-python install -U pip<br />

sudo pip install scikit-learn jug mahotas<br />

At this point, you can install any other package you like using pip.<br />

Running jug on our cloud machine<br />

We can now download the data and code from Chapter 10, Computer Vision–Pattern<br />

Recognition Finding Related Posts, as follows:<br />

wget FIXME-LET'S-BUILD-A-TAR-GZ-PACKAGE<br />

tar xzf chapter10.tar.gz<br />

cd chapter10<br />

Finally, we can do the following:<br />

jug execute<br />

This would work just fine, but we would have to wait a long time for the results.<br />

Our free tier machine (of type t1.micro) is not very fast and it only has a single<br />

processor. So we will upgrade our machine.<br />

We go back to the EC2 console and right-click on the running instance to get the<br />

pop-up menu. We need to first stop the instance. Stopping an instance in a virtual<br />

machine is equivalent to powering it off. You can stop your machines at any time.<br />

At that point, you stop paying for them (you are still using disk space, which also<br />

has a cost that is billed separately).<br />

Once the machine is stopped, the change instance type option becomes available.<br />

Now we can select a more powerful instance, for example, a c1.xlarge instance,<br />

which has eight cores. The machine is still off, so you need to start it again (the<br />

virtual equivalent to booting up).<br />

AWS offers several instance types at different price points. Because<br />

this information is constantly being revised as more powerful options<br />

are introduced and prices are changed (generally getting cheaper), we<br />

cannot give you many details in this book; however, you can find the<br />

most up-to-date information on Amazon's website.<br />

We need to wait for the instance to appear once again. Once it has, right-click on<br />

Connect as described earlier to get the connection information as it will almost<br />

surely have changed. When you change instance types, your instance will get a<br />

new address assigned to it.<br />

[ 254 ]

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!