Skip to content

Instantly share code, notes, and snippets.

@sde1000
sde1000 / demo-undefer-group.py
Created August 20, 2017 14:16
undefer_group() sqlalchemy problem
from sqlalchemy import create_engine
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import Column, Integer, ForeignKey, Numeric
from sqlalchemy.schema import Sequence, MetaData
from sqlalchemy.sql.expression import text
from sqlalchemy.orm import sessionmaker
from sqlalchemy.orm import relationship, backref, column_property
from sqlalchemy.orm import defaultload, joinedload
from sqlalchemy.sql import select, func
@sde1000
sde1000 / split-P60s.py
Created April 12, 2017 09:57
P60 file split script
#!/usr/bin/env python3
from PyPDF2 import PdfFileWriter, PdfFileReader
from PyPDF2.pdf import ContentStream
payroll_number_loc = (430.86600, 727.19200)
if __name__ == "__main__":
input = PdfFileReader(open("bulk_P60s.pdf", "rb"))
Failing source addresses/ports:
2a02:8011:4008:1:5cfb:619a:2af5:21eb.35743
Succeeding source addresses/ports:
2a02:8011:4008:1:bdd8:5366:82b8:3e19.32856
@sde1000
sde1000 / flacsplit.py
Created October 17, 2013 10:01
Script to split flac files with embedded cue sheet and tags into mp3s
#!/usr/bin/env python
"""Split a flac file with cuesheet and embedded tags into multiple
files, optionally re-encoded as mp3.
"""
version="0.1"
import os,subprocess,re,os.path,sys
@sde1000
sde1000 / panel.pcb
Created July 25, 2012 13:34
Front panel layout; laser cuts in 'top' layer
# release: pcb 20110918
# To read pcb files, the pcb version (or the git source date) must be >= the file version
FileVersion[20070407]
PCB["Front panel" 633858 511811]
Grid[1968.0 0 0 1]
Cursor[316848 218448 0.000000]
PolyArea[3100.006200]