Skip to content

Instantly share code, notes, and snippets.

View loisaidasam's full-sized avatar
🙌
🙌

Loisaida Sam loisaidasam

🙌
🙌
View GitHub Profile
@loisaidasam
loisaidasam / README.md
Created September 29, 2022 15:58
Pitchfork - The 250 Best Songs of the 1990s - in a plaintext list
@loisaidasam
loisaidasam / 0-README.md
Last active June 29, 2021 09:46
La Vuelta event-stream updates
@loisaidasam
loisaidasam / VOTE_ATLANTA.md
Created June 3, 2020 17:38
Atlanta Early Voting Locations
@loisaidasam
loisaidasam / story.ipynb
Created May 1, 2020 03:55
Story about numpy ndarrays with nested sequences
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@loisaidasam
loisaidasam / results.txt
Last active February 12, 2020 21:12
Python: setattr() vs. direct object manipulation
$ python test_setattr.py
test_setattr 0.11335835400000001
test_direct_object_manipulation 0.04550438199999998
$ python test_setattr_data_types.py
int
setattr() 0.104297199
direct obj manipulation 0.046985358000000005
float
setattr() 0.097025698
@loisaidasam
loisaidasam / README.md
Created January 31, 2020 20:45
How often can we celebrate someone's birthday in the office?

Given a certain amount of employees in an office, how many weeks of the year should it be reasonable to celebrate birthdays?

Assumptions:

  • there are ~200 employees in this office
  • there are 52 weeks in the year
  • there is an equal probability of each employee being born on any of the 52 weeks

Here are 20 trials:

@loisaidasam
loisaidasam / README.md
Last active December 2, 2019 19:07
Bookmarklet: Strava - Open Group Activities

Bookmarklet: Strava - Open Group Activities

In Strava, when you go on a bike ride with other folks, it groups your activities together.

Use this bookmarklet to open up the activities of all of the other people you rode bikes with in separate tabs.

To create the bookmarklet

  • Create a new browser bookmark
  • For location, paste in the contents of bookmarklet.js
@loisaidasam
loisaidasam / dcoms.csv
Last active November 18, 2019 15:48
The 103 DCOMs now available on Disney+, scraped from https://www.buzzfeed.com/laurengarafano/disney-plus-dcoms using `pup`
title year
Adventures in Babysitting 2016
Alley Cats Strike 2000
Avalon High 2010
Bad Hair Day 2015
Brink! 1998
Buffalo Dreams 2005
Cadet Kelly 2002
Camp Rock 2008
Camp Rock 2: The Final Jam 2010
@loisaidasam
loisaidasam / nytimes-xword-scrape.py
Created October 20, 2019 19:44
Grab the latest NY Times Crossword puzzle
#!/usr/bin/env python
"""Grab the latest NY Times Crossword puzzle
TODO: Figure out how to get today's puzzle - for some reason this grabs yesterday's
"""
import os
import re
import time
@loisaidasam
loisaidasam / picblast.sh
Last active August 2, 2019 15:07 — forked from bwhitman/picblast.sh
Make an audio collage out of your live photos
#!/bin/bash
mkdir /tmp/picblast
cd ~/Pictures/Photos\ Library.photoslibrary
for i in $(find . | grep jpegvideocompl)
do
ffmpeg -i $i /tmp/picblast/${i:(-8)}.wav
done