This file contains hidden or 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
2017-11-24 10:43:36,843 INFO [sqlalchemy.engine.base.Engine][waitress] SELECT languoid.pk AS languoid_pk, language.pk AS language_pk, language.jsondata AS language_jsondata, language.polymorphic_type AS language_polymorphic_type, language.id AS language_id, language.name AS language_name, language.description AS language_description, language.markup_description AS language_markup_description, language.latitude AS language_latitude, language.longitude AS language_longitude, language.version AS language_version, languoid.hid AS languoid_hid, languoid.father_pk AS languoid_father_pk, languoid.family_pk AS languoid_family_pk, languoid.level AS languoid_level, languoid.status AS languoid_status, languoid.bookkeeping AS languoid_bookkeeping, languoid.newick AS languoid_newick, languoid.child_family_count AS languoid_child_family_count, languoid.child_language_count AS languoid_child_language_count, languoid.child_dialect_count AS languoid_child_dialect_count, languoid_1.pk AS languoid_1_pk, language_1.pk AS langua |
This file contains hidden or 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 sys | |
import re | |
import requests | |
from hurry.filesize import size | |
NEXT = re.compile('\<(?P<url>[^\>]+)\>; rel\=\"next\"') |
This file contains hidden or 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
""" | |
Python 2.7 script to determine WWF Ecoregions in which a given species has been observed. | |
Assumes you have downloaded the WWF Ecoregions shapefile. | |
Usage: | |
$ python ecoregions_for_species.py "Ursus maritimus" | |
PA1101 Arctic desert | |
NA0616 Southern Hudson Bay taiga |
This file contains hidden or 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 json | |
from sqlalchemy import not_ | |
from sqlalchemy.orm import joinedload | |
from clld.scripts.util import parsed_args | |
from clld.db.meta import DBSession | |
from glottolog3.models import Ref, Doctype, Languoid, Provider |