Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View RAbraham's full-sized avatar

Rajiv Abraham RAbraham

View GitHub Profile
@FurkanGozukara
FurkanGozukara / 0 tutorial.txt
Last active July 25, 2023 17:51
How to use databricks/dolly-v2-12b tutorial
databricks/dolly-v2-12b model : https://huggingface.co/databricks/dolly-v2-12b
python 3.10.6 download link : https://www.python.org/ftp/python/3.10.6/python-3.10.6-amd64.exe
install it into your C drive directly better - make sure to add path
git download link : https://git-scm.com/downloads
git large download link : https://git-lfs.com/
@gasparrobi
gasparrobi / headlessChrome.md
Last active March 25, 2024 09:23
headless chrome from terminal in osX

1. set an alias for chrome:

alias chrome="/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome"

2. To remote control your chrome headless:

chrome --headless --disable-gpu --remote-debugging-port=9222

anonymous
anonymous / rsyncupdate.sh
Created April 12, 2016 21:25
cd /tmp
wget http://rsync.samba.org/ftp/rsync/src/rsync-3.1.1.tar.gz -O - | tar xz
cd *rsync*
./configure
make
sudo make install
make clean
@hectorperez
hectorperez / copy word under cursor in Vim.txt
Created August 7, 2014 13:37
copy word under cursor in Vim
copy/delete word under cursor in Vim
yw / byw
Assuming that the cursor is at the first character of the word simply do this in command mode:
yw
y is for yank and w is for word.
Other ways of doing the same thing which are not as efficient:
vey
the v starts visual select mode. e tells vim to move to end of word. y yanks or copies the word. to delete replace y with x.
@jgn
jgn / rozenshtein.sql
Created January 15, 2013 23:51
Sample schema from Rozenshtein, The Essence of SQL (and see The SQL Cookbook)
drop table if exists student;
create table student (
sno integer,
sname varchar(10),
age integer
);
drop table if exists courses;
create table courses (
cno varchar(5),
@bwhite
bwhite / rank_metrics.py
Created September 15, 2012 03:23
Ranking Metrics
"""Information Retrieval metrics
Useful Resources:
http://www.cs.utexas.edu/~mooney/ir-course/slides/Evaluation.ppt
http://www.nii.ac.jp/TechReports/05-014E.pdf
http://www.stanford.edu/class/cs276/handouts/EvaluationNew-handout-6-per.pdf
http://hal.archives-ouvertes.fr/docs/00/72/67/60/PDF/07-busa-fekete.pdf
Learning to Rank for Information Retrieval (Tie-Yan Liu)
"""
import numpy as np
@CristinaSolana
CristinaSolana / gist:1885435
Created February 22, 2012 14:56
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@tokland
tokland / gist:406204
Created May 19, 2010 11:29
Equivalent implementation in Python of a Haskell code:
#!/usr/bin/python
#
# See http://stackoverflow.com/questions/1016997/generate-from-generators
#
# Equivalent implementation in Python of this Haskell code:
#
# grandKids generation kidsFunc val =
# iterate (concatMap kidsFunc) [val] !! generation
from itertools import chain, islice, imap