Skip to content

Instantly share code, notes, and snippets.

@nathzi1505
nathzi1505 / opencv-4.2.0-cuda-10.1-Ubuntu-20.04.md
Last active February 3, 2023 01:51
Step-by-Step Guide to build OpenCV 4.2.0 with CUDA 10.1 on Ubuntu 20.04
View opencv-4.2.0-cuda-10.1-Ubuntu-20.04.md

How to install OpenCV 4.2.0 with CUDA 10.1 on Ubuntu 20.04 LTS (Focal Fossa)

Install updates and upgrade your system:

    $ sudo apt update
    $ sudo apt upgrade

Install required libraries:

@hzlzh
hzlzh / weixin-menu-post.py
Last active January 20, 2016 03:07
WeiXIn Menu Post
View weixin-menu-post.py
# encoding: utf-8
import json
import urllib
import urllib2
appid = ""
secret = ""
access_url = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=%s&secret=%s"
menu_url = "https://api.weixin.qq.com/cgi-bin/menu/create?%s"
@CatTail
CatTail / htmlentity.js
Created November 30, 2012 08:27
Javascript: encode(decode) html text into html entity
View htmlentity.js
// encode(decode) html text into html entity
var decodeHtmlEntity = function(str) {
return str.replace(/&#(\d+);/g, function(match, dec) {
return String.fromCharCode(dec);
});
};
var encodeHtmlEntity = function(str) {
var buf = [];
for (var i=str.length-1;i>=0;i--) {