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
class ParadoxicalEncoder: | |
def __init__(self): | |
self.classes = set() | |
self.encodings = {} | |
def _updte_encodings(self, label): | |
try: | |
enc = self.encodings[label] | |
except KeyError: | |
self.encodings[label] = len(self.encodings)+1 |
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
wget --load-cookies /tmp/cookies.txt "https://docs.google.com/uc?export=download&confirm=$(wget --quiet --save-cookies /tmp/cookies.txt --keep-session-cookies --no-check-certificate 'https://docs.google.com/uc?export=download&id=FILE_ID' -O- | sed -rn 's/.*confirm=([0-9A-Za-z_]+).*/\1\n/p')&id=FILE_ID" -O FILENAME && rm -rf /tmp/cookies.txt |
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
""" | |
Required modules/libraries: | |
- falcon | |
- falcon-cors | |
- falcon-multipart | |
- gunicorn | |
TO run the api: | |
gunicorn -b ip:port api:app |
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
import os | |
import cv2 | |
from shutil import copyfile | |
from random import randint,shuffle | |
import string | |
def create_dir(path): | |
if not os.path.exists(path): | |
os.makedirs(path) |
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
#include <stdio.h> | |
#include <stdlib.h> | |
/* 1 2 3 5 | |
3 4 5 6 | |
6 7 8 7 | |
2 3 4 5 | |
*/ | |
int deterstandard(const int order,int **matrix) | |
{ | |
int i,j,k,val=0; |
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
#!/usr/bin/env python3 | |
from abc import ABC, abstractmethod | |
class Base(ABC): | |
def __init__(self, val): | |
super().__init__() | |
self.val = val | |
@abstractmethod |
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
ZERO_WIDTH_JOINER = '\u200d' | |
ZERO_WIDTH_SPACE = '\u200b' | |
ZERO_WIDTH_NON_JOINER = '\u200c' | |
ZERO_WIDTH_NO_BREAK_SPACE = '\ufeff' | |
def zeropad(num, padding=8): | |
return str(num).zfill(padding) | |
def num_to_binary(num): | |
return bin(num)[2:] |
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
#!/usr/bin/env python3 | |
from bs4 import BeautifulSoup | |
import requests | |
def check_user(username): | |
url = "https://www.instagram.com/{}".format(username) | |
response = requests.get(url) | |
status_code = response.status_code |
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
# Install the PyDrive wrapper & import libraries. | |
# This only needs to be done once in a notebook. | |
!pip install -U -q PyDrive | |
from pydrive.auth import GoogleAuth | |
from pydrive.drive import GoogleDrive | |
from google.colab import auth | |
from oauth2client.client import GoogleCredentials | |
# Authenticate and create the PyDrive client. | |
# This only needs to be done once in a notebook. |
We can't make this file beautiful and searchable because it's too large.
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
text,opn,con,ext,agr,neu | |
likes the sound of thunder.,1,0,0,0,1 | |
is so sleepy it's not even funny that's she can't get to sleep.,1,0,0,0,1 | |
"is sore and wants the knot of muscles at the base of her neck to stop hurting. On the other hand, YAY I'M IN ILLINOIS! <3",1,0,0,0,1 | |
likes how the day sounds in this new song.,1,0,0,0,1 | |
is home. <3,1,0,0,0,1 | |
www.thejokerblogs.com,1,0,0,0,1 | |
"saw a nun zombie, and liked it. Also, *PROPNAME* + Tentacle!Man + Psychic Powers = GREAT Party.",1,0,0,0,1 | |
is in Kentucky. 421 miles into her 1100 mile journey home.,1,0,0,0,1 | |
was about to finish a digital painting before her tablet went haywire. Is now contemplating the many ways she wishes to exact her revenge on faulty technology.,1,0,0,0,1 |