Skip to content

Instantly share code, notes, and snippets.

View asmith26's full-sized avatar
😎
Always Learning

asmith26

😎
Always Learning
View GitHub Profile
@simecek
simecek / Map+Your+Twitter+Followers.ipynb
Last active August 7, 2021 05:35
Map your Twitter followers
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
import requests
import csv
import datetime
import calendar
import time
i=0
# Change the range depending on how long you like to record the data
for i in range (0,50):
@bnutz
bnutz / nexus5X_bootloop_fix_sequence.md
Last active April 28, 2024 19:05
Procedure used for working around Nexus 5X bootloop issue

Just documenting my own experiences in restoring my Nexus 5X back from bootlooping state.

Hopefully this can be helpful to some, but "common sense" caveats apply:

  • Follow at your own risk
  • I'm not responsible for any loss of data, loss of hair, bricked devices, exploding(!) devices, mental / physical injuries, etc. etc. etc.

Remember:

  • This is only an account of what I did to get my 5X working operational again.
  • YMMV if you decide to try the steps below on your bootlooping device.
@nygeog
nygeog / csv-to-shapefile-geopandas.py
Last active November 25, 2023 09:47
Read a CSV with Pandas and set as GeoDataFrame with geopandas and save as Shapefile with fiona
import pandas as pd
from geopandas import GeoDataFrame
from shapely.geometry import Point
import fiona
df = pd.read_csv('data.csv')
geometry = [Point(xy) for xy in zip(df.x, df.y)]
crs = {'init': 'epsg:2263'} #http://www.spatialreference.org/ref/epsg/2263/
geo_df = GeoDataFrame(df, crs=crs, geometry=geometry)
@davidvasandani
davidvasandani / gist:e9508512d66825cbff7af2d57b69c0f2
Last active February 26, 2024 11:14
Learning How to Learn notes
Learning How To Learn
Module 1 - What is Learning
Focused/Diffuse Modes Thinking
- Obviously ‘focused’ is when you’re concentrating. Direct approach to solving familiar problems.
- Focused: thoughts move through nicely-paved road of familiar notions (neural pattern looks very tight and directed).
- encompasses rational, sequential, analytical approaches to thinking
- Diffuse: More of a search function neural pattern. Thoughts move widely. More of a broad/big-picture perspective trying to connect ideas from different places.
- We’re always either in focused or diffuse mode of thinking.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@fchollet
fchollet / classifier_from_little_data_script_3.py
Last active September 13, 2023 03:34
Fine-tuning a Keras model. Updated to the Keras 2.0 API.
'''This script goes along the blog post
"Building powerful image classification models using very little data"
from blog.keras.io.
It uses data that can be downloaded at:
https://www.kaggle.com/c/dogs-vs-cats/data
In our setup, we:
- created a data/ folder
- created train/ and validation/ subfolders inside data/
- created cats/ and dogs/ subfolders inside train/ and validation/
- put the cat pictures index 0-999 in data/train/cats
@fchollet
fchollet / classifier_from_little_data_script_2.py
Last active September 13, 2023 03:34
Updated to the Keras 2.0 API.
'''This script goes along the blog post
"Building powerful image classification models using very little data"
from blog.keras.io.
It uses data that can be downloaded at:
https://www.kaggle.com/c/dogs-vs-cats/data
In our setup, we:
- created a data/ folder
- created train/ and validation/ subfolders inside data/
- created cats/ and dogs/ subfolders inside train/ and validation/
- put the cat pictures index 0-999 in data/train/cats
@karpathy
karpathy / pg-pong.py
Created May 30, 2016 22:50
Training a Neural Network ATARI Pong agent with Policy Gradients from raw pixels
""" Trains an agent with (stochastic) Policy Gradients on Pong. Uses OpenAI Gym. """
import numpy as np
import cPickle as pickle
import gym
# hyperparameters
H = 200 # number of hidden layer neurons
batch_size = 10 # every how many episodes to do a param update?
learning_rate = 1e-4
gamma = 0.99 # discount factor for reward
@EderSantana
EderSantana / CATCH_Keras_RL.md
Last active October 16, 2023 08:32
Keras plays catch - a single file Reinforcement Learning example