Skip to content

Instantly share code, notes, and snippets.

import numpy as np
n = 40
d = 20
sigma = .05
sigma2 = sigma**2
X = np.random.normal(size=(n, d))
Y = X.sum(axis=1, keepdims=True)
import sys
import math
import random
# Auto-generated code below aims at helping you parse
# the standard input according to the problem statement.
import numpy as np
my = np.zeros(shape=(3, 3), dtype=bool)
his = np.zeros(shape=(3, 3), dtype=bool)
ps -eo 'user,pid,command' | grep -E "`nvidia-smi -q -d "PIDS" | grep 'Process ID' | awk '{print $4}' | paste -sd '|'`"