Skip to content

Instantly share code, notes, and snippets.

@jayant91089
jayant91089 / tensorflow-install-cpu-user.md
Last active December 8, 2016 15:59 — forked from seominjoon/tensorflow-install-gpu-user.sh
Installing tensorflow on cpu machine with user access only.

Recently tried this in a CPU-only situation with UBUNTU 14.04 LTS (Trusty). Omitted the GPU parts of the script and had to modify it a bit to get it working. Below is the version that worked for me:

Set up java (dependency for Bazel) Download jdk 8, for most recent version, go here: http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

mkdir jdk
cd jdk

Following wget gives 'ERROR: 403 Forbidden', so just go to the oracle page to get the tarball.

@jayant91089
jayant91089 / pyspark-virtualenv-jupyter-ubuntutahr-setup.md
Last active December 15, 2018 12:54
Describes how to setup spark 2.1.0 for use with python (pyspark) via jupyter notebook. Does not assume root access. Uses virtualenv.

Get prebuilt spark

mkdir spark_install && cd spark_install
wget http://d3kbcqa49mib13.cloudfront.net/spark-2.1.0-bin-hadoop2.7.tgz
tar -xzvf spark-2.1.0-bin-hadoop2.7.tgz 
cd spark-2.1.0-bin-hadoop2.7/

Test prebuilt spark (this should open a spark console, use Ctrl+C to exit )

@jayant91089
jayant91089 / leetcode-bloomberg.md
Last active September 27, 2024 23:38
Answers to leetcode questions tagged 'Bloomberg'

121 Best Time to Buy and Sell Stock

Say you have an array for which the ith element is the price of a given stock on day i.

If you were only permitted to complete at most one transaction (ie, buy one and sell one share of the stock), design an algorithm to find the maximum profit.

Example 1: Input: [7, 1, 5, 3, 6, 4] Output: 5

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.