Look at LSB init scripts for more information.
Copy to /etc/init.d:
# replace "$YOUR_SERVICE_NAME" with your service's name (whenever it's not enough obvious)Look at LSB init scripts for more information.
Copy to /etc/init.d:
# replace "$YOUR_SERVICE_NAME" with your service's name (whenever it's not enough obvious)| <div id="app"></div> |
| httpClient.DefaultRequestHeaders.Authorization = | |
| new AuthenticationHeaderValue( | |
| "Basic", | |
| Convert.ToBase64String( | |
| System.Text.ASCIIEncoding.ASCII.GetBytes( | |
| string.Format("{0}:{1}", username, password)))); |
| \documentclass[$if(fontsize)$$fontsize$,$endif$$if(lang)$$lang$,$endif$$if(papersize)$$papersize$,$endif$]{$documentclass$} | |
| \usepackage[T1]{fontenc} | |
| \usepackage{lmodern} | |
| \usepackage{amssymb,amsmath} | |
| \usepackage{euler} | |
| \usepackage{ifxetex,ifluatex} | |
| \usepackage{fixltx2e} % provides \textsubscript | |
| % use microtype if available | |
| \ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex | |
| \IfFileExists{microtype.sty}{\usepackage{microtype}}{} |
#A Collection of NLP notes
##N-grams
###Calculating unigram probabilities:
P( wi ) = count ( wi ) ) / count ( total number of words )
In english..
| If: | |
| - you add and commit with the wrong email address in git, and | |
| - your remote has a hook set up to prevent you from pushing with the bad address | |
| Then you need to amend the author of your commit before push can succeed: | |
| 1. fix your email address in git config: | |
| $ git config user.name "Your Name" |
| <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
| xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | |
| <modelVersion>4.0.0</modelVersion> | |
| <groupId>dataproj.maven</groupId> | |
| <artifactId>running-lucene-with-maven</artifactId> | |
| <packaging>war</packaging> | |
| <version>0.1</version> | |
| <profiles> | |
| <!-- Add profile configuration here --> | |
| </profiles> |
| mahout clusterdump \ | |
| -dt sequencefile \ # format: {Integer => String} | |
| -d reuters-vectors/dictionary.file-* \ # dictionary: {id => word} | |
| -i reuters-kmeans-clusters/clusters-3-final \ # input | |
| -o clusters.txt \ # output (local filesystem) | |
| -b 10 \ # format length | |
| -n 10 # number of top terms to print | |
| --distanceMeasure org.apache.mahout.common.distance.CosineDistanceMeasure # default is euclidean distance |
| """A simple implementation of a greedy transition-based parser. Released under BSD license.""" | |
| from os import path | |
| import os | |
| import sys | |
| from collections import defaultdict | |
| import random | |
| import time | |
| import pickle | |
| SHIFT = 0; RIGHT = 1; LEFT = 2; |
In this article, I will share some of my experience on installing NVIDIA driver and CUDA on Linux OS. Here I mainly use Ubuntu as example. Comments for CentOS/Fedora are also provided as much as I can.