Skip to content

Instantly share code, notes, and snippets.

View Siunami's full-sized avatar

Matthew Siu Siunami

View GitHub Profile

Why read books when you can learn things the hard way? Because good books are written by people with experience, people who learnt from their mistakes. No point in comitting the same mistakes and learning from them, when you can read a book and do better. Be better informed so that you make mistakes that very few have yet to come across.

HTML, CSS & JavaScript

Learn

Starting with the best introductory books to HTML, CSS & JS by Jon Duckett, just so that I am not caught unaware by any unexpected JS in the other books. Then moving on to the high quality publishers of content on Web Design, because as a beginner I should be learning from the best. Then everything else, keeping in mind that even if I learn just one thing that's extremely useful or thoughtful from an entire book, that's still great.

  1. HTML and CSS: Design and Build Websites by Jon Duckett (Official Site)
  2. JavaScript and JQuery: Interactive Front-End Web Development by Jon Duckett ([Official Site]
@impshum
impshum / stats.py
Created December 23, 2017 00:39
Get mongodb stats using python with pymongo
from pymongo import MongoClient
try:
client = MongoClient('localhost')
db = client.searchfollow
except:
print("Could not connect to MongoDB")
call = db.command("dbstats")
@zackschuster
zackschuster / links.md
Last active March 13, 2019 21:19
@MylesBorins academic links 1 July 2017
@aparrish
aparrish / understanding-word-vectors.ipynb
Last active July 27, 2024 14:45
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7) Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@aparrish
aparrish / spacy_intro.ipynb
Last active July 29, 2024 21:03
NLP Concepts with spaCy. Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
/*
Created by Matthew Siu on 2017-1-17.
http://www.matthewsiu.com/
https://github.com/Siunami
https://www.linkedin.com/in/matthewwilsonsiu
*/
// BEGIN WITH PIN 5
// This can be changed to any starting values desired
int pinState[10] = {LOW, LOW, LOW, LOW, HIGH, LOW, LOW, LOW, LOW, LOW};
@dannguyen
dannguyen / README.md
Last active July 6, 2024 16:36
Using Python 3.x and Google Cloud Vision API to OCR scanned documents to extract structured data

Using Python 3 + Google Cloud Vision API's OCR to extract text from photos and scanned documents

Just a quickie test in Python 3 (using Requests) to see if Google Cloud Vision can be used to effectively OCR a scanned data table and preserve its structure, in the way that products such as ABBYY FineReader can OCR an image and provide Excel-ready output.

The short answer: No. While Cloud Vision provides bounding polygon coordinates in its output, it doesn't provide it at the word or region level, which would be needed to then calculate the data delimiters.

On the other hand, the OCR quality is pretty good, if you just need to identify text anywhere in an image, without regards to its physical coordinates. I've included two examples:

####### 1. A low-resolution photo of road signs

@vasanthk
vasanthk / System Design.md
Last active July 30, 2024 00:17
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@JJediny
JJediny / gist:a466eed62cee30ad45e2
Created October 5, 2015 20:42
Jekyll Liquid Cheatsheet

There are two types of markup in Liquid: Output and Tag.

  • Output markup (which may resolve to text) is surrounded by
{{ matched pairs of curly brackets (ie, braces) }}
  • Tag markup (which cannot resolve to text) is surrounded by
@staltz
staltz / introrx.md
Last active July 29, 2024 05:55
The introduction to Reactive Programming you've been missing