The Getting Things Gnome application is what I'm currently using for David Allen's Getting Things Done self-management method. The application was stagnant for a few years but has recently been revived. The new team has not had the time to catch up the old plugins that synced different computers using Remember The Milk (there may have been others as well?)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import geopandas as gpd | |
import os | |
import requests | |
import shutil | |
# downloading all the ANSI codes for all the states and DC, skipping the territories | |
states_list = requests.get('https://www2.census.gov/geo/docs/reference/state.txt').text.split('\n')[1:52] | |
# states_list should = | |
''' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3d:tessellate -> Tessellate | |
gdal:aspect -> Aspect | |
gdal:assignprojection -> Assign projection | |
gdal:buffervectors -> Buffer vectors | |
gdal:buildvirtualraster -> Build virtual raster | |
gdal:cliprasterbyextent -> Clip raster by extent | |
gdal:cliprasterbymasklayer -> Clip raster by mask layer | |
gdal:clipvectorbyextent -> Clip vector by extent | |
gdal:clipvectorbypolygon -> Clip vector by mask layer | |
gdal:colorrelief -> Color relief |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from shapely.geometry import mapping, LineString | |
from qgis import processing | |
import timeit | |
import fiona | |
SHAPEFILE_DIRECTORY = 'path/to/shapefiles' | |
# create some linestrings to test on | |
scheme = {'geometry': 'LineString', 'properties': []} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
A script for deleting large numbers of duplicates from the output .txt file of | |
the open source Duplciate Files Finder application (https://sourceforge.net/projects/doubles/). | |
Given a list of duplicate files, the one with the shortest path (by character count) | |
is kept and all the rest are deleted. If several have the same length and there are | |
none shorter, then the least "alphabetically" is kept. | |
I used this to reduce a heavily duplicated picture archive from 121Gb to 57Gb. There | |
wasn't really a best way to decide which to delete so the "least path" logic above was |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Just a silly little wkt parser I wrote because for a minute there | |
I thought invalid shapely MultiPolygons were missing the | |
`difference` method if loaded via the `shapely.wkt` module. Turns | |
out it was just a spelling error. :D | |
Not made to be easy to read, sorry. But I thought it was cool so | |
I made a gist out of it. | |
""" | |
from shapely.geometry import Polygon, MultiPolygon |
It's common to use the [shapely.stretree.STRtree.query
] to find what's near a point.
Often the point is buffered to get whatever is roughly within a radius of the point.
For example,
dist = 123.456
geoms_near_point = tree.query(pt.buffer(dist))
What's really being returned here are any geometries in the tree whose bounding boxes
intersect with the point's bounding box. By default, pt.buffer(dist)
returns a buffer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""A small module for finding the distance between two geometries in an arbitrary direction | |
Inspired by a question/issue in the Shapely github repository (`#1051`_). | |
Notes | |
----- | |
There is another way I can think of doing this which will probably be much faster for | |
large geometries, but less accurate. It should be possible to stretch both geometries | |
by a very large amount in the direction perpendicular to the direction you want to | |
find the distance in. Of course, you would loose the 'movement' idea (i.e. it could |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A list of spiders in alltheplacs that do not have wikidata added to them | |
# There are 548/690 which do not. | |
# Repository link: https://github.com/alltheplaces/alltheplaces | |
grep -rL 'brand_wikidata' locations/spiders/ | |
: ' | |
locations/spiders/lane_bryant.py | |
locations/spiders/chilis.py | |
locations/spiders/half_price_books.py | |
locations/spiders/trader_joes.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
A short script to start a song at a random time on Christmas morning. | |
Usage | |
----- | |
You will need a way to keep your computer from falling asleep. I | |
used the Caffiene program which I believe is crossplatform. If your | |
computer does fall asleep, run out of batteries, get stolen by | |
Santa, etc; the music will not play in the morning. |
OlderNewer