Skip to content

Instantly share code, notes, and snippets.

View Power Limit for Nvidia GPUs
#set persistence mode for all GPU
sudo nvidia-smi -pm 1
#Set gpu max power at 160w
sudo nvidia-smi -pl 160
#Set Power level of specific GPU (1080) in watts
# sudo nvidia-smi -i 2 -pl 200
divinity76 / process-mysqldump.c
Last active Jul 10, 2018 — forked from lavoiesl/process-mysqldump.c
Add newlines before parenthesis for a SQL mysqldump
View process-mysqldump.c
// gcc -O2 -Wall -pedantic process-mysqldump.c -o process-mysqldump
// Usage: cat dump.sql | process-mysqldump
// Or : process-mysqldump dump.sql
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
#define BUFFER 100000
View GetModuleBaseAddress.cpp
#include <iostream>
#include <windows.h>
#include <Tlhelp32.h.>
using namespace std;
int main()
HANDLE h= CreateToolhelp32Snapshot(8, 780);
throw std::runtime_error("CreateToolhelp32Snapshot failed, returning INVALID_HANDLE_VALUE");
View sh-ignore.js
forked from Mr. Pengi's, and added fallback to cookies if localStorage is not available,
also fixed a few exceptions that would rise if localStorage is not available
var ignores = null;
var replacementtext = "<td align='left' bgcolor='444444'>This post has been ignored</td>";
$(document).ready(function () {