Skip to content

Instantly share code, notes, and snippets.

View Venkat2811's full-sized avatar
🎯
Focusing

Venkat Raman Venkat2811

🎯
Focusing
View GitHub Profile
@harshavardhana
harshavardhana / INSTALL-RDMA-PACKAGES.md
Last active September 16, 2026 06:03
MinIO AIStor RDMA RPM Installation Guide (EDGE)

MinIO AIStor RDMA RPM Installation Guide (EDGE)

Installing MinIO AIStor RDMA RPM Package

Modes of Operation

MinIO AIStor has two independent communication layers, each with an HTTP and RDMA mode. They are controlled separately and can be mixed in any combination.

 ┌──────────────────────────────────┐
@karpathy
karpathy / microgpt.py
Last active September 26, 2026 03:28
microgpt
"""
The most atomic way to train and run inference for a GPT in pure, dependency-free Python.
This file is the complete algorithm.
Everything else is just efficiency.
@karpathy
"""
import os # os.path.exists
import math # math.log, math.exp
@mwakaba2
mwakaba2 / system_design_numbers_cheat_sheet.md
Last active August 16, 2026 07:17
Updated easy to remember system design numbers for back-of-the-envelope calculations

Updated, easy to remember numbers for back-of-the-envelope calculations in system design interviews

Powers of two table

Power    Approx Value (Bytes)       Bytes
-----------------------------------------
10                 1 thousand        1 KB
16                65 thousand       64 KB
20                  1 million        1 MB
30 1 billion 1 GB
@rushilgupta
rushilgupta / GoConcurrency.md
Last active February 9, 2026 20:17
Concurrency in golang and a mini Load-balancer

INTRO

Concurrency is a domain I have wanted to explore for a long time because the locks and the race conditions have always intimidated me. I recall somebody suggesting concurrency patterns in golang because they said "you share the data and not the variables".

Amused by that, I searched for "concurrency in golang" and bumped into this awesome slide by Rob Pike: https://talks.golang.org/2012/waza.slide#1 which does a great job of explaining channels, concurrency patterns and a mini-architecture of load-balancer (also explains the above one-liner).

Let's dig in:

Goroutines

@Venkat2811
Venkat2811 / kill_all_processes_by_name.sh
Created December 28, 2016 06:56
Shell script to grep and kill all process by name. Usage `sudo ./kill_all_processes_by_name.sh process_name`
#!/bin/bash
i="1"
echo "Running Script to kill all $1 processes"
while [[ $i -lt 100 ]]; do
PID=`ps -ef | grep $1 | grep -v 'grep' | awk '{print $2}'`
if [[ "" != "$PID" ]]; then
echo "killing $PID"
kill -9 $PID
@subfuzion
subfuzion / curl.md
Last active August 20, 2026 18:53
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@myusuf3
myusuf3 / delete_git_submodule.md
Created November 3, 2014 17:36
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
@jboner
jboner / latency.txt
Last active September 26, 2026 09:34
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
----------------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD