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
from fabric.api import env, execute, lcd, task, settings | |
from fabric.decorators import runs_once, parallel | |
env.roledefs = { | |
'foo': ['bar1', 'bar2', 'bar3'] | |
} | |
class FabricAbortException(Exception): | |
pass |
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
# strip out iBooks citation | |
sed -E -e 's/^[ ]?[0-9]* //g' | sed -E -e 's/«[ ]?[0-9]?[ ]?//g' | sed -E -e 's/»$//g' | sed -E -e 's/^(Отрывок из книги).*//g' |
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
# coding: utf-8 | |
import json | |
import re | |
import human_curl as hurl | |
try: | |
from urllib.parse import urlencode, urljoin | |
except ImportError: |
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
{% load staticfiles %} | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<style type="text/css"> | |
@font-face { | |
font-family: 'robotoregular'; | |
src: url(data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAAE7wAA8AAAAAfWQAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABGRlRNAAABWAAAABwAAAAcZ5vbxEdERUYAAAF0AAAAHgAAAB4AJwGVT1MvMgAAAZQAAABRAAAAYLihUHljbWFwAAAB6AAAAeIAAANmxa/pEWN2dCAAAAPMAAAABAAAAAQARAURZ2FzcAAAA9AAAAAIAAAACAAAABBnbHlmAAAD2AAAPNcAAF9A5fsspWhlYWQAAECwAAAAMQAAADYGDO5CaGhlYQAAQOQAAAAhAAAAJAxmBqdobXR4AABBCAAABCUAAAY8ObKDomxvY2EAAEUwAAADCgAAAyA3Jk+0bWF4cAAASDwAAAAfAAAAIAGgAOBuYW1lAABIXAAAAbUAAAOQMAuLK3Bvc3QAAEoUAAAE0gAAC6abmAiwd2ViZgAATugAAAAGAAAABqFXVUYAAAABAAAAANE/eMAAAAAAxPARLgAAAADRbFHVAAEAAAAMAAAAFgAAAAIAAQABAY4AAQAEAAAAAgAAAAB42mNgZjnOOIGBlYGFdRarMQMDozyEZr7IkMbEgAweMDD9D2BQiAYyFUD8gsqiYiDFpPqHjeEfkMGRxBSswMA435+RgYHFinUDWB0jAJwtDhcAAAB42q2SyU8UQRSHv+puUFBEARUQsRgFF9xwB7dxX1FxAxTFlRHc43ph3BG9ePCmHozGBOJ2QBISjUYORM9eDGCkD/IfeLLbRzmjZIgkeqB |
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
from PIL import Image | |
import OpenEXR | |
import Imath | |
import numpy | |
import numexpr as ne | |
FLOAT = Imath.PixelType(Imath.PixelType.FLOAT) | |
def exr_to_array(exrfile): |