Skip to content

Instantly share code, notes, and snippets.

View jamjar919's full-sized avatar

James Paterson jamjar919

View GitHub Profile
I am attesting that this GitHub handle jamjar919 is linked to the Tezos account tz1XySYcNvmWY4upC2WQYAYofVXAZP8DHh3Q for tzprofiles
sig:edsigtYc6gS3VeNvLVWea4Gf3tu74tBtuEMB5jdDg2jV8Rm2b36o3EEhMCLuCBEx3bHNoohW8Lt62Lsm8Ji7SNMHjBjkT1S79f3
@jamjar919
jamjar919 / peepshowepisodes.json
Created December 9, 2018 15:25
Episodes of Peep Show in JSON format.
[
{
"EpisodeNumber": "1",
"EpisodeNumber2": "1",
"Title": "Warring Factions",
"DirectedBy": "Jeremy Wooding",
"WrittenBy": "Jesse Armstrong & Sam Bain",
"ShortSummary": "We are introduced to twenty-something Croydon flatmates Mark: a history-loving office worker who has a crush on his colleague Sophie – and Jez: a lazy, unemployment in the United Kingdom unemployed, would-be musician who lives in the same flat and leeches off him. The two men are competing to try to become their unhappily married next-door neighbour Toni's fuck buddy. We follow them to a party at Toni's, at which Mark fails in his attempt to seduce her while talking to her about the Battle of Stalingrad. Meanwhile, Jez meets her sister – whom he erroneously believes has leukaemia because she has another sister who has the disease. After this misunderstanding causes an argument, Mark and Jez are told by Toni's husband, Tony, to leave. During the next day, Mark picks up a metal pole that had been discarded in the stree
@jamjar919
jamjar919 / countmessages.rb
Created April 11, 2018 20:33
Example MVE for facebook messenger counter
require 'nokogiri'
require 'axlsx'
catalog = ARGV[0]
user_name = Nokogiri::HTML(File.open("#{catalog}/index.htm")).title.split(' - Profile')[0]
friends = Hash.new
Dir.chdir("#{catalog}/messages") do
messages_files = Dir.glob("*.html")
@jamjar919
jamjar919 / skeletonintersection.py
Created July 22, 2017 12:14
Skeleton intersection code for
def getSkeletonIntersection(skeleton):
""" Given a skeletonised image, it will give the coordinates of the intersections of the skeleton.
Keyword arguments:
skeleton -- the skeletonised image to detect the intersections of
Returns:
List of 2-tuples (x,y) containing the intersection coordinates
"""
# A biiiiiig list of valid intersections 2 3 4
<?php
session_start();
/* * * * * * * * * * * * * * * * * * * * * * * *
*
* DATE AND TIME
*
@jamjar919
jamjar919 / unigrams.json
Last active January 9, 2017 18:23
Json file of unigrams from twitter linked to sentiment scores
This file has been truncated, but you can view the full file.
{
"great":2,
"gr8":2,
"good":1,
"love":2,
"like":1,
":-)":2,
"terrible":-2,
"bad":-1,
"hate":-2,