Skip to content

Instantly share code, notes, and snippets.

View dioptx's full-sized avatar

Dionisis Pettas dioptx

View GitHub Profile
- [x] inverted dropout
- [x] goldilocks ideal rate // bullshit
- [x] shannons entropy measure // good one
- [x] harmonic mean
- [x] beta distribution
- [x] gamma function
- [x] bias correction of exponentially weighted average
- [x] covariate shifting computer vision
- [x] why use strided convolution
- [x] selu
import warnings
# loaded config
lstm_conf = {
'WINDOW_SIZE' : 15,
'NUM_OF_FEATURES': 42,
'LABEL_LENGTH': 4,
'BATCH_SIZE': 25,
import os, shutil, urllib
# Settings
number_of_shops = 100
number_of_places = 30
images_per_shop = 5
extension = '.jpg'
dimentions = {
'thumbnail': (140, 140),
@dioptx
dioptx / index_creator.py
Last active April 14, 2019 16:12
index.js creation with Python from a dynamic asset structure
from pathlib import Path
from pprint import pprint
import os, json
root_path = Path('YOUR_ROOT_PATH')
assets = {}
def add_to_dict(root_dict, components, path_to_root):
import logging
from logging.handlers import RotatingFileHandler
import inspect
def create_rotating_log():
'''
Creates a rotating logger function
:return:
'''
logger = logging.getLogger(_settings.Name)
@dioptx
dioptx / send.js
Created December 27, 2018 10:14
Code supposed to send 1 iota to test address
const Iota = require('@iota/core');
const Converter = require('@iota/converter');
const iota = Iota.composeAPI({
provider: 'https://nodes.devnet.iota.org:443'
});
iota.getNodeInfo()
.then(info => console.log(info))
.catch(err => {});