just type
pip install opencv-python
in python
import cv2
from flask import Flask | |
from flask import request | |
import json | |
import requests | |
import hashlib as hasher | |
import datetime as date | |
node = Flask(__name__) | |
# Define what a Snakecoin block is | |
class Block: |
# coding=utf8 | |
import PIL | |
from PIL import ImageFont | |
from PIL import Image | |
from PIL import ImageDraw | |
def text2png(text, fullpath, color = "#000", bgcolor = "#FFF", fontfullpath = None, fontsize = 13, leftpadding = 3, rightpadding = 3, width = 200): | |
REPLACEMENT_CHARACTER = u'\uFFFD' | |
NEWLINE_REPLACEMENT_STRING = ' ' + REPLACEMENT_CHARACTER + ' ' |
just type
pip install opencv-python
in python
import cv2
alias wget="curl -O --retry 999 --retry-max-time 0 -C -" | |
## | |
# Line should be placed at ~/.bash_profile | |
# Source: http://www.mymacosx.com/terminal/wget-replacement-macos.html | |
# Source: http://superuser.com/questions/142459/persistent-retrying-resuming-downloads-with-curl | |
## |
Type Option Default regular expression Argument argument-rgx [a-z_][a-z0-9_]{2,30}$ Attribute attr-rgx [a-z_][a-z0-9_]{2,30}$ Class class-rgx [A-Z_][a-zA-Z0-9]+$ Constant const-rgx (([A-Z_][A-Z0-9_])|(__.__))$ Function function-rgx [a-z_][a-z0-9_]{2,30}$ Method method-rgx [a-z_][a-z0-9_]{2,30}$ Module module-rgx (([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$ Variable variable-rgx [a-z_][a-z0-9_]{2,30}$
open -a preview [files..]
""" MODULE images2gif | |
Provides a function (writeGif) to write animated gif from a series | |
of PIL images or numpy arrays. | |
This code is provided as is, and is free to use for all. | |
Almar Klein (June 2009) | |
- based on gifmaker (in the scripts folder of the source distribution of PIL) |
# From https://github.com/wnyc/PIL/blob/master/Scripts/gifmaker.py | |
# | |
# The Python Imaging Library | |
# $Id$ | |
# | |
# convert sequence format to GIF animation | |
# | |
# history: | |
# 97-01-03 fl created | |
# |
ssh -D 8123 -f -C -q -N server