Skip to content

Instantly share code, notes, and snippets.

@NelsonMinar
NelsonMinar / README.md
Created January 31, 2024 14:11
League of Legends rank data 2016
@NelsonMinar
NelsonMinar / README.txt
Created January 20, 2022 18:59
Solar monitoring setup: PVS6, PGE, forecast.solar to Influx
Data imports for a custom solar monitoring system I build using Sunpower's PVS6, Telegraf, Influx, and Grafana.
See http://nelsonslog.wordpress.com/ for details
This code is provided without license or support. If you do something interested and related let me know!
--nelson@monkey.org
@NelsonMinar
NelsonMinar / hatch.py
Created September 28, 2021 15:08
Hatching algorithm (in progress)
def hatch(polygon, spacing: float = 1, rotation: float = 0, tolerance: float = 5, inset: float = 0) -> shapely.geometry.MultiLineString:
"""
Fill a polygon with hatched lines.
Note this code is unit-independent. The default spacing of 1 was chosen with the idea of the units being
millimeters and the pen width being 0.5mm, for a 50% fill.
:param polygon: the shape to generate a hatch for
:param spacing: space between hatch lines
:param rotation: rotation of hatch lines (in degrees)
:param tolerance: limit on length of joining lines to make hatches a single line. Multiples of spacing.
@NelsonMinar
NelsonMinar / Torena Somnopose Oscar convertor
Last active August 4, 2023 10:40
Torena to Somnopose data convertor for OSCAR
Notes:
https://nelsonslog.wordpress.com/2021/07/21/sleep-position-tracking-and-oscar/
http://www.apneaboard.com/forums/Thread-Torena-sleep-position-monitor-for-Android-similar-to-SomnoPose
<opml version="1.0" xmlns:fz="urn:forumzilla:">
<head>
<title>Metafilter user blogs https://metatalk.metafilter.com/24654/Who-Are-The-Bloggers-of-Metafilter</title>
<dateCreated>Sat, 20 Jan 2018 21:49:01 GMT</dateCreated>
</head>
<body>
<outline type="rss" title="Amor Bellator" text="Amor Bellator" version="RSS" xmlUrl="https://amorbellator.com/feed/" htmlUrl="https://amorbellator.com"/>
<outline type="rss" title="Boxer Indemnity Scholars" text="Boxer Indemnity Scholars" version="RSS" xmlUrl="https://boxerindemnityscholars.wordpress.com/feed/" htmlUrl="https://boxerindemnityscholars.wordpress.com"/>
<outline type="rss" title="Best Results Organizing" text="Best Results Organizing" version="RSS" xmlUrl="http://juliebestry.com/feed/" htmlUrl="http://juliebestry.com"/>
<outline type="rss" title="mike.whybark.com" text="mike.whybark.com" version="RSS" xmlUrl="http://mike.whybark.com/feed" htmlUrl="http://mike.whybark.com"/>
@NelsonMinar
NelsonMinar / index.html
Last active February 10, 2018 12:06
Demo of using Mocha + Chai in a browser without Node
<html>
<head>
<meta charset="utf-8">
<title>Mocha Tests</title>
<link href="https://cdnjs.cloudflare.com/ajax/libs/mocha/5.0.0/mocha.css" rel="stylesheet" />
</head>
<body>
<div id="mocha"></div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/mocha/5.0.0/mocha.js"></script>
@NelsonMinar
NelsonMinar / idb-walk.py
Created January 11, 2018 19:02
IndexedDB database file walker for Firefox
#!/usr/bin/env python3.6
"""
Hacky code to walk all the IndexedDB storage in your Firefox profile
and print some basic information about them.
The hardcoded path here works in WSL, Linux-for-Windows. Change as needed.
"""
base_dir = '/mnt/c/Users/*/AppData/Roaming/Mozilla/Firefox/Profiles/*/storage/default/'
@NelsonMinar
NelsonMinar / Sigmoid hidden layer.ipynb
Created January 6, 2018 02:17
TensorFlow MNIST sigmoid recognizer
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@NelsonMinar
NelsonMinar / scrape.ipynb
Created November 28, 2017 00:21
Demo of using IPython with BeautifulSoup
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.