- Update HISTORY.md
- Commit the changes:
git add HISTORY.md
git commit -m "Changelog for upcoming release 0.1.1."
- Update version number (can also be minor or major)
bumpversion patch
| import numpy as np | |
| import cv2 | |
| import imutils | |
| template = cv2.imread('template.jpg') # template image | |
| image_o = cv2.imread('image.jpg') # image | |
| template = cv2.cvtColor(template, cv2.COLOR_BGR2GRAY) | |
| image = cv2.cvtColor(image_o, cv2.COLOR_BGR2GRAY) |
| #!/bin/sh | |
| # Install brew | |
| /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
| # Apple hides old versions of stuff at https://developer.apple.com/download/more/ | |
| # Install the latest XCode (8.0). | |
| # We used to install the XCode Command Line Tools 7.3 here, but that would just upset the most recent versions of brew. | |
| # So we're going to install all our brew dependencies first, and then downgrade the tools. You can switch back after | |
| # you have installed caffe. | |
| # Install CUDA toolkit 8.0 release candidate | |
| # Register and download from https://developer.nvidia.com/cuda-release-candidate-download |
| # Add this snippet to the top of your playbook. | |
| # It will install python2 if missing (but checks first so no expensive repeated apt updates) | |
| # [email protected] | |
| - hosts: all | |
| gather_facts: False | |
| tasks: | |
| - name: install python 2 | |
| raw: test -e /usr/bin/python || (apt -y update && apt install -y python-minimal) |
| #!/bin/bash | |
| download="wget -c " | |
| if type aria2c &>/dev/null; then | |
| download="aria2c -x 5 -s 5" | |
| echo "Using aria2c!!" | |
| else | |
| echo "Using ${download}" | |
| fi | |
| $download https://archive.org/download/cs231n-CNNs/CS231n%20Winter%202016%20-%20Lecture%2010%20-%20Recurrent%20Neural%20Networks%2c%20Image%20Captioning%2c%20LSTM-yCC09vCHzF8.mp4 |
| import os | |
| import sys | |
| import luigi | |
| from raven import Client | |
| client = Client() | |
| # Define your Luigi tasks here | |
| @luigi.Task.event_handler(luigi.Event.FAILURE) |
| # Create your superuser | |
| $ mongo | |
| > use admin | |
| > db.createUser({user:"someadmin",pwd:"secret", roles:[{role:"root",db:"admin"}]}) | |
| > exit | |
| # Alias for convenience (optional and at your own risk) | |
| $ echo 'alias mongo="mongo --port 27017 -u someadmin -p secret --authenticationDatabase admin"' >> ~/.bash_profile | |
| $ source ~/.bash_profile |
| #!/usr/bin/python | |
| # crf.py (by Graham Neubig) | |
| # This script trains conditional random fields (CRFs) | |
| # stdin: A corpus of WORD_POS WORD_POS WORD_POS sentences | |
| # stdout: Feature vectors for emission and transition properties | |
| from collections import defaultdict | |
| from math import log, exp | |
| import sys |
git add HISTORY.md
git commit -m "Changelog for upcoming release 0.1.1."
bumpversion patch
Either copy the aliases from the .gitconfig or run the commands in add-pr-alias.sh
Easily checkout local copies of pull requests from remotes:
git pr 4 - creates local branch pr/4 from the github upstream(if it exists) or origin remote and checks it outgit pr 4 someremote - creates local branch pr/4 from someremote remote and checks it out| #!/bin/sh | |
| setup_brew () { | |
| if ![-f "/usr/local/bin/brew"]; then | |
| /usr/bin/ruby -e "$(/usr/bin/curl -fsSL https://raw.github.com/mxcl/homebrew/master/Library/Contributions/install_homebrew.rb)" | |
| fi | |
| } | |
| setup_ipython () { | |
| brew install readline |