This file contains 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
import time | |
from collections import deque | |
import numpy as np | |
import sounddevice as sd | |
from beepy import beep | |
from infi.systray import SysTrayIcon | |
last_alert = time.time() - 10 | |
q = deque(maxlen=200) |
This file contains 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 typing import Union, Iterable, Optional, List | |
import spacy | |
from prodigy import recipe, get_stream | |
from prodigy.models.matcher import PatternMatcher | |
from prodigy.types import RecipeSettingsType | |
from prodigy.util import get_labels | |
@recipe( |
This file contains 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
import copy | |
from typing import Union, Iterable, Optional, List | |
import spacy | |
from prodigy import recipe, log, get_stream | |
from prodigy.models.matcher import PatternMatcher | |
from prodigy.types import RecipeSettingsType | |
from prodigy.util import get_labels | |
This file contains 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
[package] | |
name = "rust_crawler" | |
version = "0.1.0" | |
authors = ["Roland Szabo <[email protected]>"] | |
edition = "2018" | |
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |
[dependencies] | |
reqwest = { version = "0.10", features = ["json", "blocking"] } |
This file contains 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 subprocess import Popen, PIPE | |
import os | |
import time | |
import sys | |
def compute_stats(): | |
all_gpu = [] | |
all_mem = [] | |
for i in range(10): | |
p = Popen(["nvidia-smi","--query-gpu=utilization.gpu,utilization.memory", "--format=csv,noheader,nounits"], stdout=PIPE) |
This file contains 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
import numpy as np | |
from numpy.random import random as rand | |
class NeuralNetwork: | |
activations = { | |
'tanh': lambda x: np.tanh(x), | |
'relu': lambda x: np.clip(x, 0, np.max(x)) | |
} | |
derivatives = { |
This file contains 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
__author__ = 'Roland' | |
import copy | |
class avl: | |
def __init__(self,value = None,left = None,right = None,parent = None): | |
self.value = value | |
self.left = left | |
self.right = right | |
self.parent = parent |
This file contains 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
(defun inserare(el l) | |
(cond | |
((null l) nil) | |
(t (mapcar (lambda (x) (cons el x)) l)) | |
) | |
) | |
(defun permutare(l) | |
(cond | |
((null l) '(())) |
This file contains 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 multiprocessing import Pool | |
__author__ = 'Roland' | |
from PIL import Image | |
#size of image | |
imgx = 600 | |
imgy = 400 | |
#make image buffer | |
image = Image.new("RGB", (imgx, imgy)) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
NewerOlder