This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import sys | |
import numpy as np | |
import cv2 as cv | |
# https://i.imgur.com/sRY2qCG.png | |
im = cv.imread("sRY2qCG.png") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import sys | |
import argparse | |
import numpy as np | |
import cv2 as cv | |
def draw_pattern(a, grain=1, tiled=False): | |
global ix, iy, gx, gy |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
udp://tracker.leechers-paradise.org:6969/announce | |
udp://9.rarbg.me:2710/announce | |
udp://tracker.internetwarriors.net:1337/announce | |
udp://tracker.opentrackr.org:1337/announce | |
udp://tracker.coppersurfer.tk:6969/announce | |
udp://tracker.pirateparty.gr:6969/announce |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <opencv2/core.hpp> | |
#include <opencv2/imgcodecs.hpp> | |
#include <opencv2/highgui.hpp> | |
#include <iostream> | |
using namespace cv; | |
// [ x64 Native Tools Command Prompt for VC 2019 ] | |
// or | |
// > "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\vc\Auxiliary\Build\vcvarsall.bat" x64 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import sys | |
import pprint; pp = pprint.pprint | |
# usage: script.py *.fastresume | |
# on files in %HOME%\AppData\Local\qBittorrent\BT_backup or wherever else they're stored | |
try: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import sys | |
import pprint; pp = pprint.pprint | |
triangle = [ | |
[int(num) for num in line.split()] | |
for line in open('p67-triangle.txt') | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name worldometers centered averages | |
// @match https://www.worldometers.info/coronavirus/country/*/ | |
// @grant unsafeWindow | |
// @run-at document-start | |
// ==/UserScript== | |
// polyfill for onbeforescriptexecute event handler | |
// https://github.com/jspenguin2017/Snippets/tree/master | |
// Library code, licensed under MIT |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import sys | |
import numpy as np | |
import cv2 as cv | |
def translation(tx, ty): | |
result = np.eye(3) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import sys | |
import numpy as np | |
from scipy.interpolate import interp1d, interp2d | |
np.set_printoptions(suppress=True, linewidth=120) | |
k = 10 | |
source1d = np.float64([0]*(2*k-1) + [1]*(2*k-1)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import sys | |
import numpy as np | |
import cv2 as cv | |
from scipy.interpolate import interp2d | |
def build_transform(p0, p1, stride=None, nsamples=None): | |
"builds an affine transform with x+ along defined line" | |
# use one of stride (in pixels) or nsamples (absolute value) |