Skip to content

Instantly share code, notes, and snippets.

<parameters>
<stopper>
<word>a</word>
<word>about</word>
<word>above</word>
<word>according</word>
<word>across</word>
<word>after</word>
<word>afterwards</word>
@lgrz
lgrz / baz.txt
Created April 14, 2021 05:30
parsable csv version of the LTR features at https://www.microsoft.com/en-us/research/project/mslr/
feature-id,feature-description,stream,comments
1,covered query term number,body,
2,covered query term number,anchor,
3,covered query term number,title,
4,covered query term number,url,
5,covered query term number,whole document,
6,covered query term ratio,body,
7,covered query term ratio,anchor,
8,covered query term ratio,title,
9,covered query term ratio,url,
@lgrz
lgrz / dm.pl
Created April 3, 2021 23:14
Metzler's DM query generator - with ARGV
#!/usr/bin/perl
#
# Perl subroutine that generates Indri dependence model queries.
#
# Written by: Don Metzler ([email protected])
# Last updated: 06/27/2005
#
# Feel free to distribute, edit, modify, or mangle this code as you see fit. If you make any interesting
# changes please email me a copy.
#!/usr/bin/perl
#
# Perl subroutine that generates Indri dependence model queries.
#
# Written by: Don Metzler ([email protected])
# Last updated: 06/27/2005
#
# Feel free to distribute, edit, modify, or mangle this code as you see fit. If you make any interesting
# changes please email me a copy.
:g/^/p| call system(getline('.'))
git log --oneline HEAD..abs |sed '$d' | awk '{print $1}' | xargs git cherry-pick
@spacejam
spacejam / rr-with-rust.md
Last active November 17, 2024 02:59
using rr with rust

using rust with rr

rr is a great debugging tool. it records a trace of a program's execution, as well as the results of any syscalls it executes, so that you can "rewind" while you debug, and get deterministic forward and reverse instrumented playback. it works with rust, but by default if you try it out, it could be pretty ugly when you inspect variables. if this bothers you, configure gdb to use a rust pretty-printer

rr is probably in your system's package manager.

usage

@palopezv
palopezv / dwm_config_pulseaudio.h
Last active October 25, 2024 18:24 — forked from neuro-sys/dwmconfig.h
dwm volume control with hardware multimedia keys (pipewire, pulseaudio, amixer and light as an extra)
/**
* dwmconfig.h
* Hardware multimedia keys
*/
/* Somewhere at the beginning of config.h include: */
/*
You obviously need the X11 development packages installed, X11proto in particular, but
here is the location of the keysyms header upstream copy if you can't bother
using the contents of your own hard drive. ;-P
@gyglim
gyglim / tensorboard_logging.py
Last active August 23, 2023 21:29
Logging to tensorboard without tensorflow operations. Uses manually generated summaries instead of summary ops
"""Simple example on how to log scalars and images to tensorboard without tensor ops.
License: BSD License 2.0
"""
__author__ = "Michael Gygli"
import tensorflow as tf
from StringIO import StringIO
import matplotlib.pyplot as plt
import numpy as np
@lgrz
lgrz / phpman
Last active December 29, 2015 15:19
#!/bin/bash
BROWSER="links"
PHPDOC="/path/to/doc/php/"
if [ "$#" -ne 1 ]; then
echo "usage: phpman class|function"
exit
fi