Skip to content

Instantly share code, notes, and snippets.

Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@izderadicka
izderadicka / tf.ipynb
Created July 29, 2016 09:54
TensorFlow tutorial
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@izderadicka
izderadicka / check.py
Created November 29, 2015 07:58
Check if point is inside triangle
import matplotlib.pyplot as lpt
import numpy as np
def pt(data, point=None):
p = plt.Polygon(data, closed=True, fill=None)
ax = plt.gca()
ax.add_patch(p)
x=data[:,0]
y=data[:,1]
if point:
@izderadicka
izderadicka / calc.py
Last active November 28, 2015 15:18
Calculate number of Fridays 13th between given dates - effective algorithm
'''
Created on Nov 28, 2015
@author: ivan
'''
from datetime import date, timedelta
from copy import copy
import pprint
@izderadicka
izderadicka / megaback.sh
Last active February 7, 2022 04:53
backup script for megatools
#!/bin/bash
BACKUP_DIR="/Root/Backup/"
PIECE_SIZE=10M
ACTION=store
trap "exit 2" SIGINT
if [[ $1 =~ -h|--help ]]; then