Skip to content

Instantly share code, notes, and snippets.

View josezy's full-sized avatar
🌮
Loving tacos

Jose josezy

🌮
Loving tacos
View GitHub Profile
@pirate
pirate / music_in_screenshots.py
Created January 12, 2024 14:43
Automatically detect song/video title/artist/album/metadata captured in screenshots using GPT-4-vision via the OpenAI API.
#!/usr/bin/env python3
# Script to extract song/video title, artist, album, etc. metadata from screenshots w/ GPT-4.
### Example Usage: ###############################################################################
#
# ➜ ~/Desktop # python3 music_in_screnshots.py --prompt=prompt.txt --attach=spotify_screenshot.PNG
# {
# "found_prominent_media": true,
# "all_strings": [
@ES-Alexander
ES-Alexander / mavactive.py
Last active May 11, 2024 16:55
An example of using `RC_OVERRIDE`s for basic vehicle control with Pymavlink. Includes a variety of other convenience functions.
from builtins import object
import weakref
from time import sleep
from threading import Thread, Event, Lock
from pymavlink import mavutil
import pymavlink.dialects.v20.ardupilotmega as mavlink
class WriteLockedFile(object):
@jotathebest
jotathebest / peopleCounter.py
Last active July 12, 2022 13:07
Pedestrian detector that sends people counter results to Ubidots. Libraries: OpenCV, requests, imutils
from imutils.object_detection import non_max_suppression
import numpy as np
import imutils
import cv2
import requests
import time
import argparse
import time
import base64
@vo
vo / listener.py
Created March 5, 2014 07:02
Quick hack to position hold with MAVLink using external webcam
#!/usr/bin/env python
import sys, os, socket, pickle
from time import time
from optparse import OptionParser
UDP_IP = "127.0.0.1"
UDP_PORT = 31200
# tell python where to find mavlink so we can import it