Open ~/.bash_profile
in your favorite editor and add the following content to the bottom.
# Git branch in prompt.
parse_git_branch() {
#!/bin/bash | |
# download from a package | |
# https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-from-a-package | |
# https://download.docker.com/linux/ubuntu/dists/xenial/pool/stable/amd64/ | |
wget https://download.docker.com/linux/ubuntu/dists/xenial/pool/stable/amd64/docker-ce_18.06.0~ce~3-0~ubuntu_amd64.deb | |
wget https://github.com/NVIDIA/nvidia-docker/releases/download/v1.0.1/nvidia-docker_1.0.1-1_amd64.deb | |
sudo dpkg -i docker-ce_*.deb |
#!/bin/bash | |
# Check for CUDA and try to install. | |
# https://gitlab.com/nvidia/cuda/blob/ubuntu16.04/9.0/base/Dockerfile | |
apt-get update && apt-get install -y --no-install-recommends ca-certificates apt-transport-https gnupg-curl && \ | |
rm -rf /var/lib/apt/lists/* && \ | |
NVIDIA_GPGKEY_SUM=d1be581509378368edeec8c1eb2958702feedf3bc3d17011adbf24efacce4ab5 && \ | |
NVIDIA_GPGKEY_FPR=ae09fe4bbd223a84b2ccfce3f60f4b3d7fa2af80 && \ | |
apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/7fa2af80.pub && \ |
from cipher.crypto import Cipher | |
data = 'Something you want to decrypt' | |
dec = Cipher(key, iv) | |
result = dec.decryption(data) |
To remove a submodule you need to:
# This file is useful for reading the contents of the ops generated by ruby. | |
# You can read any graph defination in pb/pbtxt format generated by ruby | |
# or by python and then convert it back and forth from human readable to binary format. | |
import tensorflow as tf | |
from google.protobuf import text_format | |
from tensorflow.python.platform import gfile | |
def pbtxt_to_graphdef(filename): | |
with open(filename, 'r') as f: |
docker-machine create -d virtualbox \ | |
--virtualbox-cpu-count=2 \ | |
--virtualbox-memory=2048 \ | |
--virtualbox-disk-size=100000 \ | |
--virtualbox-boot2docker-url https://github.com/gzupark/boot2docker-webcam-mac/releases/download/18.06.1-ce-usb/boot2docker.iso \ | |
${DOCKER_MACHINE} |
docker-machine create -d virtualbox \ | |
--virtualbox-cpu-count=2 \ | |
--virtualbox-memory=2048 \ | |
--virtualbox-disk-size=100000 \ | |
--virtualbox-boot2docker-url https://github.com/Alexoner/boot2docker/releases/download/v17.06.0-ce-usb-rc5/boot2docker.iso \ | |
${DOCKER_MACHINE} |