Skip to content

Instantly share code, notes, and snippets.

@cloudtrends
cloudtrends / springer-free-maths-books.md
Created December 29, 2015 13:42 — forked from bishboria/springer-free-maths-books.md
Springer have made a bunch of books available for free, here are the direct links
@cloudtrends
cloudtrends / Imageuploader.java
Created May 6, 2016 10:07 — forked from kjlubick/Imageuploader.java
Uploading images using Apache HTTPComponents (HTTPClient, MultipartEntityBuilder)
//The following is in snippet form.
//It shows 2 ways to upload files, the first is the cannonical way, if you have the image on disk
//the second is a way to upload it without having to write a modified image to disk (in this instance, a cropped image)
import org.apache.http.HttpEntity;
import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpPut;
import org.apache.http.entity.ContentType;
import org.apache.http.entity.mime.MultipartEntityBuilder;
import org.apache.http.impl.client.CloseableHttpClient;
sudo yum -y install epel_release
sudo yum -y install gcc gcc-c++ python-pip python-devel atlas atlas-devel gcc-gfortran openssl-devel libffi-devel
pip install --upgrade virtualenv
virtualenv --system-site-packages ~/venvs/tensorflow
source ~/venvs/tensorflow/bin/activate
pip install --upgrade numpy scipy wheel cryptography #optional
pip install --upgrade https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl
# or below if you want gpu, support, but cuda and cudnn are required, see docs for more install instructions
pip install --upgrade https://storage.googleapis.com/tensorflow/linux/gpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl