Skip to content

Instantly share code, notes, and snippets.

Avatar
❤️
友利奈緒

Melon Melanpan

❤️
友利奈緒
View GitHub Profile
@Melanpan
Melanpan / YandereImageDownload.py
Created Jul 17, 2015
Download images from yande.re or konachan.com, only when the aspect ratio is 16:9 and the image is 1080p or above
View YandereImageDownload.py
import requests
import os
import sys
def downloadPostJson(limit=10000, page=0, tag="", board="konachan.com"):
url = "https://%s/post.json?tags=%s&limit=%s&page=%s" % (board, tag, limit, page)
r = requests.get(url)
if len(r.content) >= 1:
return r.json()
View autoEncoder.py
#!/usr/bin/python3.5
import os
import subprocess
import json
import pyinotify
import time
import logging
class autoEncoder():
View mpd_icecast_update.py
"""
Small script that syncs the current now playing (MPD) with Icecast
By Melan
"""
import time
import os
import requests
from mpd import MPDClient
View udp_vu.py
import socket
import struct
import pyaudio
import wave
import audioop
import math
UDP_IP = "192.168.3.4"
UDP_PORT = 5000
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
View pixelflut.py
import socket
import struct
import logging
from PIL import Image
class PixelClient():
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
buffer = []
log = logging.getLogger("pixelclient")
View gameboy_pixelflut.py
import sys
import cv2
import struct
import numpy as np
import socket
from pyboy import PyBoy
pyboy = PyBoy(sys.argv[1],debugging=False,disable_input=False,hide_window="--quiet" in sys.argv)
pyboy.set_emulation_speed(1)
View gist:c87bfa16dc1edb02a674ac84858f3d80
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <unistd.h>
#include <string.h>
#include <math.h>
#include <errno.h>
#include <signal.h>
#include <pulse/simple.h>
#include <pulse/error.h>